From: Christoph Sommer Date: Thu, 27 Dec 2007 01:59:47 +0000 (+0000) Subject: Extend wrapper.?pp dependencies to include everything in src/scripting/ X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=ae3f33e54c796b9e16ea183e4604a8a1635c8adc;p=supertux.git Extend wrapper.?pp dependencies to include everything in src/scripting/ SVN-Revision: 5238 --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 975c5f029..7ed9a2631 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -193,13 +193,15 @@ ENDIF(ENABLE_SQDBG) OPTION(GENERATE_WRAPPER "Build miniswig and generate the wrapper" ${DEBUG}) IF(GENERATE_WRAPPER) ADD_SUBDIRECTORY(tools/miniswig) + FILE(GLOB GENERATE_WRAPPER_SOURCES RELATIVE ${SUPERTUX_SOURCE_DIR} src/scripting/*.?pp) + LIST(REMOVE_ITEM GENERATE_WRAPPER_SOURCES "src/scripting/wrapper.cpp" "src/scripting/wrapper.hpp") ADD_CUSTOM_COMMAND( OUTPUT ${SUPERTUX_SOURCE_DIR}/src/scripting/wrapper.cpp ${SUPERTUX_SOURCE_DIR}/src/scripting/wrapper.hpp COMMAND cd ${SUPERTUX_SOURCE_DIR} && ${CMAKE_CXX_COMPILER} ARGS -x "c++" -E -CC -DSCRIPTING_API src/scripting/wrapper.interface.hpp -o ${SUPERTUX_BINARY_DIR}/miniswig.tmp COMMAND tools/miniswig/miniswig ARGS --input miniswig.tmp --output-cpp ${SUPERTUX_SOURCE_DIR}/src/scripting/wrapper.cpp --output-hpp ${SUPERTUX_SOURCE_DIR}/src/scripting/wrapper.hpp --module supertux --select-namespace Scripting - DEPENDS src/scripting/wrapper.interface.hpp tools/miniswig/miniswig + DEPENDS ${GENERATE_WRAPPER_SOURCES} tools/miniswig/miniswig ) ENDIF(GENERATE_WRAPPER)