Skip to content

Apple Platform (iOS / macOS)

This page records the current build status of the Apple platform, not end-to-end integration steps. The Apple README says: “Not a skeleton any more, and not a product either.” The distinction is whether the compiler has seen it; this section therefore reports only what the compiler has seen.

No code has run on an iPhone. The G0 probe (ProbeApp/) is the first Mac task; product selection will be determined by probe evidence, not prescribed in advance by any document in this repository.

Component Status
core/ (MigoAppleCore) Built, tested, and cross-compiled as aarch64-apple-ios on an Apple silicon runner for every PR
Sources/MigoAppleRenderer Apple SDK workflow builds iOS/simulator shipping slices and a standalone macOS external-frame diagnostic package; the macOS diagnostic package is not a V8 product test
Sources/MigoAppleWebKit Placeholder; compiles, with no behavior
Sources/MigoMacV8 Placeholder; compiles, with no behavior
WebContent/PerformancePlus The encoder runs against the same golden corpus under node on every PR
ProbeApp/ README only; no source files, and there should be none until a real device can run it
Product Where content JS runs Renderer Enters v1
MigoAppleWebKit WebContent, the full Web platform WebKit Yes
MigoApplePerformancePlus WebContent, Worker or Window (selected by the G0 probe) In-process: Skia + ANGLE/Metal Conditional
MigoMacV8 In-process, V8 with JIT In-process: Skia + ANGLE/Metal Yes (macOS only)

MigoAppleRenderer is shared by the two native rendering lanes, Performance+ and MacV8; MigoAppleWebKit intentionally does not depend on it—a host requesting the compatibility baseline should not link a renderer that will never drive anything.

The repository contains two packages; the split reflects meaningful payload boundaries:

  • platforms/apple/core/Package.swift (MigoAppleCore): no engine dependency and can be resolved, built, and tested without fetching or building anything else. It contains profile policy, deployment floor, lifecycle, permissions, and metrics.
  • platforms/apple/Package.swift (shipping package): declares a binary target pointing to the xcframework generated by scripts/build-apple-sdk.sh; it cannot be resolved before that script runs on a Mac. This means that while this skeleton remains, no Swift files are compiled—including those that mirror contracts/apple/*.json and only compare text. core/ is the engine-free half, so it is built and tested on every PR.

include/migo/platform/ios.h declares two iOS surface descriptors:

  • MigoIosUiViewDescriptor: holds a host-owned UIView* (the convenience path; Host Kit creates and owns the view’s sole CAMetalLayer backing).
  • MigoIosMetalLayerDescriptor: holds a host-owned CAMetalLayer* (the Performance+ lane requires a host-owned Metal surface; this is the authoritative path).

include/migo/platform/macos.h declares two macOS surface descriptors:

  • MigoMacosNsViewDescriptor: holds a host-owned NSView* (the comment marks it as “A future implementation”).
  • MigoMacosMetalLayerDescriptor: holds a host-owned CAMetalLayer*. Mounting a CAMetalLayer on macOS has run in CI (apple-sdk.yml run 34017950809), completing the full retirement handshake: begin_detach, polling until MIGO_SURFACE_RELEASE_RELEASED, migo_surface_release_destroy, migo_session_destroy, and migo_engine_destroy.

core/ has no engine dependency and can be independently resolved, built, and tested:

终端窗口
bash scripts/test-apple-swift-core-engine-free.sh

The shipping package requires ANGLE to be installed and the SDK to be built, on macOS only:

终端窗口
bash scripts/fetch-apple-angle.sh ios
bash scripts/fetch-apple-angle.sh ios-simulator
export MIGO_APPLE_BUILD_ROOT=/tmp/migo-apple-build
bash scripts/build-apple-sdk.sh --platform ios --configuration Release
bash scripts/build-apple-sdk.sh --platform ios-simulator --configuration Release

This produces platforms/apple/Frameworks/MigoEngine.xcframework, containing iOS device and iOS simulator platform groups.

macOS external-frame renderer/ABI diagnostic test (not a V8 product test):

终端窗口
bash scripts/build-apple-sdk.sh --platform macos \
--product external-frames-diagnostic --configuration Debug

Packaging contracts can be verified without Xcode:

终端窗口
bash scripts/test-apple-shipping-package-contract.sh
bash scripts/test-apple-sdk-packaging.sh

The following is currently unavailable; do not use this page as a basis for attempting it:

  • Steps for running Migo on an iPhone or iPad—ProbeApp/ has no source files, and the G0 probe has not yet run.
  • An application session implementation for MigoAppleWebKit or MigoMacV8—the Swift placeholders compile but implement no session logic.
  • A macOS V8 shipping artifact—the README explicitly says the SDK workflow does not publish a macOS V8 release and does not claim to have built a macOS V8 archive; a compiling placeholder is not a complete product.

See BUILD.md and platforms/apple/README.md in the repository for build details.