-
Notifications
You must be signed in to change notification settings - Fork 4
/
CMakeLists.txt
58 lines (47 loc) · 1.57 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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
PROJECT( qartm )
CMAKE_MINIMUM_REQUIRED(VERSION 2.8)
# setup build system
IF(NOT CMAKE_BUILD_TYPE)
SET(CMAKE_BUILD_TYPE "Debug")
ENDIF(NOT CMAKE_BUILD_TYPE)
SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake)
INCLUDE(Gch)
INCLUDE(ListFIles)
# setup project proper
SET(PROJECT_LIB lib${PROJECT_NAME})
SET(PROJECT_LIB_DIR ${CMAKE_SOURCE_DIR}/lib)
SET(PROJECT_PCH static.h)
SET(PROJECT_QT4_MODULES QtCore QtGui)
SET(PROJECT_LIBRARIES ${PROJECT_LIB})
# application / release configuration
SET(PROJECT_VERSION_MAJOR "0")
SET(PROJECT_VERSION_MINOR "0")
SET(PROJECT_VERSION_PATCH "1")
SET(PROJECT_VERSION_COUNT 1)
SET(PROJECT_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}")
SET(PROJECT_COPYRIGHT_YEAR "2012")
SET(PROJECT_VENDOR "V2Lab")
# mac identifiers
SET(PROJECT_DOMAIN_FIRST "v2")
SET(PROJECT_DOMAIN_SECOND "nl")
SET(PROJECT_DOMAIN "${PROJECT_DOMAIN_FIRST}.${PROJECT_DOMAIN_SECOND}")
INCLUDE_DIRECTORIES(${CMAKE_BINARY_DIR}/lib ${CMAKE_SOURCE_DIR}/lib)
# setup dependencies
# CxxTest
# Because we have it embedded as a submodule, we can help cmake find it
SET(CXXTEST_INCLUDE_DIR ${PROJECT_LIB_DIR}/cxxtest/cxxtest)
SET(CXXTEST_PYTHON_TESTGEN_EXECUTABLE
${PROJECT_LIB_DIR}/cxxtest/bin/cxxtestgen)
SET(CXXTEST_USE_PYTHON 1)
FIND_PACKAGE(CxxTest)
# Qt
SET(CMAKE_AUTOMOC 1)
FIND_PACKAGE(Qt4 4.8.1 REQUIRED COMPONENTS ${PROJECT_QT4_MODULES})
INCLUDE(${QT_USE_FILE})
LIST(APPEND PROJECT_LIBRARIES ${QT_LIBRARIES})
# OpenCV
FIND_PACKAGE(OpenCV REQUIRED)
LIST(APPEND PROJECT_LIBRARIES ${OpenCV_LIBS})
ADD_SUBDIRECTORY(lib)
ADD_SUBDIRECTORY(test)
ADD_SUBDIRECTORY(main)