mirror of https://github.com/axmolengine/axmol.git
Optimize CMake scripts
This commit is contained in:
parent
cf52f4d46a
commit
ec80ebd344
|
@ -167,6 +167,15 @@ function(cocos_copy_target_dll cocos_target)
|
|||
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${cc_dll_file} "$<TARGET_FILE_DIR:${cocos_target}>/${cc_dll_name}"
|
||||
)
|
||||
endforeach()
|
||||
|
||||
# Copy win32 angle binaries
|
||||
add_custom_command(TARGET ${cocos_target}
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libGLESv2.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libEGL.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/d3dcompiler_47.dll
|
||||
$<TARGET_FILE_DIR:${cocos_target}>
|
||||
)
|
||||
endfunction()
|
||||
|
||||
# mark `FILES` as resources, files will be put into sub-dir tree depend on its absolute path
|
||||
|
|
|
@ -430,14 +430,3 @@ if(WINDOWS)
|
|||
set_target_properties(${APP_NAME} PROPERTIES COMPILE_FLAGS "/Yuprecheader.h /FIprecheader.h")
|
||||
set_source_files_properties("${CMAKE_CURRENT_SOURCE_DIR}/Classes/precheader.cpp" PROPERTIES COMPILE_FLAGS "/Ycprecheader.h")
|
||||
endif()
|
||||
|
||||
# Copy win32 angle binaries
|
||||
if(WIN32)
|
||||
add_custom_command(TARGET ${APP_NAME}
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libGLESv2.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libEGL.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/d3dcompiler_47.dll
|
||||
$<TARGET_FILE_DIR:${APP_NAME}>
|
||||
)
|
||||
endif()
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
# ****************************************************************************/
|
||||
cmake_minimum_required(VERSION 3.6)
|
||||
|
||||
set(APP_NAME fairygui_tests)
|
||||
set(APP_NAME fairygui-tests)
|
||||
|
||||
project(${APP_NAME})
|
||||
|
||||
|
@ -144,14 +144,3 @@ if(LINUX OR WINDOWS)
|
|||
cocos_get_resource_path(APP_RES_DIR ${APP_NAME})
|
||||
cocos_copy_target_res(${APP_NAME} LINK_TO ${APP_RES_DIR} FOLDERS ${GAME_RES_FOLDER})
|
||||
endif()
|
||||
|
||||
# Copy win32 angle binaries
|
||||
if(WIN32)
|
||||
add_custom_command(TARGET ${APP_NAME}
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libGLESv2.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libEGL.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/d3dcompiler_47.dll
|
||||
$<TARGET_FILE_DIR:${APP_NAME}>
|
||||
)
|
||||
endif()
|
||||
|
|
|
@ -145,14 +145,3 @@ if(LINUX OR WINDOWS)
|
|||
cocos_copy_lua_scripts(${APP_NAME} ${res_src_folders} ${APP_RES_DIR}/src )
|
||||
cocos_copy_lua_scripts(${APP_NAME} ${res_script_folders} ${APP_RES_DIR}/src/cocos)
|
||||
endif()
|
||||
|
||||
# Copy win32 angle binaries
|
||||
if(WIN32)
|
||||
add_custom_command(TARGET ${APP_NAME}
|
||||
COMMAND ${CMAKE_COMMAND} -E copy_if_different
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libGLESv2.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/libEGL.dll
|
||||
${COCOS2DX_ROOT_PATH}/external/angle/prebuilt/win32/d3dcompiler_47.dll
|
||||
$<TARGET_FILE_DIR:${APP_NAME}>
|
||||
)
|
||||
endif()
|
||||
|
|
Loading…
Reference in New Issue