Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 2 additions & 10 deletions .github/actions/androidapp-road-test/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,8 @@ runs:
- name: Prepare Android environment
uses: ./.github/actions/prepare-android

- name: Restore Gradle cache
uses: actions/cache@9255dc7a253b0ccc959486e2bca901246202afeb # v5
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-android-androidapp-${{ inputs.flavor }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-android-androidapp-${{ inputs.flavor }}-gradle-
${{ runner.os }}-android-androidapp-gradle-
Comment on lines -26 to -35
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you sure we need to remove this? I would say this actually gives us a boost.

- name: Setup Gradle
uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5 # v4.2.1

# == Brownfield Gradle Plugin ==
- name: Publish Brownfield Gradle Plugin to Maven Local
Expand Down
3 changes: 3 additions & 0 deletions apps/AndroidApp/app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ android {
versionCode = 1
versionName = "1.0"

ndk {
abiFilters += listOf("arm64-v8a")
}
Comment on lines +28 to +30
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm all for it, but how about injecting this in CI - the current approach will be a sad surprise for someone who wants to run e.g. on x86_64. I think the optimal way would be something like:

val abiOverride = project.findProperty("demoAbiFilters") as String?
if (abiOverride != null) {
  abiFilters.clear()
  abiFilters += abiOverride.split(",")
} else {
  abiFilters += listOf("arm64-v8a")
}

And we could just pass -PdemoAbiFilters=arm64-v8a.

But there's one blocker: I think we don't have a way to pass -P args to gradlew from the CLI. Would you be able to follow-up with this feature, in a new or maybe even in this PR?

This would not only unlock this option, but also help reactNativeArchitectures - we could also specify them with a -PreactNativeArchitectures=arm64-v8a. This would also bring a nice improvement that may be used by consumers of Brownfield.

testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
}

Expand Down
2 changes: 1 addition & 1 deletion apps/RNApp/android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ android.useAndroidX=true
# Use this property to specify which architecture you want to build.
# You can also override it from the CLI using
# ./gradlew <task> -PreactNativeArchitectures=x86_64
reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64
reactNativeArchitectures=arm64-v8a
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


# Use this property to enable support to the new architecture.
# This will allow you to use TurboModules and the Fabric render in
Expand Down
Loading