Files
react-native/settings.gradle.kts
Luís Chaves 664acaf441 fix: upgrade foojay-resolver-convention to 1.0.0 (#56210)
Summary:
foojay-resolver-convention's version 0.5.0 is not compatible with Gradle 9. (https://github.com/gradle/foojay-toolchains/issues/151)
When trying to build for Android on React Native 0.8.2, we are presented with
```
java.lang.NoSuchFieldError: Class org.gradle.jvm.toolchain.JvmVendorSpec does not have member field 'org.gradle.jvm.toolchain.JvmVendorSpec IBM_SEMERU'
	at org.gradle.toolchains.foojay.DistributionsKt.<clinit>(distributions.kt:16)
	at org.gradle.toolchains.foojay.FoojayApi.fetchDistributionsIfMissing(FoojayApi.kt:62)
	at org.gradle.toolchains.foojay.FoojayApi.match$foojay_resolver(FoojayApi.kt:49)
	at org.gradle.toolchains.foojay.FoojayApi.toLinks(FoojayApi.kt:41)
```

## Changelog:

<!-- Help reviewers and the release process by writing your own changelog entry.

Pick one each for the category and type tags:

[ANDROID] [CHANGED] - changed foojay-resolver-convetion version to 1.0.0

For more details, see:
https://reactnative.dev/contributing/changelogs-in-pull-requests

Pull Request resolved: https://github.com/facebook/react-native/pull/56210

Test Plan: After making the change, the app build without problems.

Reviewed By: fabriziocucci

Differential Revision: D98883905

Pulled By: cortinico

fbshipit-source-id: 18bfbba0e6af1aee660cee13c68c20bab75506d9
2026-03-31 04:07:33 -07:00

47 lines
1.1 KiB
Kotlin

/*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
pluginManagement {
repositories {
mavenCentral()
google()
gradlePluginPortal()
}
includeBuild("packages/gradle-plugin/")
}
include(
":packages:react-native:ReactAndroid",
":packages:react-native:ReactAndroid:hermes-engine",
":packages:react-native:ReactAndroid:external-artifacts",
":packages:rn-tester:android:app",
":packages:rn-tester:android:app:benchmark",
":private:react-native-fantom",
)
includeBuild("packages/gradle-plugin/")
dependencyResolutionManagement {
versionCatalogs {
create("libs") { from(files("packages/react-native/gradle/libs.versions.toml")) }
}
}
rootProject.name = "react-native-github"
plugins {
id("org.gradle.toolchains.foojay-resolver-convention").version("1.0.0")
id("com.facebook.react.settings")
}
configure<com.facebook.react.ReactSettingsExtension> {
autolinkLibrariesFromCommand(
workingDirectory = file("packages/rn-tester/"),
lockFiles = files("yarn.lock"),
)
}