-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
46 lines (35 loc) · 1.31 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
cmake_minimum_required (VERSION 2.8.12)
project (pomerol2dcore CXX)
# set version number
set(pomerol2dcore_version_major 1)
set(pomerol2dcore_version_minor 7)
message(STATUS "pomerol2dcore version ${pomerol2dcore_version_major}.${pomerol2dcore_version_minor}")
configure_file (
"${PROJECT_SOURCE_DIR}/Config.h.in"
"${PROJECT_BINARY_DIR}/Config.h"
)
include_directories("${PROJECT_BINARY_DIR}")
list(APPEND CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
#include(CommonDefs)
# Disable build in source
if (${CMAKE_BINARY_DIR} STREQUAL ${CMAKE_SOURCE_DIR})
message(FATAL_ERROR "In source builds are disabled. Please use a separate build directory.")
endif()
set(CMAKE_DISABLE_SOURCE_CHANGES ON)
set(CMAKE_DISABLE_IN_SOURCE_BUILD ON)
SET(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
find_package(pomerol)
message(STATUS "Pomerol includes : ${pomerol_INCLUDE_DIRS}")
message(STATUS "Pomerol libraries : ${pomerol_LIBRARIES}")
find_package(Boost COMPONENTS mpi serialization)
include_directories(${pomerol_INCLUDE_DIRS})
include_directories(include)
add_definitions(-std=c++11)
set (sources
src/ReadWrite.cpp
src/Params.cpp
src/OperatorPresetsExtra.cpp
)
add_executable(pomerol2dcore src/pomerol2dcore.cpp ${sources})
target_link_libraries(pomerol2dcore ${pomerol_LIBRARIES})
install(TARGETS pomerol2dcore DESTINATION bin)