~mht/surcut

ref: 0dbc35cd48d7238ffa3ae1b1cd3effe59f237622 surcut/CMakeLists.txt -rw-r--r-- 1.3 KiB
0dbc35cd — Martin Hafskjold Thoresen Only optionally do the force cutoff thing 1 year, 8 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
cmake_minimum_required(VERSION 3.1)
project(surcut)

set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}/cmake)

option(LIBIGL_WITH_OPENGL            "Use OpenGL" ON)
option(LIBIGL_WITH_OPENGL_GLFW       "Use GLFW"   ON)
option(LIBIGL_WITH_OPENGL_GLFW_IMGUI "Use ImGui"  ON)
option(LIBIGL_WITH_TETGEN            "Use TetGen" ON)
option(LIBIGL_WITH_PNG               "Use PNG"    ON)


find_package(LIBIGL REQUIRED QUIET)
igl_download_stb()
find_package(OpenMP REQUIRED)

set(SRCFILES surcut.cpp arap-mold.cpp mesh.cpp)

add_executable(surcut ${SRCFILES} main.cpp)
target_link_libraries(surcut igl::core igl::opengl igl::opengl_glfw igl::opengl_glfw_imgui
  igl::tetgen OpenMP::OpenMP_CXX igl_stb_image)
target_compile_options(surcut PRIVATE -g -O2 -Wall -Werror -Wpedantic -DDEBUG)

add_executable(evaluate ${SRCFILES} evaluate.cpp)
target_link_libraries(evaluate igl::core igl::tetgen OpenMP::OpenMP_CXX igl_stb_image)
target_compile_options(evaluate PRIVATE -g -O2 -Wall -Werror -Wpedantic -DDEBUG)

add_executable(size mesh.cpp size.cpp)
target_link_libraries(size igl::core igl::tetgen)
target_compile_options(size PRIVATE -g -O2 -Wall -Werror -Wpedantic -DDEBUG)

add_executable(2obj 2obj.cpp)
target_link_libraries(2obj igl::core)
target_compile_options(2obj PRIVATE -g -O2 -Wall -Werror -Wpedantic -DDEBUG)

igl_download_tutorial_data()