Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/makesdna/intern/CMakeLists.txt')
-rw-r--r--source/blender/makesdna/intern/CMakeLists.txt34
1 files changed, 23 insertions, 11 deletions
diff --git a/source/blender/makesdna/intern/CMakeLists.txt b/source/blender/makesdna/intern/CMakeLists.txt
index d42289e17c4..ba9e7d30e80 100644
--- a/source/blender/makesdna/intern/CMakeLists.txt
+++ b/source/blender/makesdna/intern/CMakeLists.txt
@@ -1,3 +1,4 @@
+# -*- mode: cmake; indent-tabs-mode: t; -*-
# $Id$
# ***** BEGIN GPL LICENSE BLOCK *****
#
@@ -24,30 +25,41 @@
#
# ***** END GPL LICENSE BLOCK *****
-INCLUDE_DIRECTORIES(../../../../intern/guardedalloc ..)
-FILE(GLOB INC_FILES ../*.h)
+# message(STATUS "Configuring makesdna")
+
+blender_include_dirs(
+ ../../../../intern/guardedalloc
+ ..
+)
# Build makesdna executable
-SET(SRC
+set(SRC
makesdna.c
../../../../intern/guardedalloc/intern/mallocn.c
)
-IF(WIN32)
- LIST(APPEND SRC ../../../../intern/guardedalloc/intern/mmap_win.c)
-ENDIF(WIN32)
+if(WIN32 AND NOT UNIX)
+ list(APPEND SRC
+ ../../../../intern/guardedalloc/intern/mmap_win.c
+ )
+endif()
-ADD_EXECUTABLE(makesdna ${SRC} ${INC_FILES})
+# SRC_DNA_INC is defined in the parent dir
+
+add_executable(makesdna ${SRC} ${SRC_DNA_INC})
# Output dna.c
-ADD_CUSTOM_COMMAND(
+add_custom_command(
OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/dna.c
COMMAND ${CMAKE_BINARY_DIR}/bin/${CMAKE_CFG_INTDIR}/makesdna ${CMAKE_CURRENT_BINARY_DIR}/dna.c ${CMAKE_SOURCE_DIR}/source/blender/makesdna/
DEPENDS makesdna
)
# Build bf_dna library
-SET(SRC dna_genfile.c dna.c)
-BLENDERLIB(bf_dna "${SRC}" "${INC}")
+set(SRC
+ dna_genfile.c
+ dna.c
+ ${SRC_DNA_INC}
+)
-MESSAGE(STATUS "Configuring makesdna")
+blender_add_lib(bf_dna "${SRC}" "${INC}")