Skip to content

Use the prebuilt Hermes archive for iOS builds - #441

Merged
kraenhansen merged 1 commit into
nextfrom
claude/hermes-prebuilt-consume-zk13mc
Aug 13, 2026
Merged

Use the prebuilt Hermes archive for iOS builds#441
kraenhansen merged 1 commit into
nextfrom
claude/hermes-prebuilt-consume-zk13mc

Conversation

@kraenhansen

@kraenhansen kraenhansen commented Aug 13, 2026

Copy link
Copy Markdown
Collaborator

Hermes is the iOS build: 17m15s of an 18m58s Build test app step, measured in #439. This points pod install at the prebuilt archive instead.

What changes

scripts/patch-hermes.rb sets HERMES_ENGINE_TARBALL_PATH from prebuilt-hermes instead of REACT_NATIVE_OVERRIDE_HERMES_DIR from vendor-hermes. hermes_source_type() then returns LOCAL_PREBUILT_TARBALL, and the [RN] [1] Build Hermesc / [RN] [2] Build Hermes script phases don't run at all.

Building from source stays available as a manually-activated fallback, and is the faster loop while iterating on Hermes itself — Xcode rebuilds it incrementally, rather than re-packaging an archive every cycle:

REACT_NATIVE_NODE_API_HERMES_FROM_SOURCE=1 pod install

Setting REACT_NATIVE_OVERRIDE_HERMES_DIR or HERMES_ENGINE_TARBALL_PATH yourself still takes precedence over both. Android is untouched — it keeps building from the vendor-hermes checkout through Gradle.

react-native-macos also stays on the source path, since the archive is only produced and exercised for the iOS platforms. The steps to move it over are written up in #392, which is where that work is already gated.

CI

test-ios gets an actions/cache keyed by the archive name, and an explicit Build prebuilt Hermes step. The step is explicit so a cold cache shows up in the job log as its own step rather than as a mysteriously slow pod install.

The archive for this pin and React Native version is already published, so that step downloads 118 MB rather than building. It only builds locally — around half an hour — when neither the cache nor the release has a matching archive, which is what a bumped pin looks like before its Hermes prebuilt run finishes.

Test plan

  • Test app (iOS) passes (label-gated on Apple 🍎, attached)
  • Build prebuilt Hermes downloads the published archive instead of building
  • pod install logs [Node-API] Using prebuilt Hermes from ..., and no [RN] [1]/[2] Build Hermes* phase appears in the Xcode build
  • A second run on the same commit hits the Hermes cache
  • Android is unaffected — Test app (Android) still resolves REACT_NATIVE_OVERRIDE_HERMES_DIR through vendor-hermes

This is the first exercise of the consuming side: everything merged so far only proves the archive can be produced, not that pod install accepts one and the app runs. That can't be checked from a Linux worker. The type-check, lint, prettier, depcheck and publint all pass.

@kraenhansen kraenhansen added CI Continuous integration Apple 🍎 Anything related to the Apple platform (iOS, macOS, Cocoapods, Xcode, XCFrameworks, etc.) labels Aug 13, 2026 — with Claude
Base automatically changed from claude/hermes-source-build-cache-zk13mc to next August 13, 2026 15:00
@kraenhansen
kraenhansen force-pushed the claude/hermes-prebuilt-consume-zk13mc branch from b086bcf to 1b3af19 Compare August 13, 2026 16:51
@kraenhansen
kraenhansen changed the base branch from next to claude/hermes-prebuilt-visionos-env-zk13mc August 13, 2026 16:51
Base automatically changed from claude/hermes-prebuilt-visionos-env-zk13mc to next August 13, 2026 17:07
Hermes is the iOS build: 17m15s of an 18m58s "Build test app" step. Point
pod install at the archive built by `prebuilt-hermes` through
HERMES_ENGINE_TARBALL_PATH, so hermes-engine.podspec vendors the prebuilt
frameworks and its two Hermes script phases don't run at all.

Building from source stays available behind
REACT_NATIVE_NODE_API_HERMES_FROM_SOURCE=1, which is the faster loop while
iterating on Hermes itself. react-native-macos stays on that path for now,
see #392.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UkNbgdyuKgHaFwT27RahGH
@kraenhansen
kraenhansen force-pushed the claude/hermes-prebuilt-consume-zk13mc branch from 1b3af19 to 233fe34 Compare August 13, 2026 17:16
@kraenhansen
kraenhansen merged commit 56ae5f8 into next Aug 13, 2026
16 checks passed
@kraenhansen
kraenhansen deleted the claude/hermes-prebuilt-consume-zk13mc branch August 13, 2026 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Apple 🍎 Anything related to the Apple platform (iOS, macOS, Cocoapods, Xcode, XCFrameworks, etc.) CI Continuous integration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant