# The name of our project is "GNURBS". CMakeLists files in this project can # refer to the root source directory of the project as ${HELLO_SOURCE_DIR} and # to the root binary directory of the project as ${HELLO_BINARY_DIR}. cmake_minimum_required (VERSION 3.10 FATAL_ERROR) if(DEFINED CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE ${CMAKE_BUILD_TYPE} CACHE STRING "Choose build type") else(DEFINED CMAKE_BUILD_TYPE) set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING "Choose build type") endif(DEFINED CMAKE_BUILD_TYPE) project(GNURBS) option(GNURBS_ENABLE_TEST "Enable Testing-related binary targets" ON) option(GNURBS_ENABLE_VTK_INTERFACE "Enable VTK integration targets" ON) add_subdirectory(nutil) include_directories (${GNURBS_SOURCE_DIR}/nutil) link_directories (${GNURBS_BINARY_DIR}/nutil) add_subdirectory(api) include_directories (${GNURBS_SOURCE_DIR}/api) link_directories (${GNURBS_BINARY_DIR}/api) if(GNURBS_ENABLE_VTK_INTERFACE) # Find VTK find_package(VTK REQUIRED) if(NOT VTK_DIR) message(FATAL_ERROR "Please set VTK_DIR.") endif(NOT VTK_DIR) include(${VTK_USE_FILE}) include_directories (${GNURBS_SOURCE_DIR}/vtk) include_directories (${GNURBS_SOURCE_DIR}/nutil/vtkdisplay) add_subdirectory(vtk) link_directories (${GNURBS_BINARY_DIR}/vtk) link_directories (${GNURBS_BINARY_DIR}/nutil/vtkdisplay) endif(GNURBS_ENABLE_VTK_INTERFACE) add_subdirectory(test)