1 # ***** BEGIN GPL LICENSE BLOCK *****
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.
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.
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.
17 # The Original Code is Copyright (C) 2006, Blender Foundation
18 # All rights reserved.
20 # The Original Code is: all of this file.
22 # Contributor(s): Jacques Beaurain.
24 # ***** END GPL LICENSE BLOCK *****
26 # message(STATUS "Configuring makesdna")
28 add_definitions(-DWITH_DNA_GHASH)
31 ../../../../intern/guardedalloc
32 ../../../../intern/atomic
38 # -----------------------------------------------------------------------------
39 # Build makesdna executable
42 ../../../../intern/guardedalloc/intern/mallocn.c
43 ../../../../intern/guardedalloc/intern/mallocn_guarded_impl.c
44 ../../../../intern/guardedalloc/intern/mallocn_lockfree_impl.c
47 if(WIN32 AND NOT UNIX)
49 ../../../../intern/guardedalloc/intern/mmap_win.c
53 # SRC_DNA_INC is defined in the parent dir
55 add_cc_flags_custom_test(makesdna)
57 add_executable(makesdna ${SRC} ${SRC_DNA_INC})
62 ${CMAKE_CURRENT_BINARY_DIR}/dna.c
63 ${CMAKE_CURRENT_BINARY_DIR}/dna_type_offsets.h
65 "$<TARGET_FILE:makesdna>"
66 ${CMAKE_CURRENT_BINARY_DIR}/dna.c
67 ${CMAKE_CURRENT_BINARY_DIR}/dna_type_offsets.h
68 ${CMAKE_SOURCE_DIR}/source/blender/makesdna/
73 # -----------------------------------------------------------------------------
74 # Build bf_dna library
85 ${CMAKE_CURRENT_BINARY_DIR}/dna.c
89 set_source_files_properties(
90 ${CMAKE_CURRENT_BINARY_DIR}/dna.c
91 ${CMAKE_CURRENT_BINARY_DIR}/dna_type_offsets.h
92 PROPERTIES GENERATED TRUE
95 blender_add_lib(bf_dna "${SRC}" "${INC}" "${INC_SYS}")
98 # -----------------------------------------------------------------------------
99 # Build bf_dna_blenlib library
109 ../../blenlib/intern/BLI_ghash.c
110 ../../blenlib/intern/BLI_ghash_utils.c
111 ../../blenlib/intern/BLI_mempool.c
112 ../../blenlib/intern/endian_switch.c
113 ../../blenlib/intern/hash_mm2a.c
114 ../../blenlib/intern/listbase.c
117 blender_add_lib(bf_dna_blenlib "${SRC}" "${INC}" "${INC_SYS}")