Warning, /graphics/krita/plugins/extensions/pykrita/kritarunner/CMakeLists.txt is written in an unsupported language. File is not indexed.
0001 include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../plugin 0002 ${CMAKE_CURRENT_BINARY_DIR}/../plugin 0003 ${CMAKE_CURRENT_SOURCE_DIR}/../libkis 0004 ${CMAKE_CURRENT_BINARY_DIR}/../libkis 0005 ) 0006 0007 set(kritarunner_SRCS main.cpp) 0008 0009 set(kritarunner_PRIVATE_LINK_LIBS 0010 ${PYTHON_LIBRARY} 0011 pykrita 0012 Qt5::Core 0013 Qt5::Gui 0014 Qt5::Widgets 0015 Qt5::Xml 0016 Qt5::Network 0017 Qt5::PrintSupport 0018 Qt5::Svg 0019 Qt5::Concurrent 0020 ) 0021 0022 if(WIN32) 0023 configure_file(kritarunner.exe.manifest.in ${CMAKE_CURRENT_BINARY_DIR}/kritarunner.exe.manifest) 0024 if (MINGW) 0025 # CMake does not know how to embed manifest on mingw, so we create our own RC file to be included 0026 file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/kritarunner.exe.manifest.rc "1 24 \"kritarunner.exe.manifest\"\n") 0027 add_library(kritarunner_manifest_res OBJECT ${CMAKE_CURRENT_BINARY_DIR}/kritarunner.exe.manifest.rc) 0028 set_property(TARGET kritarunner_manifest_res PROPERTY AUTOMOC OFF) 0029 set_property(TARGET kritarunner_manifest_res PROPERTY INCLUDE_DIRECTORIES "") 0030 set(kritarunner_SRCS ${kritarunner_SRCS} $<TARGET_OBJECTS:kritarunner_manifest_res>) 0031 else() 0032 set(kritarunner_SRCS ${kritarunner_SRCS} 0033 ${CMAKE_CURRENT_BINARY_DIR}/kritarunner.exe.manifest 0034 ) 0035 endif() 0036 endif() 0037 0038 add_executable(kritarunner ${kritarunner_SRCS}) 0039 target_include_directories(kritarunner SYSTEM PUBLIC "${PYTHON_INCLUDE_DIRS}") 0040 target_link_libraries(kritarunner PRIVATE ${kritarunner_PRIVATE_LINK_LIBS}) 0041 0042 if(APPLE) 0043 set_target_properties(kritarunner PROPERTIES INSTALL_RPATH "@loader_path/../Frameworks;@executable_path/../lib;@executable_path/../Frameworks") 0044 set_property(TARGET kritarunner PROPERTY MACOSX_BUNDLE OFF) 0045 endif() 0046 0047 if (MINGW) 0048 target_compile_definitions(kritarunner PRIVATE _hypot=hypot) 0049 endif (MINGW) 0050 0051 install(TARGETS kritarunner ${INSTALL_TARGETS_DEFAULT_ARGS}) 0052 0053 if (WIN32) 0054 add_executable(kritarunner_com ${kritarunner_SRCS}) 0055 target_include_directories(kritarunner_com SYSTEM PUBLIC "${PYTHON_INCLUDE_DIRS}") 0056 target_link_libraries(kritarunner_com PRIVATE ${kritarunner_PRIVATE_LINK_LIBS}) 0057 0058 set_target_properties(kritarunner_com 0059 PROPERTIES 0060 WIN32_EXECUTABLE false 0061 SUFFIX ".com" 0062 ) 0063 if (NOT MSVC) 0064 # MSBuild copies all binaries and library exports into a single 0065 # directory. This constitutes a write race condition with kritarunner. 0066 # See https://gitlab.kitware.com/cmake/cmake/-/issues/22133 0067 set_target_properties(kritarunner_com 0068 PROPERTIES 0069 OUTPUT_NAME "kritarunner" 0070 ) 0071 endif() 0072 0073 if (MINGW) 0074 target_compile_definitions(kritarunner_com PRIVATE _hypot=hypot) 0075 endif (MINGW) 0076 0077 if (MSVC) 0078 target_link_options(kritarunner_com PRIVATE "/DEBUG:NONE") 0079 endif() 0080 0081 install(TARGETS kritarunner_com ${INSTALL_TARGETS_DEFAULT_ARGS}) 0082 endif (WIN32)