build: windeployqt only on package dir
This commit is contained in:
parent
d4addceb09
commit
329afb47be
2 changed files with 6 additions and 11 deletions
|
|
@ -12,6 +12,12 @@ configure_file(
|
||||||
${PROJECT_BINARY_DIR}/src/version.rc @ONLY
|
${PROJECT_BINARY_DIR}/src/version.rc @ONLY
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Install Qt Depends to stage
|
||||||
|
find_program(DEPLOYQT windeployqt6)
|
||||||
|
install(CODE "execute_process(
|
||||||
|
COMMAND ${DEPLOYQT} --no-compiler-runtime --no-system-d3d-compiler --no-quick-import -network \"\${CMAKE_INSTALL_PREFIX}/deskflow.exe\"
|
||||||
|
)")
|
||||||
|
|
||||||
# Setup OS_STRING
|
# Setup OS_STRING
|
||||||
if(CMAKE_SYSTEM_PROCESSOR MATCHES AMD64)
|
if(CMAKE_SYSTEM_PROCESSOR MATCHES AMD64)
|
||||||
set(OS_STRING "win-x64")
|
set(OS_STRING "win-x64")
|
||||||
|
|
|
||||||
|
|
@ -76,17 +76,6 @@ if(WIN32)
|
||||||
".*system32.*"
|
".*system32.*"
|
||||||
RUNTIME DESTINATION .
|
RUNTIME DESTINATION .
|
||||||
)
|
)
|
||||||
find_program(DEPLOYQT windeployqt6)
|
|
||||||
add_custom_command(
|
|
||||||
TARGET ${target} POST_BUILD
|
|
||||||
COMMAND ${CMAKE_COMMAND} -E remove_directory ${CMAKE_BINARY_DIR}/qtDeploy
|
|
||||||
COMMAND ${DEPLOYQT} --no-compiler-runtime --no-system-d3d-compiler --no-quick-import -network --dir ${CMAKE_BINARY_DIR}/qtDeploy $<TARGET_FILE:${target}>
|
|
||||||
)
|
|
||||||
install(
|
|
||||||
DIRECTORY ${CMAKE_BINARY_DIR}/qtDeploy/
|
|
||||||
DESTINATION .
|
|
||||||
FILES_MATCHING PATTERN "*.*"
|
|
||||||
)
|
|
||||||
elseif(APPLE)
|
elseif(APPLE)
|
||||||
set_target_properties(${target} PROPERTIES
|
set_target_properties(${target} PROPERTIES
|
||||||
INSTALL_RPATH "@loader_path/../Libraries;@loader_path/../Frameworks"
|
INSTALL_RPATH "@loader_path/../Libraries;@loader_path/../Frameworks"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue