Fix Windows ARM64 builds on x64 on Qt 6.10.1+
This commit is contained in:
parent
60fd840d7a
commit
d878447413
1 changed files with 21 additions and 11 deletions
|
|
@ -33,11 +33,15 @@ if /I "%BUILD_CONFIG%"=="debug" (
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
rem Locate qmake and determine if we're using qmake.exe or qmake.bat
|
rem Locate qmake and determine if we're using qmake.exe or (host-)qmake.bat
|
||||||
rem qmake.bat is an ARM64 forwarder to the x64 version of qmake.exe
|
rem (host-)qmake.bat is an ARM64 forwarder to the x64 version of qmake.exe
|
||||||
where qmake.bat
|
where qmake.bat
|
||||||
if !ERRORLEVEL! EQU 0 (
|
if !ERRORLEVEL! EQU 0 (
|
||||||
set QMAKE_CMD=call qmake.bat
|
set QMAKE_CMD=call qmake.bat
|
||||||
|
) else (
|
||||||
|
where host-qmake.bat
|
||||||
|
if !ERRORLEVEL! EQU 0 (
|
||||||
|
set QMAKE_CMD=call host-qmake.bat
|
||||||
) else (
|
) else (
|
||||||
where qmake.exe
|
where qmake.exe
|
||||||
if !ERRORLEVEL! EQU 0 (
|
if !ERRORLEVEL! EQU 0 (
|
||||||
|
|
@ -47,6 +51,7 @@ if !ERRORLEVEL! EQU 0 (
|
||||||
goto Error
|
goto Error
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
)
|
||||||
|
|
||||||
rem Find Qt path to determine our architecture
|
rem Find Qt path to determine our architecture
|
||||||
for /F %%i in ('where qmake') do set QT_PATH=%%i
|
for /F %%i in ('where qmake') do set QT_PATH=%%i
|
||||||
|
|
@ -64,6 +69,10 @@ if not x%QT_PATH:_arm64=%==x%QT_PATH% (
|
||||||
set HOSTBIN_PATH=%QT_PATH:_arm64=_64%
|
set HOSTBIN_PATH=%QT_PATH:_arm64=_64%
|
||||||
echo HOSTBIN_PATH=!HOSTBIN_PATH!
|
echo HOSTBIN_PATH=!HOSTBIN_PATH!
|
||||||
|
|
||||||
|
if exist %QT_PATH%\host-qtpaths.bat (
|
||||||
|
echo Using windeployqt.exe from HOSTBIN_PATH
|
||||||
|
set WINDEPLOYQT_CMD=!HOSTBIN_PATH!\windeployqt.exe --qtpaths %QT_PATH%\host-qtpaths.bat
|
||||||
|
) else (
|
||||||
if exist %QT_PATH%\windeployqt.exe (
|
if exist %QT_PATH%\windeployqt.exe (
|
||||||
echo Using windeployqt.exe from QT_PATH
|
echo Using windeployqt.exe from QT_PATH
|
||||||
set WINDEPLOYQT_CMD=windeployqt.exe
|
set WINDEPLOYQT_CMD=windeployqt.exe
|
||||||
|
|
@ -71,6 +80,7 @@ if not x%QT_PATH:_arm64=%==x%QT_PATH% (
|
||||||
echo Using windeployqt.exe from HOSTBIN_PATH
|
echo Using windeployqt.exe from HOSTBIN_PATH
|
||||||
set WINDEPLOYQT_CMD=!HOSTBIN_PATH!\windeployqt.exe --qtpaths %QT_PATH%\qtpaths.bat
|
set WINDEPLOYQT_CMD=!HOSTBIN_PATH!\windeployqt.exe --qtpaths %QT_PATH%\qtpaths.bat
|
||||||
)
|
)
|
||||||
|
)
|
||||||
) else (
|
) else (
|
||||||
if not x%QT_PATH:_64=%==x%QT_PATH% (
|
if not x%QT_PATH:_64=%==x%QT_PATH% (
|
||||||
set ARCH=x64
|
set ARCH=x64
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue