2013-11-06 22:26:00 +01:00
|
|
|
# Set the minimum required version of cmake for a project.
|
2026-03-25 21:57:21 +08:00
|
|
|
cmake_minimum_required(VERSION 3.6)
|
|
|
|
|
|
|
|
|
|
include_directories(./)
|
|
|
|
|
|
|
|
|
|
set(INC
|
|
|
|
|
tetgen.h
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
set(SRC
|
|
|
|
|
tetgen.cxx
|
|
|
|
|
predicates.cxx
|
|
|
|
|
)
|
2013-11-06 22:26:00 +01:00
|
|
|
|
|
|
|
|
# Add an executable to the project using the specified source files.
|
2026-03-25 21:57:21 +08:00
|
|
|
add_executable(tetgen ${INC} ${SRC})
|
2013-11-06 22:26:00 +01:00
|
|
|
|
|
|
|
|
#Add a library to the project using the specified source files.
|
|
|
|
|
# In Linux/Unix, it will creates the libtet.a
|
2026-03-25 21:57:21 +08:00
|
|
|
#add_library(tet STATIC tetgen.cxx predicates.cxx)
|
2013-11-06 22:26:00 +01:00
|
|
|
|
|
|
|
|
#Set properties on a target.
|
|
|
|
|
#We use this here to set -DTETLIBRARY for when compiling the
|
|
|
|
|
#library
|
2026-03-25 21:57:21 +08:00
|
|
|
#set_target_properties(tet PROPERTIES "COMPILE_DEFINITIONS" TETLIBRARY)
|