CMakeLists.txt 1.07 KB
Newer Older
1 2
include(plugin)

3 4
SET( CURRENT_PLUGIN_DEPS "")

5 6 7
if (EXISTS ${CMAKE_SOURCE_DIR}/ObjectTypes/PolyhedralMesh)
    add_definitions (-DENABLE_OPENVOLUMEMESH_SUPPORT)
    add_definitions (-DENABLE_OPENVOLUMEMESH_POLYHEDRAL_SUPPORT)
8 9

    list( APPEND CURRENT_PLUGIN_DEPS OpenVolumeMesh )
10 11 12 13
endif()

if (EXISTS ${CMAKE_SOURCE_DIR}/ObjectTypes/HexahedralMesh)
    add_definitions (-DENABLE_OPENVOLUMEMESH_SUPPORT)
14 15 16
    add_definitions (-DENABLE_OPENVOLUMEMESH_HEXAHEDRAL_SUPPORT)    

    list( APPEND CURRENT_PLUGIN_DEPS OpenVolumeMesh )
17
endif()
18

19 20
list(REMOVE_DUPLICATES CURRENT_PLUGIN_DEPS )

21 22 23 24 25 26
# use Qwt6 for QT5
if (NOT FORCE_QT4 AND QT5_FOUND)
  find_package(Qwt6)

  if (QWT6_FOUND)
    add_definitions(-DWITH_QWT)
Jan Möbius's avatar
Jan Möbius committed
27
    openflipper_plugin( DEPS ${CURRENT_PLUGIN_DEPS} Qwt6)
28
  else()
29
    openflipper_plugin( DEPS ${CURRENT_PLUGIN_DEPS})
30
  endif()
31
else()
32 33 34 35
  find_package(Qwt5)

  if(Qwt5_Qt4_FOUND)
    add_definitions(-DWITH_QWT)
Jan Möbius's avatar
Jan Möbius committed
36
    openflipper_plugin( DEPS ${CURRENT_PLUGIN_DEPS} Qwt5)
37
  else()
38
    openflipper_plugin(DEPS ${CURRENT_PLUGIN_DEPS})
39
  endif()
40
endif()