CMakeLists.txt 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. project(CTKScriptingPythonCore)
  2. #
  3. # See CTK/CMake/ctkMacroBuildLib.cmake for details
  4. #
  5. set(KIT_export_directive "CTK_SCRIPTING_PYTHON_CORE_EXPORT")
  6. # Source files
  7. set(KIT_SRCS
  8. ctkAbstractPythonManager.cpp
  9. ctkAbstractPythonManager.h
  10. )
  11. # Headers that should run through moc
  12. set(KIT_MOC_SRCS
  13. ctkAbstractPythonManager.h
  14. )
  15. # UI files
  16. set(KIT_UI_FORMS
  17. )
  18. # Resources
  19. set(KIT_resources
  20. )
  21. #
  22. # Configure file describing which Qt modules are wrapped
  23. #
  24. set(QT_PYTHON_WRAPPED_LIBRARIES_LIST Core Gui Widgets Network OpenGL Sql Svg UiTools WebKit WebKitWidgets Xml XmlPatterns)
  25. foreach(qtlib ${QT_PYTHON_WRAPPED_LIBRARIES_LIST})
  26. string(TOUPPER ${qtlib} qtlib)
  27. set(CTK_PYTHONQT_WRAP_QT${qtlib} ${CTK_LIB_Scripting/Python/Core_PYTHONQT_WRAP_QT${qtlib}})
  28. message(CTK_LIB_Scripting/Python/Core_PYTHONQT_WRAP_QT${qtlib}:${CTK_LIB_Scripting/Python/Core_PYTHONQT_WRAP_QT${qtlib}})
  29. endforeach()
  30. configure_file(
  31. ctkScriptingPythonCoreConfigure.h.in
  32. ${CMAKE_CURRENT_BINARY_DIR}/ctkScriptingPythonCoreConfigure.h
  33. )
  34. # Target libraries - See CMake/ctkFunctionGetTargetLibraries.cmake
  35. # The following macro will read the target libraries from the file 'target_libraries.cmake'
  36. ctkFunctionGetTargetLibraries(KIT_target_libraries)
  37. ctkMacroBuildLib(
  38. NAME ${PROJECT_NAME}
  39. EXPORT_DIRECTIVE ${KIT_export_directive}
  40. SRCS ${KIT_SRCS}
  41. MOC_SRCS ${KIT_MOC_SRCS}
  42. UI_FORMS ${KIT_UI_FORMS}
  43. TARGET_LIBRARIES ${KIT_target_libraries}
  44. RESOURCES ${KIT_resources}
  45. LIBRARY_TYPE ${CTK_LIBRARY_MODE}
  46. )
  47. # Plugins
  48. #if(CTK_BUILD_QTDESIGNER_PLUGINS)
  49. # add_subdirectory(Plugins)
  50. #endif()
  51. add_subdirectory(Python)
  52. # Testing
  53. if(BUILD_TESTING)
  54. add_subdirectory(Testing)
  55. endif()