CMakeLists.txt 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596
  1. PROJECT(CTKVisualizationVTKCore)
  2. #
  3. # 3rd party dependencies
  4. #
  5. FIND_PACKAGE(VTK)
  6. IF(NOT VTK_FOUND)
  7. MESSAGE(FATAL_ERROR "error: VTK package is required to build ${PROJECT_NAME}")
  8. ENDIF()
  9. INCLUDE(${VTK_USE_FILE})
  10. #
  11. # See CTK/CMake/ctkMacroBuildLib.cmake for details
  12. #
  13. SET(KIT_export_directive "CTK_VISUALIZATION_VTK_CORE_EXPORT")
  14. # Additional directories to include
  15. SET(KIT_include_directories
  16. )
  17. # Source files
  18. SET(KIT_SRCS
  19. ctkVTKColorTransferFunction.cpp
  20. ctkVTKColorTransferFunction.h
  21. ctkVTKCommandOptions.cpp
  22. ctkVTKCommandOptions.h
  23. ctkVTKCompositeFunction.cpp
  24. ctkVTKCompositeFunction.h
  25. ctkVTKConnection.cpp
  26. ctkVTKConnection.h
  27. ctkVTKHistogram.cpp
  28. ctkVTKHistogram.h
  29. ctkVTKLookupTable.cpp
  30. ctkVTKLookupTable.h
  31. ctkVTKObject.h
  32. ctkVTKObjectEventsObserver.cpp
  33. ctkVTKObjectEventsObserver.h
  34. ctkVTKPiecewiseFunction.cpp
  35. ctkVTKPiecewiseFunction.h
  36. vtkLightBoxRendererManager.cpp
  37. vtkLightBoxRendererManager.h
  38. )
  39. # Headers that should run through moc
  40. SET(KIT_MOC_SRCS
  41. ctkVTKColorTransferFunction.h
  42. ctkVTKConnection.h
  43. ctkVTKCompositeFunction.h
  44. ctkVTKLookupTable.h
  45. ctkVTKHistogram.h
  46. ctkVTKObjectEventsObserver.h
  47. ctkVTKPiecewiseFunction.h
  48. )
  49. # UI files
  50. SET(KIT_UI_FORMS
  51. )
  52. # Resources
  53. SET(KIT_resources
  54. )
  55. # Set VTK_LIBRARIES variable
  56. SET(VTK_LIBRARIES
  57. vtkCommon
  58. vtkFiltering
  59. vtkRendering
  60. vtkHybrid
  61. )
  62. # Target libraries - See CMake/ctkMacroGetTargetLibraries.cmake
  63. # The following macro will read the target libraries from the file 'target_libraries.cmake'
  64. ctkMacroGetTargetLibraries(KIT_target_libraries)
  65. ctkMacroBuildLib(
  66. NAME ${PROJECT_NAME}
  67. EXPORT_DIRECTIVE ${KIT_export_directive}
  68. INCLUDE_DIRECTORIES ${KIT_include_directories}
  69. SRCS ${KIT_SRCS}
  70. MOC_SRCS ${KIT_MOC_SRCS}
  71. UI_FORMS ${KIT_UI_FORMS}
  72. TARGET_LIBRARIES ${KIT_target_libraries}
  73. RESOURCES ${KIT_resources}
  74. LIBRARY_TYPE ${CTK_LIBRARY_MODE}
  75. )
  76. # Plugins
  77. #ADD_SUBDIRECTORY(Plugins)
  78. # Testing
  79. IF(BUILD_TESTING)
  80. ADD_SUBDIRECTORY(Testing)
  81. ENDIF(BUILD_TESTING)