diff --git a/.github/autobuild/ios.sh b/.github/autobuild/ios.sh index 211666db04..7a5c8e931a 100755 --- a/.github/autobuild/ios.sh +++ b/.github/autobuild/ios.sh @@ -26,7 +26,7 @@ set -eu -QT_DIR=/usr/local/opt/qt +QT_DIR=/opt/qt # The following version pinnings are semi-automatically checked for # updates. Verify .github/workflows/bump-dependencies.yaml when changing those manually: AQTINSTALL_VERSION=3.1.18 @@ -45,7 +45,15 @@ setup() { echo "Using Qt installation from previous run (actions/cache)" else echo "Installing Qt" - python3 -m pip install "aqtinstall==${AQTINSTALL_VERSION}" + # We may need to create the Qt installation directory and chown it to the runner user to fix permissions + sudo mkdir -p "${QT_DIR}" + sudo chown "$(whoami)" "${QT_DIR}" + # Create and enter virtual environment + python3 -m venv venv + # Must hide directory as it just gets created during execution of the previous command and cannot be found by shellcheck + # shellcheck source=/dev/null + source venv/bin/activate + pip install "aqtinstall==${AQTINSTALL_VERSION}" # Install actual ios Qt: local qtmultimedia=() if [[ ! "${QT_VERSION}" =~ 5\.[0-9]+\.[0-9]+ ]]; then @@ -58,14 +66,13 @@ setup() { if [[ ! "${QT_VERSION}" =~ 5\.[0-9]+\.[0-9]+ ]]; then # Starting with Qt6, ios' qtbase install does no longer include a real qmake binary. # Instead, it is a script which invokes the mac desktop qmake. - # As of aqtinstall 2.1.0 / 04/2022, desktop qtbase has to be installed manually: - python3 -m aqt install-qt --outputdir "${QT_DIR}" mac desktop "${QT_VERSION}" --archives qtbase + # As of aqtinstall 2.1.0 / 04/2022, desktop qtbase and qttools including lrelease have to be installed manually: + python3 -m aqt install-qt --outputdir "${QT_DIR}" mac desktop "${QT_VERSION}" --archives qtbase qttools fi - # Suppress deprecation of Legacy Build System for now. - # TODO: Legacy Build System is removed in xcode 14. Need to migrate - # to the Modern Build System instead. - /usr/libexec/PlistBuddy -c "Add :DisableBuildSystemDeprecationDiagnostic bool true" /usr/local/opt/qt/"${QT_VERSION}"/ios/mkspecs/macx-xcode/WorkspaceSettings.xcsettings + # deactivate and remove venv as aqt is no longer needed from here on + deactivate + rm -rf venv fi } diff --git a/.github/workflows/autobuild.yml b/.github/workflows/autobuild.yml index 2fd765178d..f50d6fa0d8 100644 --- a/.github/workflows/autobuild.yml +++ b/.github/workflows/autobuild.yml @@ -250,15 +250,13 @@ jobs: - config_name: iOS (artifacts) target_os: ios - building_on_os: macos-12 - base_command: QT_VERSION=5.15.2 ./.github/autobuild/ios.sh + building_on_os: macos-14 + base_command: QT_VERSION=6.7.3 ./.github/autobuild/ios.sh # Build failed with CodeQL enabled when last tested 03/2022 (#2490). # There are no hints that iOS is supposed to be supported by CodeQL. # Therefore, disable it: run_codeql: false - # Unfortunately, more modern Xcode versions no longer seem to support - # Qt 5.15.2. Therefore upgrading to Qt6 is needed in the medium term (#2711) - xcode_version: 13.4.1 + xcode_version: 15.4.0 - config_name: Windows (artifact+codeQL) target_os: windows