1 # -*- mode: cmake; indent-tabs-mode: t; -*-
2 # $Id: CMakeLists.txt 17433 2008-11-12 21:16:53Z blendix $
3 # ***** BEGIN GPL LICENSE BLOCK *****
5 # This program is free software; you can redistribute it and/or
6 # modify it under the terms of the GNU General Public License
7 # as published by the Free Software Foundation; either version 2
8 # of the License, or (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software Foundation,
17 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
19 # The Original Code is Copyright (C) 2006, Blender Foundation
20 # All rights reserved.
22 # The Original Code is: all of this file.
24 # Contributor(s): Jacques Beaurain.
26 # ***** END GPL LICENSE BLOCK *****
28 # Generated code has some unused vars we can ignore.
31 # message(STATUS "Configuring makesrna")
33 # files rna_access.c rna_define.c makesrna.c intentionally excluded.
115 string(REGEX REPLACE "rna_([a-zA-Z0-9_-]*).c" "${CMAKE_CURRENT_BINARY_DIR}/rna_\\1_gen.c" GENSRC "${DEFSRC}")
116 set_source_files_properties(GENSRC PROPERTIES GENERATED true)
121 ../RNA_documentation.h
131 ../../../../intern/guardedalloc/intern/mallocn.c
132 ../../../../intern/guardedalloc/intern/mmap_win.c
145 add_definitions(-DWITH_PYTHON)
149 add_definitions(-DWITH_GAMEENGINE)
152 if(WITH_IMAGE_OPENEXR)
153 add_definitions(-DWITH_OPENEXR)
157 add_definitions(-DWITH_TIFF)
160 if(WITH_IMAGE_OPENJPEG)
161 add_definitions(-DWITH_OPENJPEG)
165 add_definitions(-DWITH_DDS)
168 if(WITH_IMAGE_CINEON)
169 add_definitions(-DWITH_CINEON)
173 add_definitions(-DWITH_HDR)
176 if(WITH_IMAGE_FRAMESERVER)
177 add_definitions(-DWITH_FRAMESERVER)
181 add_definitions(-DWITH_AUDASPACE)
184 if(WITH_CODEC_QUICKTIME)
188 add_definitions(-DWITH_QUICKTIME)
191 if(WITH_CODEC_FFMPEG)
193 ${FFMPEG_INCLUDE_DIRS}
195 add_definitions(-DWITH_FFMPEG)
198 if(NOT WITH_MOD_FLUID)
199 add_definitions(-DDISABLE_ELBEEM)
203 add_definitions(-DWITH_FFTW3)
207 add_definitions(-DWITH_SDL)
211 add_definitions(-DWITH_OPENAL)
215 add_definitions(-DWITH_JACK)
219 add_definitions(-DWITH_COLLADA)
222 # Build makesrna executable
223 blender_include_dirs(
235 ../../editors/include
236 ../../render/extern/include
237 ../../../../intern/audaspace/intern
238 ../../../../intern/guardedalloc
239 ../../../../intern/memutil
242 blender_include_dirs_sys(
246 add_executable(makesrna ${SRC} ${SRC_RNA_INC} ${SRC_DNA_INC})
247 target_link_libraries(makesrna bf_dna)
248 target_link_libraries(makesrna bf_dna_blenlib)
251 # note (linux only): with crashes try add this after COMMAND: valgrind --leak-check=full --track-origins=yes
254 COMMAND ${CMAKE_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/makesrna ${CMAKE_CURRENT_BINARY_DIR}/
269 blender_add_lib(bf_rna "${SRC}" "${INC}" "${INC_SYS}")