React Native安卓项目升级Android Gradle插件及compileSdk问题求助
React Native Android Gradle构建问题求助
遇到的Gradle警告
- 从Android Gradle Plugin(AGP)8.0开始,Maven发布将不再自动创建软件组件,需在
gradle.properties中设置android.disableAutomaticComponentCreation=true,或使用新的发布DSL - OneSignalPlugin将
com.android.support:33.0.0降级至28.+以避免编译错误,建议更新项目的compileSdkVersion - 当前使用的AGP 7.2.1仅测试支持到compileSdk 32,若要使用compileSdk 33需升级至更高版本插件
困惑与升级报错
我已在build.gradle中明确指定compileSdkVersion为33,但仍出现上述警告。此外,尝试将AGP从7.0.4升级至7.3.3时,构建失败,报错如下:
> Could not determine the dependencies of null. > Could not resolve all task dependencies for configuration ':classpath'. > Could not find com.android.tools.build:gradle:7.3.3. Searched in the following locations: - https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/7.3.3/gradle-7.3.3.pom - https://repo.maven.apache.org/maven2/com/android/tools/build/gradle/7.3.3/gradle-7.3.3.pom Required by: project : > Could not find com.android.tools.build:gradle:7.3.3. Searched in the following locations: - https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/7.3.3/gradle-7.3.3.pom - https://repo.maven.apache.org/maven2/com/android/tools/build/gradle/7.3.3/gradle-7.3.3.pom Required by: project : > project :react-native-gradle-plugin
请求帮助解决这些问题。
内容的提问来源于stack exchange,提问作者Justin
相关产品推荐
相关产品推荐

