-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
38 lines (30 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
PROJECT(gomory)
CMAKE_MINIMUM_REQUIRED(VERSION 2.8.3)
include(ExternalProject)
SET(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMakeModules)
SET(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake")
FIND_PACKAGE(GUROBI)
SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/output)
SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/output)
SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/output)
FOREACH(OUTPUTCONFIG ${CMAKE_CONFIGURATION_TYPES})
STRING(TOUPPER ${OUTPUTCONFIG} OUTPUTCONFIG)
SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY_${OUTPUTCONFIG} ${CMAKE_BINARY_DIR}/output)
SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY_${OUTPUTCONFIG} ${CMAKE_BINARY_DIR}/output)
SET(CMAKE_ARCHIVE_OUTPUT_DIRECTORY_${OUTPUTCONFIG} ${CMAKE_BINARY_DIR}/output)
ENDFOREACH(OUTPUTCONFIG CMAKE_CONFIGURATION_TYPES)
set(QSOPT_EX_DIR "${CMAKE_CURRENT_SOURCE_DIR}/libraries/qsopt-ex")
ExternalProject_Add(
qsopt-ex
SOURCE_DIR "${QSOPT_EX_DIR}"
PATCH_COMMAND "./bootstrap"
CONFIGURE_COMMAND "./configure"
INSTALL_COMMAND ""
BUILD_IN_SOURCE 1
BUILD_COMMAND "make")
INCLUDE_DIRECTORIES("${QSOPT_EX_DIR}")
set(QSOPT_LIB "${CMAKE_CURRENT_SOURCE_DIR}/libraries/qsopt-ex/.libs/libqsopt_ex.a")
INCLUDE_DIRECTORIES("libraries/rapidjson/include")
INCLUDE_DIRECTORIES("libraries/eigen/")
INCLUDE_DIRECTORIES("${GUROBI_INCLUDE_DIR}")
ADD_SUBDIRECTORY(source)