找不到兼容的并行NDK版本.默认值为20.0.5594570 [英] Compatible side by side NDK version was not found. Default is 20.0.5594570

查看:1984
本文介绍了找不到兼容的并行NDK版本.默认值为20.0.5594570的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我收到上述错误

我的gradle像这样

My gradle looks like this

apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'

android {
    compileSdkVersion 29
    buildToolsVersion "29.0.3"

    defaultConfig {
        applicationId "com.example.hypersignwalletcorekotlin"
        minSdkVersion 23
        targetSdkVersion 29
        versionCode 1
        versionName "1.0"

        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }

}
project.ext {
    walletcore_version = "2.0.5"
}
dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
    implementation 'androidx.appcompat:appcompat:1.1.0'
    implementation 'androidx.core:core-ktx:1.2.0'
    implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
    implementation "com.trustwallet:wallet-core:$walletcore_version"
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'androidx.test.ext:junit:1.1.1'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
}

不明白为什么会这样.

谢谢

推荐答案

修复: ndkVersion 添加到模块的build.gradle >

The Fix: add ndkVersion to your module's build.gradle

    android.ndkVersion  "your-installed-ndk-version"

一些示例.您可以从文件$ NDK/source.properties中找到您的NDK版本.

as in some examples. You could find your NDK version from the file $NDK/source.properties.

背景信息: 您可能使用的是AGP/Android Studio 3.6+版本:从Android Gradle插件(AGP)3.6+开始,添加了known good NDK概念,即发布该AGP版本时的known good/tested NDK version".如果满足以下条件,则AGP将使用该内部NDK版本:

Background Info: You probably using AGP/Android Studio version 3.6+: "From Android Gradle Plugin ( AGP ) 3.6+, there is a known good NDK concept added, which is the known good/tested NDK version when that AGP version was released". AGP will use that internal NDK version if:

  • you are not using the ndkVersion feature added in AGP 3.5

内部NDK预计将作为并行NDK位置安装: $ SDK \ ndk
如果未安装:

That internal NDKs are expected to be installed as side-by-side NDK place: $SDK\ndk
if not installed:

  • AGP 3.6,AGP 4.0将出错
  • AGP 4.1会自动安装它.

随着不断更新的NDK不断发布,内部嵌入式NDK版本很可能很快就会过时:如果要使用更新的NDK版本,则需要使用 ndkVersion .

The internally embedded NDK version, most likely, will be out-of-date pretty quickly as newer NDKs are constantly being released: if you want to use a newer NDK version, you do need to configure gradle with ndkVersion.

其他文档: 有关详细信息,请参考官方文档.

Additional Doc: Refer to the official documentation for details.

这篇关于找不到兼容的并行NDK版本.默认值为20.0.5594570的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆