]> Creatis software - FrontAlgorithms.git/blob - CMakeLists.txt
811b889fd7bfb0fa78e75120e6768face6ad2ff5
[FrontAlgorithms.git] / CMakeLists.txt
1 CMAKE_MINIMUM_REQUIRED(VERSION 3.0)
2
3 ## ========================
4 ## == Project definition ==
5 ## ========================
6
7 SET(prj_NAME FrontAlgorithms)
8 SET(prj_MAJOR_VERSION   0)
9 SET(prj_MINOR_VERSION   1)
10 SET(prj_RELEASE_VERSION 0)
11 SET(_subdirs lib plugins examples)
12 SET(_policies CMP0015 CMP0020 CMP0042)
13
14 ## ==========================
15 ## == Some useful policies ==
16 ## ==========================
17
18 FOREACH(_p ${_policies})
19   IF(POLICY ${_p})
20     CMAKE_POLICY(SET ${_p} NEW)
21   ENDIF(POLICY ${_p})
22 ENDFOREACH(_p)
23
24 ## ===========================
25 ## == Project configuration ==
26 ## ===========================
27
28 PROJECT(${prj_NAME})
29 SET(
30   prj_VERSION
31   "${prj_MAJOR_VERSION}.${prj_MINOR_VERSION}.${prj_RELEASE_VERSION}"
32   )
33 SET(prj_SHORT_VERSION "${prj_MAJOR_VERSION}")
34
35 ## =====================================
36 ## == Functions, packages and options ==
37 ## =====================================
38
39 FIND_PACKAGE(cpPlugins QUIET)
40 IF(cpPlugins_DIR)
41   OPTION(USE_cpPlugins "Build cpPlugins-based code" ON)
42 ELSE(cpPlugins_DIR)
43   OPTION(USE_cpPlugins "Build cpPlugins-based code" OFF)
44   MARK_AS_ADVANCED(FORCE cpPlugins_DIR)
45 ENDIF(cpPlugins_DIR)
46 IF(USE_cpPlugins)
47   FIND_PACKAGE(cpPlugins)
48   MARK_AS_ADVANCED(CLEAR cpPlugins_DIR)
49 ENDIF(USE_cpPlugins)
50 INCLUDE(cmake/BaseConfig.cmake)
51 INCLUDE(cmake/KitwareTools.cmake)
52 INCLUDE(cmake/QtTools.cmake)
53 INCLUDE(cmake/Functions.cmake)
54
55 ## ===========================
56 ## == Build different parts ==
57 ## ===========================
58
59 FOREACH(_s ${_subdirs})
60   SUBDIRS(${_s})
61 ENDFOREACH(_s)
62
63 ## eof - $RCSfile$