548aac85af907d0771a0cfde773e175e941d044a
[blender-staging.git] / intern / cycles / blender / CMakeLists.txt
1
2 set(INC
3         ../render
4         ../device
5         ../kernel
6         ../kernel/svm
7         ../util
8         ../subd
9         ../../guardedalloc
10         ../../mikktspace
11         ../../../source/blender/makesdna
12         ../../../source/blender/makesrna
13         ../../../source/blender/blenlib
14         ${CMAKE_BINARY_DIR}/source/blender/makesrna/intern
15 )
16
17 set(INC_SYS
18         ${PYTHON_INCLUDE_DIRS}
19         ${GLEW_INCLUDE_PATH}
20 )
21
22 set(SRC
23         blender_camera.cpp
24         blender_mesh.cpp
25         blender_object.cpp
26         blender_particles.cpp
27         blender_curves.cpp
28         blender_python.cpp
29         blender_session.cpp
30         blender_shader.cpp
31         blender_sync.cpp
32
33         CCL_api.h
34         blender_sync.h
35         blender_session.h
36         blender_util.h
37 )
38
39 set(ADDON_FILES
40         addon/__init__.py
41         addon/engine.py 
42         addon/osl.py
43         addon/presets.py
44         addon/properties.py
45         addon/ui.py
46         addon/version_update.py
47 )
48
49 add_definitions(-DGLEW_STATIC)
50
51 blender_add_lib(bf_intern_cycles "${SRC}" "${INC}" "${INC_SYS}")
52
53 # avoid link failure with clang 3.4 debug
54 if(CMAKE_C_COMPILER_ID MATCHES "Clang" AND NOT ${CMAKE_C_COMPILER_VERSION} VERSION_LESS '3.4')
55         set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -gline-tables-only")
56 endif()
57
58 add_dependencies(bf_intern_cycles bf_rna)
59
60 delayed_install(${CMAKE_CURRENT_SOURCE_DIR} "${ADDON_FILES}" ${CYCLES_INSTALL_PATH})
61