1 cmake_minimum_required(VERSION 2.6)
3 add_definitions(-DNDEBUG)
5 # Add an executable to the project using the specified source files.
6 add_executable(tetgen tetgen.cxx predicates.cxx)
9 find_path(CGAL_INCLUDE_PATH CGAL/Exact_predicates_inexact_constructions_kernel.h /usr/include /usr/local/include)
11 add_definitions(-DUSE_CGAL_PREDICATES)
12 find_path (BOOST_INCLUDE_PATH any.hpp /usr/include/boost /usr/local/include/boost)
13 include_directories(${BOOST_INCLUDE_PATH})
14 find_library(GMP_LIBRARY
16 PATHS /usr/lib /usr/lib64 /usr/local/lib /usr/local/lib64)
17 target_link_libraries(tetgen ${GMP_LIBRARY})
20 #Add a library to the project using the specified source files.
21 # In Linux/Unix, it will creates the libtet.a
22 add_library(tet STATIC tetgen.cxx predicates.cxx)
24 #Set properties on a target.
25 #We use this here to set -DTETLIBRARY for when compiling the
27 set_target_properties(tet PROPERTIES "COMPILE_DEFINITIONS" TETLIBRARY)
29 install(TARGETS tetgen DESTINATION bin)