-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
83 lines (66 loc) · 1.82 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# Require a recent version of cmake
cmake_minimum_required(VERSION 2.8.4 FATAL_ERROR)
# CMake entry point
cmake_minimum_required (VERSION 2.6)
project (HPXCOL)
find_package(OpenGL REQUIRED)
# Compile external dependencies
add_subdirectory (external)
# On Visual 2005 and above, this module can set the debug working directory
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/external/rpavlik-cmake-modules-1c73e35")
include(CreateLaunchers)
include(MSVCMultipleProcessCompile) # /MP
if(INCLUDE_DISTRIB)
add_subdirectory(distrib)
endif(INCLUDE_DISTRIB)
include_directories(
external/AntTweakBar-1.16/include/
external/glfw-2.7.6/include/
external/glm-0.9.4.0/
external/glew-1.9.0/include/
external/assimp-3.0.1270/include/
external/bullet-2.81-rev2613/src/
.
)
set(ALL_LIBS
${OPENGL_LIBRARY}
GLFW_276
GLEW_190
)
add_definitions(
-DTW_STATIC
-DTW_NO_LIB_PRAGMA
-DTW_NO_DIRECT3D
-DGLEW_STATIC
-D_CRT_SECURE_NO_WARNINGS
)
# This adds the HPX cmake configuration directory to the search path.
set(CMAKE_MODULE_PATH
$ENV{HPX_DIR}/share/cmake-2.8/Modules)
# Instruct cmake to find the HPX settings
find_package(HPX)
include_directories(${HPX_INCLUDE_DIR})
link_directories(${HPX_LIBRARY_DIR})
set (sources
playground/playground.cpp
playground/util.cpp
playground/util.hpp
playground/vert.glsl
playground/frag.glsl
common/controls.cpp
common/controls.hpp
common/objloader.cpp
common/objloader.hpp
common/shader.cpp
common/shader.hpp
common/texture.cpp
common/texture.hpp
common/vboindexer.cpp
common/vboindexer.hpp)
# add example executable
add_hpx_executable(playground
SOURCES ${sources}
${PLAYGROUND_FLAGS}
FOLDER
COMPONENT_DEPENDENCIES ${ALL_LIBS} assimp)
create_target_launcher(playground_exe WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/playground/")