Skip to content

Add iOS platform support#118

Open
shiena wants to merge 5 commits intostechyo:masterfrom
shiena:feature/ios-support
Open

Add iOS platform support#118
shiena wants to merge 5 commits intostechyo:masterfrom
shiena:feature/ios-support

Conversation

@shiena
Copy link

@shiena shiena commented Feb 15, 2026

Follow up #87

Summary

  • Add iOS (arm64) build support for the GDExtension
  • SConstruct: Add iOS platform detection and static library output (.a) instead of shared library
  • gdextension: Add iOS library entries and static library dependencies (godot-cpp, libphonon, pffft, libmysofa)
  • Makefile: Add ios-deps target to build pffft and libmysofa for iOS, and ios-release target with godot-cpp copy
  • CI: Add iOS build step to macOS workflow
  • Add pffft and libmysofa as git submodules under src/lib/

Why static libraries need extra dependencies

iOS requires static libraries (.a), unlike other platforms which use shared libraries (.dylib/.so/.dll).
Shared libraries resolve all symbols at build time, but static libraries defer symbol resolution to the final Xcode link stage.
Therefore godot-cpp, pffft, and libmysofa must be explicitly provided as dependencies in the gdextension file.

New submodules

  • src/lib/pffft — FFT library required by Steam Audio
  • src/lib/libmysofa — SOFA (HRTF) reader library required by Steam Audio

These are only needed for the iOS static build. On other platforms, they are already linked into the shared libphonon library.

Verified

  • iPhone 15 Pro / iOS 26.3 / Godot 4.6

- Add iOS build configuration in SConstruct (static library, LIBPATH)
- Add ios-release target and iOS lib copy in Makefile
- Add iOS entries to gdextension file
- Add iOS build step to GitHub Actions macOS job
iOS uses static libraries (.a) unlike other platforms' shared libraries,
so godot-cpp, pffft, and libmysofa must be provided separately at final
link time. Add ios-deps Makefile target to build pffft and libmysofa from
source, copy godot-cpp after scons build, and declare all dependencies
in the gdextension file.
Keep the ios/ directory in the repository so CI copy commands
work without needing mkdir, consistent with android/ directories.
Add pffft and libmysofa as git submodules under src/lib/, consistent
with how godot-cpp and steamaudio are managed. Update Makefile ios-deps
to build from submodule paths instead of cloning into a temp directory.
iOS does not support Embree, so fall back to the default scene type,
consistent with the existing macOS ARM64 and Android fallbacks.
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.

1 participant