Skip to content

Commit

Permalink
Update the js-tests CMake files.
Browse files Browse the repository at this point in the history
  • Loading branch information
WenhaiLin committed Apr 23, 2015
1 parent bbb9498 commit 55d3cc1
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -325,9 +325,9 @@ endif(BUILD_LUA_LIBS)
if(BUILD_JS_LIBS)
add_subdirectory(cocos/scripting/js-bindings)

# build lua tests
# build js tests
if(BUILD_JS_TESTS)
add_subdirectory(tests/js-tests)
add_subdirectory(tests/js-tests/project)
endif(BUILD_JS_TESTS)

endif(BUILD_JS_LIBS)
Original file line number Diff line number Diff line change
Expand Up @@ -28,26 +28,26 @@ if(WIN32)

else()
set(PLATFORM_SRC
project/proj.linux/main.cpp
proj.linux/main.cpp
)
endif()

set(SAMPLE_SRC
project/Classes/AppDelegate.cpp
project/Classes/js_DrawNode3D_bindings.cpp
project/Classes/js_Effect3D_bindings.cpp
Classes/AppDelegate.cpp
Classes/js_DrawNode3D_bindings.cpp
Classes/js_Effect3D_bindings.cpp
${PLATFORM_SRC}
)

include_directories(
project/Classes
../../cocos/scripting/js-bindings/auto
../../cocos/scripting/js-bindings/manual
../../cocos/base
../../cocos/editor-support
../../cocos/audio/include
../../external/spidermonkey/include/${PLATFORM_FOLDER}
../../external/chipmunk/include/chipmunk
Classes
../../../cocos/scripting/js-bindings/auto
../../../cocos/scripting/js-bindings/manual
../../../cocos/base
../../../cocos/editor-support
../../../cocos/audio/include
../../../external/spidermonkey/include/${PLATFORM_FOLDER}
../../../external/chipmunk/include/chipmunk
)

# add the executable
Expand All @@ -56,7 +56,7 @@ add_executable(${APP_NAME}
)

target_link_libraries(${APP_NAME}
jsbindings
jscocos2d
cocos2d
)

Expand All @@ -71,9 +71,9 @@ pre_build(${APP_NAME}
COMMAND ${CMAKE_COMMAND} -E remove_directory ${APP_BIN_DIR}/src
COMMAND ${CMAKE_COMMAND} -E remove ${APP_BIN_DIR}/*.js
COMMAND ${CMAKE_COMMAND} -E remove ${APP_BIN_DIR}/*.json
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/../cpp-tests/Resources ${APP_BIN_DIR}/res
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/src ${APP_BIN_DIR}/src
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/../../cocos/scripting/js-bindings/script ${APP_BIN_DIR}/script
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/main.js ${APP_BIN_DIR}/main.js
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/project.json ${APP_BIN_DIR}/project.json
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/../../cpp-tests/Resources ${APP_BIN_DIR}/res
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/../src ${APP_BIN_DIR}/src
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/../../../cocos/scripting/js-bindings/script ${APP_BIN_DIR}/script
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/../main.js ${APP_BIN_DIR}/main.js
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/../project.json ${APP_BIN_DIR}/project.json
)

0 comments on commit 55d3cc1

Please sign in to comment.