Repository navigation
Android source builds fail at configureBuildForHermes since facebook/hermes moved to meta/hermes #59587
Description
Description
Since facebook/hermes moved to meta/hermes (2026-10-28), building React Native from source on Android fails at :packages:react-native:ReactAndroid:hermes-engine:configureBuildForHermes.
Cause:
-
downloadHermesfetcheshttps://github.com/facebook/hermes/tarball/<tag>. That URL now redirects (301) tometa/hermes, so the download itself still works. -
GitHub names a tarball's top-level folder
<owner>-<repo>-<sha>, so it is nowmeta-hermes-<sha>/rather thanfacebook-hermes-<sha>/:$ curl -sL https://github.com/facebook/hermes/tarball/hermes-v260318099.0.2 | tar -tz | head -1 meta-hermes-4188b63/ -
unzipHermesonly flattens entries that start withfacebook-hermes-. So Hermes is extracted tosdks/hermes/meta-hermes-<sha>/, and CMake finds noCMakeLists.txtinsdks/hermes.
Who's affected: anyone building React Native from source on Android, e.g. via includeBuild + dependencySubstitution or Expo's buildReactNativeFromSource, whenever Hermes has to be downloaded again (CI, fresh clones, fresh node_modules). Apps using the prebuilt artifacts don't download Hermes, so they're unaffected. main (as of dee5bb5) and 0.88-stable both still have the facebook-hermes- check.
Proposed fix: strip the tarball's single top-level folder unconditionally, the same way the folly, fmt and fast_float download tasks in ReactAndroid/build.gradle.kts already do. That no longer depends on the repo owner and behaves the same for the old tarballs. Pointing the download URL at meta/hermes would also stop relying on the redirect. I'll open a PR.
(Not the same as #59514, which touches the same file but is about a stale CMake cache after the source directory moves.)
Steps to reproduce
- Clone https://github.com/mozzius/hermes-tarball-repro. It's the community reproducer template (React Native 0.88.1) with one change:
android/settings.gradlebuilds React Native from source. - Run
cd ReproducerApp && yarn && cd android && ./gradlew :app:assembleDebug -PreactNativeArchitectures=arm64-v8a. - The build fails within about 30 seconds at
configureBuildForHermes(log below).
The repo's fixed branch applies the proposed change with patch-package. With it, unzipHermes, configureBuildForHermes, buildHermesC and prepareHeadersForPrefab all pass, and CMakeLists.txt lands directly in sdks/hermes.
React Native Version
0.88.1
Affected Platforms
Runtime - Android, Build - MacOS
Output of npx @react-native-community/cli info
System:
OS: macOS 27.0.1
CPU: (14) arm64 Apple M4 Pro
Shell:
version: 5.3.20
path: /opt/homebrew/bin/bash
Binaries:
Node:
version: 24.22.1
Yarn:
version: 1.22.22
npm:
version: 11.19.1
Watchman:
version: 2026.10.19.00
SDKs:
Android SDK:
API Levels:
- "35"
- "36"
- "37"
Build Tools:
- 36.0.0
- 37.0.0
IDEs:
Android Studio: 2026.1 AI-261.26222.65.2614.16379836
Languages:
Java:
version: 17.0.20.1
npmPackages:
"@react-native-community/cli":
installed: 20.2.0
wanted: 20.2.0
react:
installed: 19.3.0
wanted: 19.3.0
react-native:
installed: 0.88.1
wanted: 0.88.1
Android:
hermesEnabled: true
newArchEnabled: true
Stacktrace or Logs
> Task :react-native:packages:react-native:ReactAndroid:hermes-engine:downloadHermes
> Task :react-native:packages:react-native:ReactAndroid:hermes-engine:unzipHermes
> Task :react-native:packages:react-native:ReactAndroid:hermes-engine:configureBuildForHermes FAILED
CMake Error: The source directory ".../ReproducerApp/node_modules/react-native/sdks/hermes" does not appear to contain CMakeLists.txt.
Specify --help for usage, or press the help button on the CMake GUI.
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':react-native:packages:react-native:ReactAndroid:hermes-engine:configureBuildForHermes'.
> Process 'command '.../cmake/3.30.5/bin/cmake'' finished with non-zero exit value 1
BUILD FAILED in 30s
MANDATORY Reproducer
https://github.com/mozzius/hermes-tarball-repro
Screenshots and Videos
No response
Activity
mozzius commentedon Oct 28, 2026
Fixed by #59589