Changeset 2239
- Timestamp:
- Nov 20, 2008, 10:13:11 PM (16 years ago)
- Location:
- code/branches/buildsystem
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/buildsystem/cmake/UseTolua.cmake
r2236 r2239 19 19 GET_TARGET_PROPERTY(TOLUA_EXECUTABLE "${_tolua_executable_name}" LOCATION) 20 20 21 MACRO(INCLUDE_DIRECTORIES_QUOTES)22 FOREACH(_tolua_quote_dir ${ARGN})23 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -iquote ${_tolua_quote_dir}")24 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -iquote ${_tolua_quote_dir}")25 ENDFOREACH(_tolua_quote_dir)26 ENDMACRO(INCLUDE_DIRECTORIES_QUOTES)27 28 21 MACRO(TOLUA _tolua_package _tolua_srcfiles_varname) 29 22 # TODO: cleaner arguments handling … … 32 25 33 26 SET(_tolua_pkgfile "${CMAKE_CURRENT_BINARY_DIR}/tolua.pkg") 34 SET(_tolua_cxxfile "${CMAKE_CURRENT_BINARY_DIR}/ tolua_bind.cc")35 SET(_tolua_hfile "${CMAKE_CURRENT_BINARY_DIR}/ tolua_bind.h")27 SET(_tolua_cxxfile "${CMAKE_CURRENT_BINARY_DIR}/ToluaBind${_tolua_package}.cc") 28 SET(_tolua_hfile "${CMAKE_CURRENT_BINARY_DIR}/ToluaBind${_tolua_package}.h") 36 29 SET(${_tolua_srcfiles_varname} ${${_tolua_srcfiles_varname}} "${_tolua_cxxfile}") 37 30 -
code/branches/buildsystem/src/CMakeLists.txt
r2237 r2239 21 21 orxonox 22 22 tolua 23 # Required for tolua bind files that are in the build folder 24 ${CMAKE_CURRENT_BINARY_DIR} 23 25 ) 24 26 -
code/branches/buildsystem/src/core/CMakeLists.txt
r2198 r2239 54 54 INCLUDE(UseTolua) 55 55 TOLUA(Core CORE_SRC_FILES INPUTFILES Script.h CommandExecutor.h) 56 INCLUDE_DIRECTORIES_QUOTES(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR})57 56 58 57 ADD_LIBRARY(core SHARED ${CORE_SRC_FILES}) -
code/branches/buildsystem/src/core/Script.cc
r1975 r2239 40 40 41 41 #include "tolua++.h" 42 #include " tolua_bind.h"42 #include "core/ToluaBindCore.h" 43 43 44 44 namespace orxonox -
code/branches/buildsystem/src/orxonox/CMakeLists.txt
r2198 r2239 66 66 INCLUDE(UseTolua) 67 67 TOLUA(Orxonox ORXONOX_SRC_FILES INPUTFILES gui/GUIManager.h) 68 INCLUDE_DIRECTORIES_QUOTES(${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_BINARY_DIR})69 INCLUDE_DIRECTORIES_QUOTES("${CMAKE_SOURCE_DIR}/src/core" "${CMAKE_BINARY_DIR}/src/core")70 68 71 69 ADD_EXECUTABLE( orxonox ${ORXONOX_SRC_FILES} ) -
code/branches/buildsystem/src/orxonox/gui/GUIManager.cc
r1975 r2239 43 43 #include "core/input/InputManager.h" 44 44 #include "core/input/SimpleInputState.h" 45 #include "../core/tolua_bind.h"46 45 #include "core/ConsoleCommand.h" 47 46 #include "core/Core.h" 48 #include "tolua_bind.h" 47 #include "core/ToluaBindCore.h" 48 #include "orxonox/ToluaBindOrxonox.h" 49 49 #include "GraphicsEngine.h" 50 50 #include "OgreCEGUIRenderer.h" -
code/branches/buildsystem/src/tolua/lua/package.lua
r2236 r2239 128 128 if flags.H then 129 129 local header = gsub(flags.H, '^.-([%w_]*%.[%w_]*)$', '%1') 130 output('#include "'..header..'"\n') 130 local package_lower = string.lower(self.name) 131 output('#include "'..package_lower..'/'..header..'"\n') 131 132 end 132 133 … … 203 204 204 205 if flags.H then 205 output('#include "'..self.name..'Prereqs.h"\n') 206 local package_lower = string.lower(self.name) 207 output('#include "'..package_lower..'/'..self.name..'Prereqs.h"\n') 206 208 output('/* Exported function */') 207 209 output('_'..self.name..'Export') … … 220 222 -- *** Thanks to Ariel Manzur for fixing bugs in nested directives *** 221 223 function extract_code(fn,s) 222 local code = '\n$#include "'.. fn..'"\n'224 local code = '\n$#include "'..string.lower(flags.n)..'/'..fn..'"\n' 223 225 s= "\n" .. s .. "\n" -- add blank lines as sentinels 224 226
Note: See TracChangeset
for help on using the changeset viewer.