Fix #11631 - Latest release failed on Windows arm64 and on mac#11632
Conversation
| Python_EXECUTABLE="${{ steps.setup-python.outputs.python-path }}" | ||
| echo "Python_EXECUTABLE=$Python_EXECUTABLE" | ||
| Python_ROOT_DIR=$(dirname "${Python_EXECUTABLE//\\//}") | ||
| echo "Python_ROOT_DIR=$Python_ROOT_DIR" |
There was a problem hiding this comment.
Windows arm64
cmake -G ‘Visual Studio 17 2022’ -A ARM64 -DLINK_WITH_PYTHON:BOOL=ON -DPYTHON_CLI:BOOL=ON -DPython_REQUIRED_VERSION:STRING=3.12.10 ‘-DPython_ROOT_DIR:PATH=C:\hostedtoolcache\windows/Python/3.12.10/arm64/’ -DBUILD_FORTRAN:BOOL=ON -DBUILD_PACKAGE:BOOL=ON -DENABLE_HARDENED_RUNTIME:BOOL=OFF -DDOCUMENTATION_BUILD:STRING=BuildWithAll -DTEX_INTERACTION:STRING=batchmode ../
I'm guessing the issue might be the backslashes in -DPython_ROOT_DIR:PATH=C:\hostedtoolcache\windows/Python/3.12.10/arm64/’
CMake Error at C:/Program Files/CMake/share/cmake-4.3/Modules/FindPackageHandleStandardArgs.cmake:290 (message):
Could NOT find Python (missing: Python_EXECUTABLE Interpreter) (found
suitable exact version "3.12.10")
Reason given by package:
Interpreter: Wrong version for the interpreter "C:/hostedtoolcache/windows/Python/3.13.13/arm64/python.exe"
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-4.3/Modules/FindPackageHandleStandardArgs.cmake:654 (_FPHSA_FAILURE_MESSAGE)
C:/Program Files/CMake/share/cmake-4.3/Modules/FindPython/Support.cmake:4334 (find_package_handle_standard_args)
C:/Program Files/CMake/share/cmake-4.3/Modules/FindPython.cmake:700 (include)
CMakeLists.txt:190 (find_package)
The step setup-python, with debug output enabled
##[debug]Added matchers: ‘python’. Problem matchers scan action output for known warning or error strings and report these inline.
##[debug]Node Action run completed with exit code 0
##[debug]pythonLocation=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]PKG_CONFIG_PATH=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64/lib/pkgconfig’
##[debug]pythonLocation=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]Python_ROOT_DIR=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]Python2_ROOT_DIR=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]Python3_ROOT_DIR=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]PKG_CONFIG_PATH=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64/lib/pkgconfig’
##[debug]Set output python-version = 3.12.10
##[debug]Set output python-path = C:\hostedtoolcache\windows\Python\3.12.10\arm64\python.exe
##[debug]Finishing: Set up Python 3.12.10
| # Download my patched QtIFW | ||
| mkdir QtIFW && cd QtIFW | ||
| aria2c https://github.com/jmarrec/QtIFW-fixup/releases/download/v5.0.0-dev-with-fixup/QtIFW-5.0.0-${{ matrix.arch }}.zip | ||
| aria2c https://github.com/jmarrec/QtIFW-fixup/releases/download/v5.0.0-dev-with-fixup2/QtIFW-5.0.0-${{ matrix.arch }}.zip |
There was a problem hiding this comment.
Update patched QtIFW to a newer version: https://github.com/jmarrec/QtIFW-fixup/releases/tag/v5.0.0-dev-with-fixup2
Fix a typo in flags passed to codesign: should be --options not --option
I also updated the target branch onto installer-framework 4.11.0: https://github.com/jmarrec/installer-framework/tree/QTIFW-3084-more-4_11_0
And Updated qt6 static to 6.11.0 (from 6.7.2) since I couldn't build with my macOS 26.5 with clang 21 (and even then, had to cherry pick one Qt commit thart's only on Qt's dev branch...)
```
Windows arm64
##[debug]Added matchers: ‘python’. Problem matchers scan action output for known warning or error strings and report these inline.
##[debug]Node Action run completed with exit code 0
##[debug]pythonLocation=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]PKG_CONFIG_PATH=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64/lib/pkgconfig’
##[debug]pythonLocation=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]Python_ROOT_DIR=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]Python2_ROOT_DIR=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]Python3_ROOT_DIR=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64’
##[debug]PKG_CONFIG_PATH=‘C:\hostedtoolcache\windows\Python\3.12.10\arm64/lib/pkgconfig’
##[debug]Set output python-version = 3.12.10
##[debug]Set output python-path = C:\hostedtoolcache\windows\Python\3.12.10\arm64\python.exe
##[debug]Finishing: Set up Python 3.12.10
cmake -G ‘Visual Studio 17 2022’ -A ARM64 -DLINK_WITH_PYTHON:BOOL=ON -DPYTHON_CLI:BOOL=ON -DPython_REQUIRED_VERSION:STRING=3.12.10 ‘-DPython_ROOT_DIR:PATH=C:\hostedtoolcache\windows/Python/3.12.10/arm64/’ -DBUILD_FORTRAN:BOOL=ON -DBUILD_PACKAGE:BOOL=ON -DENABLE_HARDENED_RUNTIME:BOOL=OFF -DDOCUMENTATION_BUILD:STRING=BuildWithAll -DTEX_INTERACTION:STRING=batchmode ../
```
I'm guessing this is the backslash
```
CMake Error at C:/Program Files/CMake/share/cmake-4.3/Modules/FindPackageHandleStandardArgs.cmake:290 (message):
Could NOT find Python (missing: Python_EXECUTABLE Interpreter) (found
suitable exact version "3.12.10")
Reason given by package:
Interpreter: Wrong version for the interpreter "C:/hostedtoolcache/windows/Python/3.13.13/arm64/python.exe"
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-4.3/Modules/FindPackageHandleStandardArgs.cmake:654 (_FPHSA_FAILURE_MESSAGE)
C:/Program Files/CMake/share/cmake-4.3/Modules/FindPython/Support.cmake:4334 (find_package_handle_standard_args)
C:/Program Files/CMake/share/cmake-4.3/Modules/FindPython.cmake:700 (include)
CMakeLists.txt:190 (find_package)
```
…n cmake 4.3.0) amr64 detection on windows passing `-DPython_EXECUTABLE:FILEPATH=<...>`bypasses the entire discovery phase, handing CMake a pre-validated path so `_PYTHON_VALIDATE_INTERPRETER` never needs to search I fixed the issue upstream in cmake but it won't be released soon enough: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/12158
https://github.com/jmarrec/QtIFW-fixup/releases/tag/v5.0.0-dev-with-fixup2 Fix a typo in flags passed to codesign: should be --options not --option, which may explain why the --options runtime wasn't applied to the install .app itself I also updated the target branch onto installer-framework 4.11.0: https://github.com/jmarrec/installer-framework/tree/QTIFW-3084-more-4_11_0 And Updated qt6 static to 6.11.0 (from 6.7.2) since I couldn't build with my macOS 26.5 with clang 21 (and even then, had to cherry pick one commit...)
946e520 to
591e833
Compare
| Python_EXECUTABLE="${{ steps.setup-python.outputs.python-path }}" | ||
| Python_EXECUTABLE="${Python_EXECUTABLE//\\//}" | ||
| cmake -G "Visual Studio 17 2022" -A ${{ matrix.vs-generator }} \ | ||
| -DLINK_WITH_PYTHON:BOOL=ON -DPYTHON_CLI:BOOL=ON \ | ||
| -DPython_REQUIRED_VERSION:STRING=${{ steps.setup-python.outputs.python-version }} \ | ||
| -DPython_ROOT_DIR:PATH=$RUNNER_TOOL_CACHE/Python/${{ steps.setup-python.outputs.python-version }}/${{ matrix.python-arch }}/ \ | ||
| -DPython_EXECUTABLE:FILEPATH="$Python_EXECUTABLE" \ | ||
| -DPython_ROOT_DIR:PATH="$(dirname "$Python_EXECUTABLE")" \ |
There was a problem hiding this comment.
Explicitly pass Python_EXECUTABLE to avoid a broken FindPython (new in cmake 4.3.0) arm64 detection on windows
passing -DPython_EXECUTABLE:FILEPATH=<...>bypasses the entire discovery phase, handing CMake a pre-validated path so _PYTHON_VALIDATE_INTERPRETER never needs to search
I fixed the issue upstream in cmake but it won't be released soon enough: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/12158
(I'm also doing forward slashes now, as I thought it could be the root cause and it's more correct for cmake)
| aria2c https://github.com/jmarrec/QtIFW-fixup/releases/download/v4.11.0-Patched/QtIFW-4.11.0-${{ matrix.arch }}.zip | ||
| xattr -r -d com.apple.quarantine ./QtIFW-4.11.0-${{ matrix.arch }}.zip | ||
| unzip QtIFW-4.11.0-${{ matrix.arch }}.zip |
There was a problem hiding this comment.
I think the mac failure was actually a fluke to begin with.
But I did go into (a very lenghty) endeavor where I updated my patched qtifw to be based on qtifw 4.11.0, and qt 6.9.1. https://github.com/jmarrec/QtIFW-fixup/releases/tag/v4.11.0-Patched
Pull request overview
Description of the purpose of this PR
Pull Request Author
Reviewer