diff options
| author | Alexandru Croitor <alexandru.croitor@qt.io> | 2025-12-11 15:47:13 +0100 |
|---|---|---|
| committer | Alexandru Croitor <alexandru.croitor@qt.io> | 2025-12-11 21:09:43 +0100 |
| commit | 97b79c80e54d85a65f0070fe9851ad818985f8c6 (patch) | |
| tree | 4434fbde491a164418842b77ed51f389cea610fe /examples/widgets/dialogs/findfiles/main.cpp | |
| parent | 07d590c4f4851a67913f8c6c708f1f6526299fdc (diff) | |
When building an iOS / xrOS user project against a single-arch (so
single SDK) Qt build, we used to force set the CMAKE_OSX_SYSROOT to
the device SDK and set the Xcode attribute SUPPORTED_PLATFORMS to the
simulator SDK.
This worked when building the project with Xcode, but didn't work
when building with xcodebuild without explicitly specifying the
simulator SDK as an argument to xcodebuild.
Instead of doing this force setting of the SDK / sysroot, keep the
CMAKE_OSX_SYSROOT value which is decided in the Qt toolchain file
(this only applies to single-SDK Qt builds).
That's usually the SDK that Qt was configured with.
Because xcodebuild tries to build all possible architectures for a
specific SDK by default if CMAKE_OSX_ARCHITECTURES is empty, we need
to ensure a single architecture is chosen (the only available one).
We do this by setting CMAKE_OSX_ARCHITECTURES in the toolchain
file to the only available architecture that Qt was configured with.
We do this only for Xcode generator, and only for a single-arch build.
This used to be done before, but regressed because we didn't store the
QT_APPLE_SDK value in __qt_apple_sdk anymore.
These changes ensures user projects build both with Xcode and
xcodebuild without any extra args or manual adjustments.
Amends 0041ddce7420aafdb8bb032058a42d47afa34c6d
Amends e23ea6a5d3bf09921bb98150a4f0f504e77ef4a3
Pick-to: 6.8 6.10 6.11
Change-Id: I98bb7b6b3a86f831fa6f02bcadc4b1bbd22464ac
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Diffstat (limited to 'examples/widgets/dialogs/findfiles/main.cpp')
0 files changed, 0 insertions, 0 deletions
