-
Notifications
You must be signed in to change notification settings - Fork 2
/
CMakeLists.txt
executable file
·46 lines (31 loc) · 1.61 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
cmake_minimum_required(VERSION 2.6)
project(dawn)
add_definitions(-std=c++11)
add_definitions(-Os)
include(FindPkgConfig)
pkg_search_module(CAIRO REQUIRED cairo)
include_directories(${CAIRO_INCLUDE_DIRS})
pkg_search_module(PANGOCAIRO REQUIRED pangocairo)
include_directories(${PANGOCAIRO_INCLUDE_DIRS})
pkg_search_module(SDL2 REQUIRED sdl2)
include_directories(${SDL2_INCLUDE_DIRS})
pkg_search_module(SDL2_IMAGE REQUIRED SDL2_image)
include_directories(${SDL2_IMAGE_INCLUDE_DIRS})
pkg_search_module(GLEW REQUIRED glew)
include_directories(${GLEW_INCLUDE_DIRS})
pkg_search_module(GLU REQUIRED glu)
include_directories(${GLU_INCLUDE_DIRS})
pkg_search_module(GL REQUIRED gl)
include_directories(${GL_INCLUDE_DIRS})
pkg_search_module(EIGEN3 REQUIRED eigen3)
include_directories(${EIGEN3_INCLUDE_DIRS})
pkg_search_module(LIBPNG REQUIRED libpng)
include_directories(${LIBPNG_INCLUDE_DIRS})
pkg_search_module(LIBLOG4CXX REQUIRED liblog4cxx)
include_directories(${LIBLOG4CXX_INCLUDE_DIRS})
set(LIBRARIES ${CAIRO_LIBRARIES} ${PANGOCAIRO_LIBRARIES} ${SDL2_LIBRARIES} ${SDL2_IMAGE_LIBRARIES} ${GLEW_LIBRARIES} ${GLU_LIBRARIES} ${GL_LIBRARIES} ${EIGEN3_LIBRARIES} ${LIBPNG_LIBRARIES} ${LIBLOG4CXX_LIBRARIES})
set(SOURCES UUID.cpp GeometryUtils.cpp ImageUtils.cpp OpenGLUtils.cpp OpenGLDebug.cpp OpenGLTexture.cpp OpenGLTexturePool.cpp OpenGLShaderProgram.cpp OpenGLShaderProgramPool.cpp OpenGLRenderTarget.cpp OpenGLRenderer.cpp duktape.c libdawn.cpp)
#add_executable(sandbox ${SOURCES} sandbox.cpp)
#target_link_libraries(sandbox ${LIBRARIES})
add_executable(sandboxjs ${SOURCES} sandboxjs.cpp)
target_link_libraries(sandboxjs ${LIBRARIES})