1 | # The name of our project is "BDM". CMakeLists files in this project can |
---|
2 | # refer to the root source directory of the project as ${BDM_SOURCE_DIR} and |
---|
3 | # to the root binary directory of the project as ${BDM_BINARY_DIR}. |
---|
4 | project (BDM) |
---|
5 | |
---|
6 | # In order to be able to use the newly written FindXXX package, the |
---|
7 | # location of the FindXXX.cmake file must be added to the cmake modules |
---|
8 | # list from within a CMakeLists.txt file as follows: |
---|
9 | set(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}\\CMake_modules\\") |
---|
10 | |
---|
11 | ###################### |
---|
12 | #Platform specific |
---|
13 | IF(WIN32) |
---|
14 | |
---|
15 | # IF YOU WANT TO USE YOUR OWN INSTALLATION OF ITTP AND/OR ACML LIBRARIES, |
---|
16 | # THEN IT IS NECESSARY TO CREATE TEXT FILE "\WIN32\LOCAL_PATHS.TXT" WITH |
---|
17 | # COPIES OF THE TWO FOLLOWING LINES AND THEN CORECT BOTH INVOLVED PATHS |
---|
18 | SET(ITPP_DIR "${BDM_SOURCE_DIR}\\win32\\itpp-4.0.1") |
---|
19 | SET(ACML_DIR "${BDM_SOURCE_DIR}\\win32\\acml3.6.0") |
---|
20 | |
---|
21 | INCLUDE(\\win32\\local_paths.txt OPTIONAL) |
---|
22 | |
---|
23 | FIND_PACKAGE(ITPP REQUIRED) |
---|
24 | FIND_PACKAGE(ACML REQUIRED) |
---|
25 | |
---|
26 | IF(ITPP_FOUND) |
---|
27 | INCLUDE_DIRECTORIES(${ITPP_INCLUDE_DIR}) |
---|
28 | LINK_DIRECTORIES(${NATIVE_ITPP_LIB_PATH}) |
---|
29 | ENDIF(ITPP_FOUND) |
---|
30 | |
---|
31 | IF(ACML_FOUND) |
---|
32 | INCLUDE_DIRECTORIES(${ACML_INCLUDE_DIR}) |
---|
33 | ENDIF(ACML_FOUND) |
---|
34 | |
---|
35 | ELSE(WIN32) |
---|
36 | #This is for UNIX makefile which does only one release at a time. |
---|
37 | SET(CMAKE_BUILD_TYPE Debug) |
---|
38 | SET(CMAKE_CXX_FLAGS_DEBUG "-g -Wall") |
---|
39 | ENDIF(WIN32) |
---|
40 | |
---|
41 | # Recurse into the "dbm" and "tests" subdirectories. This does not actually |
---|
42 | # cause another cmake executable to run. The same process will walk through |
---|
43 | # the project's entire directory structure. |
---|
44 | add_subdirectory (bdm) |
---|
45 | add_subdirectory (tests) |
---|
46 | add_subdirectory (simulator_zdenek) |
---|