diff options
author | Mattes D <github@xoft.cz> | 2016-07-17 16:23:29 +0200 |
---|---|---|
committer | Mattes D <github@xoft.cz> | 2016-07-18 22:11:41 +0200 |
commit | 430b62322355c0bfe6233586c9823013d60a3335 (patch) | |
tree | ed6adc62f2a7e2a5b2d39056eac962ec5a680cb5 /src/Bindings/CMakeLists.txt | |
parent | APIDump: Added explicit IsStatic flag to static functions. (diff) | |
download | cuberite-430b62322355c0bfe6233586c9823013d60a3335.tar cuberite-430b62322355c0bfe6233586c9823013d60a3335.tar.gz cuberite-430b62322355c0bfe6233586c9823013d60a3335.tar.bz2 cuberite-430b62322355c0bfe6233586c9823013d60a3335.tar.lz cuberite-430b62322355c0bfe6233586c9823013d60a3335.tar.xz cuberite-430b62322355c0bfe6233586c9823013d60a3335.tar.zst cuberite-430b62322355c0bfe6233586c9823013d60a3335.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Bindings/CMakeLists.txt | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/src/Bindings/CMakeLists.txt b/src/Bindings/CMakeLists.txt index 5c79225cc..05d4c7e4f 100644 --- a/src/Bindings/CMakeLists.txt +++ b/src/Bindings/CMakeLists.txt @@ -56,7 +56,6 @@ set (BINDING_OUTPUTS ) set(BINDING_DEPENDENCIES - tolua ../Bindings/AllToLua.pkg ../Bindings/BindingsProcessor.lua ../Bindings/LuaFunctions.h @@ -139,17 +138,21 @@ set(BINDING_DEPENDENCIES ) if (NOT MSVC) - ADD_CUSTOM_COMMAND( - # add any new generated bindings here - OUTPUT ${BINDING_OUTPUTS} - - # Regenerate bindings: - COMMAND tolua -L BindingsProcessor.lua -o Bindings.cpp -H Bindings.h AllToLua.pkg - WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} - - # add any new generation dependencies here - DEPENDS ${BINDING_DEPENDENCIES} - ) + if (HAS_LUA_INTERPRETER) + ADD_CUSTOM_COMMAND( + OUTPUT ${BINDING_OUTPUTS} + COMMAND lua BindingsProcessor.lua + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} + DEPENDS ${BINDING_DEPENDENCIES} + ) + else() + ADD_CUSTOM_COMMAND( + OUTPUT ${BINDING_OUTPUTS} + COMMAND tolua -L BindingsProcessor.lua -o Bindings.cpp -H Bindings.h AllToLua.pkg + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} + DEPENDS ${BINDING_DEPENDENCIES} tolua + ) + endif() endif () set_source_files_properties(${BINDING_OUTPUTS} PROPERTIES GENERATED TRUE) |