-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
executable file
·27 lines (20 loc) · 1.26 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
CMAKE_MINIMUM_REQUIRED(VERSION 2.8.1)
PROJECT(otbm D)
SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
CACHE STRING "Where binaries files go" FORCE )
SET( CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
CACHE STRING "Where archives go" FORCE )
SET( CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
CACHE STRING "Where libraries go" FORCE )
SET( USER_DOCUMENT_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/doc
CACHE STRING "Where documentation go" FORCE )
SET( USER_INCLUDE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/inc
CACHE STRING "Where headers go" FORCE )
FILE( COPY doc/bootDoc/bootdoc.js doc/bootDoc/bootdoc.css doc/bootDoc/assets DESTINATION ${USER_DOCUMENT_OUTPUT_DIRECTORY} )
EXEC_PROGRAM( rdmd ${CMAKE_SOURCE_DIR}/doc ARGS ${CMAKE_SOURCE_DIR}/doc/bootDoc/generate.d ${CMAKE_SOURCE_DIR}/src --output ${USER_DOCUMENT_OUTPUT_DIRECTORY} )
include_directories ( "${CMAKE_SOURCE_DIR}/src" )
SET( GLOBAL_DMD_DEFS "-O -inline -gc -release -D -Dd${USER_DOCUMENT_OUTPUT_DIRECTORY} -H -Hd${USER_INCLUDE_OUTPUT_DIRECTORY}" )
SET( CMAKE_D_FLAGS "${CMAKE_D_FLAGS} ${GLOBAL_DMD_DEFS}" )
SET( PARSER_SOURCES src/otbm/otbm.d src/otbm/otb.d src/otbm/parser.d src/otbm/common.d )
ADD_LIBRARY( otbm STATIC ${PARSER_SOURCES} )
ADD_EXECUTABLE( otbt ${PARSER_SOURCES} src/tool.d )