Skip to content

Commit dfb75d8

Browse files
committed
fix(ios): match official Qt simulator architecture and OS baseline
1 parent 140a9af commit dfb75d8

4 files changed

Lines changed: 17 additions & 8 deletions

File tree

‎.github/workflows/ios-review.yml‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ permissions:
88
jobs:
99
simulator:
1010
if: github.ref == 'refs/heads/feature/ios'
11-
runs-on: macos-15
11+
runs-on: macos-15-intel
1212
timeout-minutes: 90
1313
steps:
1414
- uses: actions/checkout@v4
@@ -30,7 +30,7 @@ jobs:
3030
shell: bash
3131
env:
3232
APPLE_SDK: iphonesimulator
33-
APPLE_ARCH: arm64
33+
APPLE_ARCH: x86_64
3434
BUILD_JOBS: '4'
3535
run: tools/build-ios.sh
3636
- name: Smoke native startup on simulator
@@ -39,10 +39,10 @@ jobs:
3939
device="$(xcrun simctl list devices available --json | python3 -c 'import json,sys; print(next(d["udid"] for ds in json.load(sys.stdin)["devices"].values() for d in ds if d["name"].startswith("iPhone")))')"
4040
xcrun simctl boot "$device"
4141
xcrun simctl bootstatus "$device" -b
42-
bundle="build/apple/iphonesimulator-arm64/app/Release-iphonesimulator/Spool.app"
42+
bundle="build/apple/iphonesimulator-x86_64/app/Release-iphonesimulator/Spool.app"
4343
xcrun simctl install "$device" "$bundle"
4444
xcrun simctl launch --console "$device" com.sachk.spool --launch-test
4545
- uses: actions/upload-artifact@v4
4646
with:
4747
name: ios-review-simulator
48-
path: build/apple/iphonesimulator-arm64/app/Release-iphonesimulator/Spool.app
48+
path: build/apple/iphonesimulator-x86_64/app/Release-iphonesimulator/Spool.app

‎README.md‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,12 @@ or App Store-approved platform. Its native build requires macOS, Xcode and
468468
matching host/iOS Qt kits at the version in `tools/manifests/toolchain.json`.
469469
Set `QT_HOST_PATH` and `QT_TARGET_PREFIX`, then run `tools/build-ios.sh`.
470470
`APPLE_SDK=iphonesimulator` selects the simulator; the default is `iphoneos`.
471-
`APPLE_ARCH` selects `arm64` or simulator `x86_64`. The shared
471+
The device architecture defaults to `arm64`, the official Qt simulator kit to
472+
`x86_64`. Apple Silicon Macs require Rosetta for this simulator kit; the review
473+
workflow uses an Intel macOS runner. A custom source-built Qt kit can select
474+
`APPLE_ARCH=arm64` for the simulator. The deployment baseline is iOS 17,
475+
matching [Qt 6.11's supported configuration](https://doc.qt.io/qt-6.11/ios.html).
476+
The shared
472477
`tools/apple/build-dependencies.sh` verifies existing dependency pins and builds
473478
static FFmpeg, curl/OpenSSL, subtitle libraries, libplacebo, mpv and QCoro for
474479
the selected SDK. Qt and application code use OpenGL ES; no desktop AppKit,

‎tools/apple/build-dependencies.sh‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ source "$ROOT/tools/lib/manifest-sources.sh"
66
APPLE_SYSTEM="${APPLE_SYSTEM:-iOS}"
77
APPLE_SDK="${APPLE_SDK:-iphoneos}"
88
APPLE_ARCH="${APPLE_ARCH:-arm64}"
9-
APPLE_DEPLOYMENT_TARGET="${APPLE_DEPLOYMENT_TARGET:-16.0}"
9+
APPLE_DEPLOYMENT_TARGET="${APPLE_DEPLOYMENT_TARGET:-17.0}"
1010
case "$APPLE_SYSTEM:$APPLE_SDK" in
1111
iOS:iphoneos) target_os=ios ;;
1212
iOS:iphonesimulator) target_os=ios; simulator=-simulator ;;

‎tools/build-ios.sh‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,12 @@ ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
66
: "${QT_HOST_PATH:?Set QT_HOST_PATH to the matching macOS Qt kit}"
77
export APPLE_SYSTEM=iOS
88
export APPLE_SDK="${APPLE_SDK:-iphoneos}"
9-
export APPLE_ARCH="${APPLE_ARCH:-arm64}"
10-
export APPLE_DEPLOYMENT_TARGET="${APPLE_DEPLOYMENT_TARGET:-16.0}"
9+
if [[ "$APPLE_SDK" == iphonesimulator ]]; then
10+
export APPLE_ARCH="${APPLE_ARCH:-x86_64}"
11+
else
12+
export APPLE_ARCH="${APPLE_ARCH:-arm64}"
13+
fi
14+
export APPLE_DEPLOYMENT_TARGET="${APPLE_DEPLOYMENT_TARGET:-17.0}"
1115
BASE="$ROOT/build/apple/$APPLE_SDK-$APPLE_ARCH"
1216
export APPLE_DEPS_PREFIX="${APPLE_DEPS_PREFIX:-$BASE/prefix}"
1317
if [[ "${BUILD_DEPENDENCIES:-1}" == 1 ]]; then "$ROOT/tools/apple/build-dependencies.sh"; fi

0 commit comments

Comments
 (0)