-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
64 lines (54 loc) · 1.62 KB
/
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
cmake_minimum_required (VERSION 3.20)
project (py_gpu_inferno LANGUAGES CXX)
set(CMAKE_CXX_STANDARD 17)
if(NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE Release)
endif()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Werror")
set(CMAKE_CXX_FLAGS_DEBUG "-g")
set(CMAKE_CXX_FLAGS_RELEASE "-O3")
find_library(APPLE_FWK_FOUNDATION Foundation REQUIRED)
find_library(APPLE_FWK_QUARTZ_CORE QuartzCore REQUIRED)
find_library(APPLE_FWK_METAL Metal REQUIRED)
add_subdirectory(pybind11)
pybind11_add_module(${PROJECT_NAME}
src/pybind.cpp
src/common.hpp
src/consAvg.hpp
src/consAvgNoMask.hpp
src/flam.hpp
src/inferno.hpp
src/infernoAvg.hpp
src/infernoAvgScore.hpp
src/loadConsAvgLibrary.hpp
src/loadConsAvgNoMaskLibrary.hpp
src/loadFlam2Library.hpp
src/loadInfAvgLibrary.hpp
src/loadInfAvgScoreLibrary.hpp
src/loadLibrary.hpp
src/loadLibraryCommon.hpp
src/loadMPDLibrary.hpp
src/loadPhaseLibrary.hpp
src/loadSALibrary.hpp
src/mpd.hpp
src/phase.hpp
src/sensitivity_analysis.hpp
)
set(PYTHON_EXECUTABLE "/Users/alexander/.pyenv-arm64/versions/miniconda3-latest/envs/python-inferno/bin/python3")
set(
INC_DIRS
SYSTEM
PUBLIC
${CMAKE_CURRENT_LIST_DIR}/src
${CMAKE_CURRENT_LIST_DIR}/metal-cpp
${CMAKE_CURRENT_LIST_DIR}/pybind11/include
"/Users/alexander/.pyenv-arm64/versions/miniconda3-latest/envs/python-inferno/include/python3.10"
)
set(
LIBS
${APPLE_FWK_FOUNDATION}
${APPLE_FWK_QUARTZ_CORE}
${APPLE_FWK_METAL}
)
target_include_directories(${PROJECT_NAME} PRIVATE ${INC_DIRS})
target_link_libraries(${PROJECT_NAME} PRIVATE ${LIBS})