Skip to content

Add iOS Support - #8

Merged
bruvzg merged 1 commit into
godotengine:mainfrom
iMacHumphries:ios-support
Aug 12, 2026
Merged

bruvzg merged 1 commit into
godotengine:mainfrom
iMacHumphries:ios-support

Conversation

@iMacHumphries

Copy link
Copy Markdown
Contributor

Note

AI-assisted: drafted with Claude Code and human-reviewed/tested.

Summary

Adds iOS device and simulator targets to the build matrix, bundled as a single AccessKit.xcframework. This unblocks the in-progress Godot iOS AccessKit integration godotengine/godot#119698 which needs prebuilt iOS slices to link against.

Changes

  • Submodule bump: accesskit-c → 0.22.1 (first release with iOS adapters from AccessKit/accesskit-c#94 and a usable prebuilt-binaries archive; 0.22.0 was skipped due to a release-pipeline issue).
  • Matrix entries (added to both ci.yml and publish.yml):
    • aarch64-apple-ios → lib/ios/arm64/static/libaccesskit.a
    • aarch64-apple-ios-sim → lib/ios-simulator/arm64/static/libaccesskit.a
  • New job package-ios-xcframework (in both workflows): downloads the two iOS artifacts and runs xcodebuild -create-xcframework to produce lib/ios/AccessKit.xcframework. The publish job now depends on this so the xcframework lands in the release zip.

Why xcframework?

iOS device and simulator slices have the same CPU (arm64) but different platform variants and cannot be lipo-merged. An xcframework is Apple's official container that lets Xcode select the correct slice at link time based on the active SDK. The device-only slice ends up in App Store builds; no simulator code is shipped.

Local verification

  • cmake -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_SYSROOT=iphoneos ... + build + install produces a valid arm64 libaccesskit.a at the expected lib/ios/arm64/static/ path.
  • Same for iphonesimulator at lib/ios-simulator/arm64/static/.
  • xcodebuild -create-xcframework produces AccessKit.xcframework with ios-arm64 and ios-arm64-simulator slices and a correct Info.plist (SupportedPlatformVariant=simulator on the second slice).

@iMacHumphries

Copy link
Copy Markdown
Contributor Author

Added -DCMAKE_CONFIGURATION_TYPES=Release to the three MSVC matrix entries in both workflows. This is required by accesskit-c 0.22.x, which bumped Corrosion (the CMake↔Rust glue) from v0.5.1 → v0.6.1. The newer Corrosion sets IMPORTED_LOCATION more strictly on multi-config generators, causing cmake --install --config Release to look in build/RelWithDebInfo/ instead of build/Release/. Pinning to a single Release configuration eliminates the ambiguity. This mirrors what upstream did in accesskit-c#98 for their own publish workflow.

Adds aarch64-apple-ios (device) and aarch64-apple-ios-sim (simulator)
matrix entries to both ci.yml and publish.yml, bumps the accesskit-c
submodule to 0.22.1 (first release with iOS adapters and a usable
prebuilt-binaries archive), and adds a package-ios-xcframework job
that combines the two iOS slices into AccessKit.xcframework via
xcodebuild -create-xcframework.

Locally verified on macOS:
- cmake configure + build + install for both iOS targets produces
  lib/ios/arm64/static/libaccesskit.a and
  lib/ios-simulator/arm64/static/libaccesskit.a (valid arm64 archives).
- xcodebuild -create-xcframework produces a well-formed
  AccessKit.xcframework with ios-arm64 and ios-arm64-simulator slices
  and a correct Info.plist (SupportedPlatformVariant=simulator).

The xcframework lets Godot's iOS export template ship a single bundle
that Xcode automatically slices at link time, so App Store builds
include only the device slice (no simulator code in the .ipa).

The xcframework job is duplicated between ci.yml and publish.yml,
matching the existing matrix-duplication pattern in this repo.

# Conflicts:
#	accesskit-c
@bruvzg
bruvzg merged commit fe462a0 into godotengine:main Aug 12, 2026
21 checks passed
@bruvzg

bruvzg commented Aug 12, 2026

Copy link
Copy Markdown
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants