Have CopyWinLibs only copy files needed for current configuration.
This commit is contained in:
@@ -122,7 +122,7 @@ if(WINDOWS)
|
|||||||
add_custom_command(
|
add_custom_command(
|
||||||
COMMENT "Copying prebuilt libraries to viewer executable directory"
|
COMMENT "Copying prebuilt libraries to viewer executable directory"
|
||||||
OUTPUT ${CMAKE_BINARY_DIR}/CopyWinLibs
|
OUTPUT ${CMAKE_BINARY_DIR}/CopyWinLibs
|
||||||
COMMAND ${CMAKE_COMMAND} -P ${CMAKE_BINARY_DIR}/CopyWinLibs.cmake
|
COMMAND ${CMAKE_COMMAND} -DCUR_CONFIG:STRING=${CMAKE_CFG_INTDIR} -P ${CMAKE_BINARY_DIR}/CopyWinLibs.cmake
|
||||||
DEPENDS ${CMAKE_BINARY_DIR}/prepare/prebuilt ${CMAKE_BINARY_DIR}/CopyWinLibs.cmake
|
DEPENDS ${CMAKE_BINARY_DIR}/prepare/prebuilt ${CMAKE_BINARY_DIR}/CopyWinLibs.cmake
|
||||||
)
|
)
|
||||||
add_custom_target(copy_win_libs DEPENDS ${CMAKE_BINARY_DIR}/CopyWinLibs)
|
add_custom_target(copy_win_libs DEPENDS ${CMAKE_BINARY_DIR}/CopyWinLibs)
|
||||||
|
|||||||
@@ -23,6 +23,10 @@ set(LIBS_DEBUG_DIR
|
|||||||
)
|
)
|
||||||
|
|
||||||
function(copy_files paths names dest)
|
function(copy_files paths names dest)
|
||||||
|
string(FIND ${dest} ${CUR_CONFIG} idx)
|
||||||
|
if(${idx} LESS 0)
|
||||||
|
return()
|
||||||
|
endif(${idx} LESS 0)
|
||||||
foreach(f ${names})
|
foreach(f ${names})
|
||||||
foreach(p ${paths})
|
foreach(p ${paths})
|
||||||
set(from_file "${p}/${f}")
|
set(from_file "${p}/${f}")
|
||||||
|
|||||||
Reference in New Issue
Block a user