Py-Driver: add 'self' option
[blender.git] / source / blender / python / intern / CMakeLists.txt
1 # ***** BEGIN GPL LICENSE BLOCK *****
2 #
3 # This program is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU General Public License
5 # as published by the Free Software Foundation; either version 2
6 # of the License, or (at your option) any later version.
7 #
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11 # GNU General Public License for more details.
12 #
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software Foundation,
15 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
16 #
17 # The Original Code is Copyright (C) 2006, Blender Foundation
18 # All rights reserved.
19 #
20 # The Original Code is: all of this file.
21 #
22 # Contributor(s): Jacques Beaurainm, Campbell Barton
23 #
24 # ***** END GPL LICENSE BLOCK *****
25
26 set(INC 
27         ..
28         ../../blenkernel
29         ../../blenlib
30         ../../blenloader
31         ../../blentranslation
32         ../../editors/include
33         ../../gpu
34         ../../imbuf
35         ../../makesdna
36         ../../makesrna
37         ../../windowmanager
38         ../../../../intern/cycles/blender
39         ../../../../intern/opencolorio
40         ../../../../intern/guardedalloc
41 )
42
43 set(INC_SYS
44         ${PYTHON_INCLUDE_DIRS}
45 )
46
47 set(SRC
48         gpu.c
49         gpu_offscreen.c
50         bpy.c
51         bpy_app.c
52         bpy_app_build_options.c
53         bpy_app_ffmpeg.c
54         bpy_app_handlers.c
55         bpy_app_ocio.c
56         bpy_app_oiio.c
57         bpy_app_openvdb.c
58         bpy_app_sdl.c
59         bpy_app_translations.c
60         bpy_driver.c
61         bpy_interface.c
62         bpy_interface_atexit.c
63         bpy_intern_string.c
64         bpy_library_load.c
65         bpy_library_write.c
66         bpy_operator.c
67         bpy_operator_wrap.c
68         bpy_path.c
69         bpy_props.c
70         bpy_rna.c
71         bpy_rna_anim.c
72         bpy_rna_array.c
73         bpy_rna_callback.c
74         bpy_rna_driver.c
75         bpy_rna_id_collection.c
76         bpy_traceback.c
77         bpy_util.c
78         bpy_utils_previews.c
79         bpy_utils_units.c
80         stubs.c
81
82         gpu.h
83         bpy.h
84         bpy_app.h
85         bpy_app_build_options.h
86         bpy_app_ffmpeg.h
87         bpy_app_handlers.h
88         bpy_app_ocio.h
89         bpy_app_oiio.h
90         bpy_app_openvdb.h
91         bpy_app_sdl.h
92         bpy_app_translations.h
93         bpy_driver.h
94         bpy_intern_string.h
95         bpy_library.h
96         bpy_operator.h
97         bpy_operator_wrap.h
98         bpy_path.h
99         bpy_props.h
100         bpy_rna.h
101         bpy_rna_anim.h
102         bpy_rna_callback.h
103         bpy_rna_driver.h
104         bpy_rna_id_collection.h
105         bpy_traceback.h
106         bpy_util.h
107         bpy_utils_previews.h
108         bpy_utils_units.h
109         ../BPY_extern.h
110 )
111
112 # only to check if buildinfo is available
113 if(WITH_BUILDINFO)
114         add_definitions(-DBUILD_DATE)
115 endif()
116
117 if(WITH_PYTHON_MODULE)
118         add_definitions(-DWITH_PYTHON_MODULE)
119 endif()
120
121 if(WITH_PYTHON_SAFETY)
122         add_definitions(-DWITH_PYTHON_SAFETY)
123 endif()
124
125
126
127 if(WITH_AUDASPACE)
128         add_definitions(-DWITH_AUDASPACE)
129 endif()
130
131 if(WITH_BULLET)
132         add_definitions(-DWITH_BULLET)
133 endif()
134
135 if(WITH_CODEC_AVI)
136         add_definitions(-DWITH_AVI)
137 endif()
138
139 if(WITH_CODEC_FFMPEG)
140         list(APPEND INC_SYS
141                 ${FFMPEG_INCLUDE_DIRS}
142         )
143         add_definitions(-DWITH_FFMPEG)
144 endif()
145
146 if(WITH_CODEC_QUICKTIME)
147         add_definitions(-DWITH_QUICKTIME)
148 endif()
149
150 if(WITH_CODEC_SNDFILE)
151         add_definitions(-DWITH_SNDFILE)
152 endif()
153
154 if(WITH_COMPOSITOR)
155         add_definitions(-DWITH_COMPOSITOR)
156 endif()
157
158 if(WITH_CYCLES)
159         add_definitions(-DWITH_CYCLES)
160 endif()
161
162 if(WITH_CYCLES_OSL)
163         add_definitions(-DWITH_CYCLES_OSL)
164 endif()
165
166 if(WITH_FREESTYLE)
167         list(APPEND INC
168                 ../../freestyle/intern/python
169         )
170         add_definitions(-DWITH_FREESTYLE)
171 endif()
172
173 if(WITH_GAMEENGINE)
174         add_definitions(-DWITH_GAMEENGINE)
175 endif()
176
177 if(WITH_IMAGE_CINEON)
178         add_definitions(-DWITH_CINEON)
179 endif()
180
181 if(WITH_IMAGE_DDS)
182         add_definitions(-DWITH_DDS)
183 endif()
184
185 if(WITH_IMAGE_FRAMESERVER)
186         add_definitions(-DWITH_FRAMESERVER)
187 endif()
188
189 if(WITH_IMAGE_HDR)
190         add_definitions(-DWITH_HDR)
191 endif()
192
193 if(WITH_IMAGE_OPENEXR)
194         add_definitions(-DWITH_OPENEXR)
195 endif()
196
197 if(WITH_OPENIMAGEIO)
198         add_definitions(-DWITH_OPENIMAGEIO)
199 endif()
200
201 if(WITH_IMAGE_OPENJPEG)
202         add_definitions(-DWITH_OPENJPEG)
203 endif()
204
205 if(WITH_IMAGE_TIFF)
206         add_definitions(-DWITH_TIFF)
207 endif()
208
209 if(WITH_INPUT_NDOF)
210         add_definitions(-DWITH_INPUT_NDOF)
211 endif()
212
213 if(WITH_INTERNATIONAL)
214         add_definitions(-DWITH_INTERNATIONAL)
215 endif()
216
217 if(WITH_OPENAL)
218         add_definitions(-DWITH_OPENAL)
219 endif()
220
221 if(WITH_SDL)
222         list(APPEND INC_SYS
223                 ${SDL_INCLUDE_DIR}
224         )
225         add_definitions(-DWITH_SDL)
226 endif()
227
228 if(WITH_SDL_DYNLOAD)
229         list(APPEND INC
230                 ../../../../extern/sdlew/include
231         )
232         add_definitions(-DWITH_SDL_DYNLOAD)
233 endif()
234
235 if(WITH_JACK)
236         add_definitions(-DWITH_JACK)
237 endif()
238
239 if(WITH_LIBMV)
240         add_definitions(-DWITH_LIBMV)
241 endif()
242
243 if(WITH_MOD_BOOLEAN)
244         add_definitions(-DWITH_MOD_BOOLEAN)
245 endif()
246
247 if(WITH_MOD_FLUID)
248         add_definitions(-DWITH_MOD_FLUID)
249 endif()
250
251 if(WITH_MOD_OCEANSIM)
252         add_definitions(-DWITH_OCEANSIM)
253 endif()
254
255 if(WITH_MOD_REMESH)
256         add_definitions(-DWITH_MOD_REMESH)
257 endif()
258
259 if(WITH_MOD_SMOKE)
260         add_definitions(-DWITH_SMOKE)
261 endif()
262
263 if(WITH_OPENCOLLADA)
264         add_definitions(-DWITH_COLLADA)
265 endif()
266
267 if(WITH_OPENCOLORIO)
268         add_definitions(-DWITH_OCIO)
269 endif()
270
271 if(WITH_OPENVDB)
272         add_definitions(-DWITH_OPENVDB)
273         list(APPEND INC
274                 ../../../../intern/openvdb
275         )
276 endif()
277
278 if(WITH_OPENIMAGEIO)
279         add_definitions(-DWITH_OPENIMAGEIO)
280         list(APPEND INC
281                 ../../imbuf/intern/oiio
282         )
283 endif()
284
285 if(WITH_PLAYER)
286         add_definitions(-DWITH_PLAYER)
287 endif()
288
289 add_definitions(${GL_DEFINITIONS})
290
291 blender_add_lib(bf_python "${SRC}" "${INC}" "${INC_SYS}")