axmol/tests/lua-empty-test/project/CMakeLists.txt

33 lines
1.2 KiB
CMake
Raw Normal View History

2014-03-11 17:56:33 +08:00
set(APP_NAME lua-empty-test)
2014-03-10 20:07:20 +08:00
set(SAMPLE_SRC
proj.linux/main.cpp
Classes/AppDelegate.cpp
)
include_directories(
Classes
../../../cocos/scripting/lua-bindings/manual
2014-03-10 20:07:20 +08:00
../../../external/lua/lua
../../../external/lua/tolua
)
# add the executable
add_executable(${APP_NAME} ${SAMPLE_SRC})
2014-03-10 20:07:20 +08:00
target_link_libraries(${APP_NAME} cocos2d luacocos2d)
2014-03-10 20:07:20 +08:00
set(APP_BIN_DIR "${CMAKE_BINARY_DIR}/bin/${APP_NAME}")
set_target_properties(${APP_NAME} PROPERTIES
RUNTIME_OUTPUT_DIRECTORY "${APP_BIN_DIR}")
pre_build(${APP_NAME}
COMMAND ${CMAKE_COMMAND} -E remove_directory ${APP_BIN_DIR}/Resources
2014-03-11 18:18:19 +08:00
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/../res ${APP_BIN_DIR}/Resources/res
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/../src ${APP_BIN_DIR}/Resources/src
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/cocos/scripting/lua-bindings/script/cocos2d ${APP_BIN_DIR}/Resources
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/cocos/scripting/lua-bindings/script/cocosdenshion ${APP_BIN_DIR}/Resources
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/cocos/scripting/lua-bindings/script/network ${APP_BIN_DIR}/Resources
2014-03-10 20:07:20 +08:00
)