Add CMakeLists.txt
[dyninst.git] / CMakeLists.txt
1 cmake_minimum_required (VERSION 2.6)
2 project (Dyninst)
3
4 set (PLATFORM $ENV{PLATFORM})
5
6 set (CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/cmake/Modules")
7 include (cmake/cap_arch_def.cmake)
8 include (cmake/c++11.cmake)
9 include (cmake/warnings.cmake)
10 include (cmake/packages.cmake)
11 include (cmake/options.cmake)
12
13 set (BUILD_SHARED_LIBS ON)
14
15 include_directories (
16                     ${PROJECT_SOURCE_DIR}
17                     ${PROJECT_SOURCE_DIR}/external
18   )
19
20 set (HEADER_DIRS dataflowAPI
21                  dwarf
22                  dyninstAPI
23                  dyninstAPI_RT
24                  dynutil
25                  elf
26                  instructionAPI
27                  parseAPI
28                  patchAPI
29                  proccontrol
30                  stackwalk
31                  symlite
32                  symtabAPI
33     )
34
35 foreach (dir ${HEADER_DIRS})
36   include_directories ( ${PROJECT_SOURCE_DIR}/${dir}/h )
37 endforeach()
38
39 # Component time
40 add_subdirectory (dynutil)
41 add_subdirectory (common)
42 add_subdirectory (elf)
43 add_subdirectory (dwarf)
44 add_subdirectory (instructionAPI)
45 add_subdirectory (symtabAPI)
46 add_subdirectory (symlite)
47 add_subdirectory (parseAPI)
48 add_subdirectory (patchAPI)
49 add_subdirectory (proccontrol)
50 add_subdirectory (stackwalk)
51 add_subdirectory (dyninstAPI)