-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathCMakeLists.txt
31 lines (20 loc) · 868 Bytes
/
CMakeLists.txt
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
cmake_minimum_required(VERSION 3.5)
project(mvshape CXX)
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_VERBOSE_MAKEFILE ON)
find_package(Threads REQUIRED)
set(CMAKE_SHARED_LINKER_FLAGS "-Wl,--as-needed,--no-undefined,--error-unresolved-symbols")
set(CMAKE_EXEC_LINKER_FLAGS "-Wl,--as-needed,--no-undefined,--error-unresolved-symbols")
set(CMAKE_EXE_LINKER_FLAGS
"${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath=/usr/local/cuda-8.0/lib64")
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -Ofast -mfpmath=both")
find_package(OpenMP)
if (OPENMP_FOUND)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}")
endif ()
# ---
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/third_party/cmake/Modules/")
add_subdirectory(third_party)
add_subdirectory(proto)
add_subdirectory(cpp)