2014-08-27 14:03:56 +00:00
|
|
|
cmake_minimum_required(VERSION 2.8 FATAL_ERROR)
|
2015-05-24 23:38:00 +00:00
|
|
|
cmake_policy(SET CMP0040 NEW) #add_custom_command's target must exist
|
2015-06-24 20:13:48 +00:00
|
|
|
project(doorkeeper_lib CXX C)
|
2014-08-27 14:03:56 +00:00
|
|
|
|
|
|
|
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -std=c++11 -g -O0 -Wall -Wextra")
|
|
|
|
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -std=c++11 -O3 -Wall -Wextra")
|
|
|
|
#string(COMPARE EQUAL CMAKE_BINARY_DIR CMAKE_SOURCE_DIR IN_SOURCE_BUILD)
|
|
|
|
|
2015-06-27 23:23:01 +00:00
|
|
|
add_definitions(
|
|
|
|
-DWITH_VECTOR_IOSTREAM
|
|
|
|
-DUSE_MANUAL_TYPENAMES
|
|
|
|
)
|
2015-05-21 16:14:07 +00:00
|
|
|
|
2015-06-06 12:32:36 +00:00
|
|
|
find_library(Boost 1.53.0 REQUIRED)
|
2014-12-09 21:30:06 +00:00
|
|
|
|
2015-06-24 20:13:48 +00:00
|
|
|
add_library(${PROJECT_NAME} INTERFACE)
|
|
|
|
|
|
|
|
target_include_directories(${PROJECT_NAME} SYSTEM
|
|
|
|
INTERFACE ${Boost_INCLUDE_DIRECTORIES}
|
2014-12-09 21:30:06 +00:00
|
|
|
)
|
|
|
|
|
2015-06-24 20:13:48 +00:00
|
|
|
target_include_directories(${PROJECT_NAME}
|
|
|
|
INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/include
|
|
|
|
INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/lib/sprout
|
2015-07-30 14:12:12 +00:00
|
|
|
INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}/lib/vectorwrapper/include
|
2014-08-27 14:03:56 +00:00
|
|
|
)
|
|
|
|
|
2015-06-27 23:23:01 +00:00
|
|
|
#add_subdirectory(lib/sprout)
|
2014-12-22 15:59:09 +00:00
|
|
|
add_subdirectory(src)
|
2015-07-29 23:18:19 +00:00
|
|
|
#add_subdirectory(test)
|
|
|
|
#add_subdirectory(game)
|
|
|
|
#add_subdirectory(tools/mapconv)
|
|
|
|
add_subdirectory(test/gtest-1.7.0)
|
|
|
|
add_subdirectory(test/unit)
|