Skip to content

Commit

Permalink
[android] Support caching prebuilt hermes-engine
Browse files Browse the repository at this point in the history
  • Loading branch information
Kudo authored and alanjhughes committed Apr 8, 2024
1 parent def653d commit 546eb41
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
9 changes: 9 additions & 0 deletions packages/react-native/ReactAndroid/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -502,6 +502,8 @@ android {
ndkVersion = libs.versions.ndkVersion.get()
}

resourcePrefix = "reactandroid_"

compileOptions {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
Expand Down Expand Up @@ -768,6 +770,13 @@ dependencies {
compileOnly(libs.javax.annotation.api)
api(libs.javax.inject)

if (!buildHermesSource) {
debugCompileOnly(files("${prebuiltHermesDir}/hermes-engine-debug.aar"))
releaseCompileOnly(files("${prebuiltHermesDir}/hermes-engine-release.aar"))
} else {
compileOnly(project(":packages:react-native:ReactAndroid:hermes-engine"))
}

// It's up to the consumer to decide if hermes should be included or not.
// Therefore hermes-engine is a compileOnly dependency.
compileOnly(project(":packages:react-native:ReactAndroid:hermes-engine"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,6 @@
<!-- @generated -->
<!-- FB Locale: es_LA -->
<resources exclude-from-buck-resource-map="true">
<<<<<<< HEAD
||||||| parent of 6b77155168f ([ReactAndroid] Prefix all resources with 'reactandroid_')
<string name="catalyst_dev_menu_header" gender="unknown">Menú de desarrollador nativo de reacción (%1$s)</string>
<string name="catalyst_dev_menu_sub_header" gender="unknown">Se está ejecutando %1$s</string>
=======
<string name="reactandroid_catalyst_dev_menu_header" gender="unknown">Menú de desarrollador nativo de reacción (%1$s)</string>
<string name="reactandroid_catalyst_dev_menu_sub_header" gender="unknown">Se está ejecutando %1$s</string>
>>>>>>> 6b77155168f ([ReactAndroid] Prefix all resources with 'reactandroid_')
</resources>

0 comments on commit 546eb41

Please sign in to comment.