我试图更改我的应用程序以支持32位和64位,但是当我这样更改 build.gradle 时。
android {
compileSdkVersion 28
defaultConfig {
applicationId "id.co.poslogistics.agendakegiatan"
minSdkVersion 15
targetSdkVersion 28
versionCode 1
versionName "1.0"
ndk.abiFilters = 'armeabi-v7a' 'arm64-v8a' 'x86' 'x86_64'
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
但是当我抓到它时,错误将显示如下
错误:
在DefaultConfig_Decorated {name = main,Dimensions = null,minSdkVersion = DefaultApiVersion {mApiLevel = 15,mCodename ='null'},targetSdkVersion = DefaultApiVersion {mApiLevel}上找不到参数[arm64-v8a]的方法armeabi-v7a() = 28,mCodename ='null'},renderscriptTargetApi = null,renderscriptSupportModeEnabled = null,renderscriptSupportModeBlasEnabled = null,renderscriptNdkModeEnabled = null,versionCode = 1,versionName = 1.0,applicationId = id.co.poslogistics.agendakegiatan,testApplicationId = null,testInstrumentationRunner = null,testInstrumentationRunnerArguments = {},testHandleProfiling = null,testFunctionalTest = null,signingConfig = null,resConfig = null,mBuildConfigFields = {},mResValues = {},mProguardFiles = [],mConsumerProguardFiles = [},mManifestPlaceholders = App, }。类型为com.android.build.gradle.internal.dsl.DefaultConfig。
谁能帮助我。谢谢
答案 0 :(得分:4)
您的配置
ndk.abiFilters = 'armeabi-v7a' 'arm64-v8a' 'x86' 'x86_64'
应为
ndk.abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
或
ndk {
abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86' ,'x86_64'
}