1
0
mirror of https://gitee.com/drabel/LibQQt.git synced 2025-01-04 10:18:44 +08:00

update app deploy command

This commit is contained in:
tianduanrui 2017-12-24 22:02:09 +08:00
parent d49105259c
commit 74ce0c25de
2 changed files with 20 additions and 5 deletions

View File

@ -9,20 +9,24 @@ isEmpty(APP_DEPLOY_ROOT){
}
message($${TARGET} deploy root: $$APP_DEPLOY_ROOT)
#set app deploy pwd
APP_DEPLOY_PWD = $${APP_DEPLOY_ROOT}/$${TARGET}/$${QKIT_STD_DIR}
contains(QKIT_PRIVATE, WIN32||WIN64) {
APP_DEPLOY_PWD~=s,/,\\,g
}
defineReplace(deploy_app_on_mac) {
#need QQT_BUILD_PWD
APP_DEPLOY_PWD = $${APP_DEPLOY_ROOT}/$${TARGET}/$${QKIT_STD_DIR}
command = &&
command += $$MK_DIR $${APP_DEPLOY_PWD} $$CMD_SEP
command += rm -fr $${APP_DEPLOY_PWD}/$${TARGET}.app &&
command += cp -fa $${DESTDIR}/$${TARGET}.app $${APP_DEPLOY_PWD}/$${TARGET}.app
command += $$RM_DIR $${APP_DEPLOY_PWD}/$${TARGET}.app &&
command += $$COPY_DIR $${DESTDIR}/$${TARGET}.app $${APP_DEPLOY_PWD}/$${TARGET}.app
#message($$command)
return ($$command)
}
defineReplace(deploy_app_on_win) {
#need QQT_BUILD_PWD
APP_DEPLOY_PWD = $${APP_DEPLOY_ROOT}\\$${TARGET}\\$${QKIT_STD_DIR}
command =
command += $$MK_DIR $${APP_DEPLOY_PWD} $$CMD_SEP
command += $$RM $${APP_DEPLOY_PWD}\\$${TARGET}.exe $$CMD_SEP
@ -41,7 +45,6 @@ defineReplace(deploy_app_on_win) {
defineReplace(deploy_app_on_linux) {
#need QQT_BUILD_PWD
APP_DEPLOY_PWD = $${APP_DEPLOY_ROOT}/$${TARGET}/$${QKIT_STD_DIR}
command =
command += $$MK_DIR $${APP_DEPLOY_PWD} $$CMD_SEP

View File

@ -14,6 +14,18 @@ contains(QMAKE_HOST.os,Windows) {
CD = cd /d
RM_DIR = rd /s /q
#PATH_SEP=\\
} else:contains(QMAKE_HOST.os, Darwin) {
SCRIPT_SUFFIX=sh
CMD_SEP = &&
MOVE = mv
COPY = cp -f
COPY_DIR = cp -fa
MK_DIR = mkdir -p
RM = rm -f
CD = cd
LN = ln -sf
RM_DIR = rm -rf
#PATH_SEP=/
} else {
SCRIPT_SUFFIX=sh
CMD_SEP = &&