我已经在 appcenter 中配置了我的 react-native 应用程序以进行构建和分发。一切正常,突然之间,构建失败并出现以下错误
> Task :app:stripReleaseDebugSymbols FAILED
Support for ANDROID_NDK_HOME is deprecated and will be removed in the future. Use android.ndkVersion in build.gradle instead.
> Task :app:mergeExtDexRelease
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:stripReleaseDebugSymbols'.
> No toolchains found in the NDK toolchains folder for ABI with prefix: arm-linux-androideabi
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
按照此链接https://github.com/microsoft/appcenter/issues/2144并将我的成绩文件更新为
buildscript {
ext {
ndkVersion = "20.1.5948944"
}
dependencies {
classpath("com.android.tools.build:gradle:4.1.0")
}
和 gradle-wrapper.properties 到
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
在此之后构建工作,但构建后分发的应用程序无法安装在设备上并出现“未安装应用程序”错误。我尝试了不同的版本,但到目前为止没有成功。