From e90ff5701a661d24f8c1e8c88fa2711569d14643 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Wed, 28 Jun 2023 16:39:05 +0300 Subject: [PATCH] Changes to work around issue QTBUG-112204. --- appveyor.yml | 11 +++++++++-- qbs/modules/windeployqt/windeployqt.qbs | 11 ++++++++++- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 665dda33a..559bf161d 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -57,6 +57,7 @@ environment: PYTHON: "C:\\Python311-x64" PLATFORM: "Windows10+" MSYS2_PACKAGES: true + WINDEPLOYQT_BIN_PATH: "C:\\Qt\\6.4\\mingw_64\\bin" DEPLOY: true - job_name: Windows_Qt_5_15_(qbs_GCC_x86) @@ -75,6 +76,7 @@ environment: PYTHON: "C:\\Python311" PLATFORM: "Windows7+" MSYS2_PACKAGES: false + WINDEPLOYQT_BIN_PATH: "undefined" DEPLOY: true - job_name: Windows_Qt_5_6_(GCC_x86) @@ -156,7 +158,8 @@ environment: ARCH: x64 PYTHON: "C:\\Python311-x64" PLATFORM: "Windows10+" - MSYS2_PACKAGES: true + MSYS2_PACKAGES: false + WINDEPLOYQT_BIN_PATH: "undefined" DEPLOY: false - job_name: Windows_Qt_5_15_(make_GCC_x86) @@ -184,6 +187,7 @@ environment: PYTHON: "C:\\Python311-x64" PLATFORM: "Windows10+" MSYS2_PACKAGES: false + WINDEPLOYQT_BIN_PATH: "C:\\Qt\\6.4\\mingw_64\\bin" DEPLOY: false - job_name: Windows_Qt_6_4_(MSVC_x64) @@ -199,6 +203,7 @@ environment: PYTHON: "C:\\Python311-x64" PLATFORM: "Windows10+" MSYS2_PACKAGES: false + WINDEPLOYQT_BIN_PATH: "undefined" DEPLOY: false - job_name: Windows_Qt_5_15_(qbs_GCC_x64) @@ -217,6 +222,7 @@ environment: PYTHON: "C:\\Python311-x64" PLATFORM: "Windows7+" MSYS2_PACKAGES: false + WINDEPLOYQT_BIN_PATH: "undefined" DEPLOY: false - job_name: Windows_Qt_5_15_(qbs_MSVC_x64) @@ -232,6 +238,7 @@ environment: PYTHON: "C:\\Python311-x64" PLATFORM: "Windows7+" MSYS2_PACKAGES: false + WINDEPLOYQT_BIN_PATH: "undefined" DEPLOY: false - job_name: Windows_Qt_5_15_(make_GCC_x64) @@ -442,7 +449,7 @@ for: build_script: - conan install . -s os=Windows --build=missing -pr valentina - - qbs build -f valentina.qbs -d %APPVEYOR_BUILD_FOLDER%\build --jobs %NUMBER_OF_PROCESSORS% config:release qbs.installRoot:%APPVEYOR_BUILD_FOLDER%\build\install-root\valentina profile:qt6 project.enableConan:true modules.buildconfig.enableCcache:false project.conanProfiles:valentina modules.buildconfig.enablePCH:%ENABLE_PCH% + - qbs build -f valentina.qbs -d %APPVEYOR_BUILD_FOLDER%\build --jobs %NUMBER_OF_PROCESSORS% config:release qbs.installRoot:%APPVEYOR_BUILD_FOLDER%\build\install-root\valentina profile:qt6 project.enableConan:true modules.buildconfig.enableCcache:false project.conanProfiles:valentina modules.buildconfig.enablePCH:%ENABLE_PCH% modules.windeployqt.windeployqtProgramBinPath:%WINDEPLOYQT_BIN_PATH% test_script: - qbs -p autotest-runner -d %APPVEYOR_BUILD_FOLDER%\build profile:qt6 config:release diff --git a/qbs/modules/windeployqt/windeployqt.qbs b/qbs/modules/windeployqt/windeployqt.qbs index aacbb2d5b..2bd4c6f73 100644 --- a/qbs/modules/windeployqt/windeployqt.qbs +++ b/qbs/modules/windeployqt/windeployqt.qbs @@ -19,6 +19,11 @@ Module { property string windeployqtProgram: "windeployqt.exe" + /** + Setup if need different path to windeployqt tool. + */ + property string windeployqtProgramBinPath: undefined + property string qmake: undefined /** @@ -161,7 +166,11 @@ Module { cmdArgs.push(product.installDir + "\\" + input.fileName); - var cmd = new Command(product.Qt.core.binPath + "/" + windeployqtProgram, cmdArgs); + var windeployqtProgramBinPath = product.Qt.core.binPath; + if (product.windeployqt.windeployqtProgramBinPath !== undefined) + windeployqtProgramBinPath = product.windeployqt.windeployqtProgramBinPath; + + var cmd = new Command(windeployqtProgramBinPath + "/" + windeployqtProgram, cmdArgs); cmd.jobPool = "windeployqt"; cmd.description = "invoking '" + windeployqtProgram; cmd.stdoutFilePath = product.buildDirectory + "/" + product.windeployqt.windeployqtArtifact;