-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
29 lines (21 loc) · 808 Bytes
/
CMakeLists.txt
File metadata and controls
29 lines (21 loc) · 808 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
29
cmake_minimum_required(VERSION 2.8.11)
project( openbarcode-distribution )
# Force out-of-source build
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/../lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/../lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/../bin)
set(dir ${CMAKE_CURRENT_SOURCE_DIR}./_build)
set(EXECUTABLE_OUTPUT_PATH ${dir} CACHE PATH "Build directory" FORCE)
set(LIBRARY_OUTPUT_PATH ${dir} CACHE PATH "Build directory" FORCE)
option(BUILD_LIB "Builds the openbarcode library" ON)
option(BUILD_CLI "Builds the openbarcode cli" ON)
option(BUILD_TEST "Builds the openbarcode tests" ON)
if(BUILD_LIB)
add_subdirectory( libopenbarcode )
endif()
if(BUILD_CLI)
add_subdirectory( openbarcode-cli )
endif()
if(BUILD_TEST)
add_subdirectory( tests )
endif()