-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCMakeLists.txt
42 lines (36 loc) · 1.29 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
cmake_minimum_required(VERSION 3.15)
project(nextnet VERSION 0.1.0)
# Use C++17
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
# *** Simulation library sources and headers
set(LIB_SOURCES
extern/NEXTNet/nextnet/network.cpp
extern/NEXTNet/nextnet/temporal_network.cpp
extern/NEXTNet/nextnet/algorithm.cpp
extern/NEXTNet/nextnet/random.cpp
extern/NEXTNet/nextnet/NextReaction.cpp
extern/NEXTNet/nextnet/NextReactionMeanField.cpp
extern/NEXTNet/nextnet/nMGA.cpp
extern/NEXTNet/nextnet/REGIR.cpp
extern/NEXTNet/nextnet/utility.cpp)
set(PY_SOURCES
src/binding.cpp
src/networkx.cpp
src/simulation_wrapper.cpp
src/tools.cpp)
include_directories(AFTER SYSTEM
extern/boost-core/include
extern/boost-config/include
extern/boost-range/include
extern/boost-lexical_cast/include
extern/boost-math/include
extern/boost-utility/include
extern/NEXTNet/nextnet
extern/NEXTNet/ext/dyndist)
find_package(Python3 COMPONENTS Interpreter Development REQUIRED)
message(STATUS "Found Python version: ${Python3_VERSION}")
message("Including pybind11 as a submodule")
add_subdirectory(extern/pybind11)
pybind11_add_module(nextnet ${LIB_SOURCES} ${PY_SOURCES})
set_target_properties(nextnet PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/python/nextnet)