-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
28 lines (22 loc) · 834 Bytes
/
CMakeLists.txt
File metadata and controls
28 lines (22 loc) · 834 Bytes
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
cmake_minimum_required(VERSION 3.10.1)
project(apcpp)
# Compiler flags
set(CMAKE_CXX_FLAGS
"${CMAKE_CXX_FLAGS} -std=c++14 -Werror -Wall -Wextra -Wno-c++98-compat -Wno-unused-parameter -pedantic-errors")
# Where to look for header files
include_directories(src/)
# This allows "make install" to put all the headers in the right place.
set(APCPP_LIB_HEADERS
src/apcpp/ap_solver.h
src/apcpp/primal_dual_ap_solver.h)
set(APCPP_LIB_SOURCES
src/apcpp/ap_solver.cpp
src/apcpp/primal_dual_ap_solver.cpp)
# apcpp library
add_library(apcpp SHARED ${APCPP_LIB_SOURCES})
target_link_libraries(apcpp)
# ap test executable
set(APCPP_TEST_SOURCES src/test/main.cpp)
add_executable(apcpp-test ${APCPP_TEST_SOURCES})
target_link_libraries(apcpp-test apcpp)
set_target_properties(apcpp-test PROPERTIES OUTPUT_NAME apcpp-test)