我的Android应用程序中出现gradle构建错误。我尝试更新NDK和所有模块,但它仍然出现。有谁知道会导致它的原因以及如何解决它?下面是我的gradle文件:
Execution failed for task ':app:transformNativeLibsWithStripDebugSymbolForDebug'.
> A problem occurred starting process 'command 'D:\Android\SDK\ndk-bundle\toolchains\mips64el-linux-android-4.9\prebuilt\windows-x86_64\bin\mips64el-linux-android-strip''
等级:
apply plugin: 'com.android.application'
android {
signingConfigs {
debug {
storeFile file('../buildsystem/debug_key.jks')
storePassword 'mypassword'
keyAlias 'androiddebug'
keyPassword 'mypassword'
}
release {
keyAlias 'Alias'
keyPassword 'mypassword'
storeFile file('release.jks')
storePassword 'mypassword'
}
}
compileSdkVersion 25
buildToolsVersion "27.0.3"
defaultConfig {
applicationId "com.mytestapplication.app"
minSdkVersion 19
targetSdkVersion 27
versionCode 3
versionName "1.2.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.release
//debuggable true
}
debug {
signingConfig signingConfigs.debug
}
}
dexOptions {
javaMaxHeapSize "4g"
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.journeyapps:zxing-android-embedded:3.5.0'
compile 'com.android.support:appcompat-v7:25.1.0'
compile 'com.android.support:support-v4:25.1.0'
compile 'com.android.support:design:25.1.0'
compile 'com.squareup.retrofit2:retrofit:2.3.0'
compile 'com.squareup.retrofit2:converter-gson:2.0.0-beta4'
compile 'com.squareup.okhttp3:logging-interceptor:3.4.1'
compile 'com.squareup.okhttp3:okhttp:3.4.1'
compile 'com.android.support:cardview-v7:25.0.+'
compile 'com.android.support:recyclerview-v7:25.0.+'
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.google.code.gson:gson:2.6.1'
compile 'com.afollestad.material-dialogs:core:0.9.4.5'
compile 'io.card:android-sdk:5.5.1'
compile 'com.github.pinball83:masked-edittext:1.0.3'
compile 'com.github.paolorotolo:appintro:3.3.0'
compile 'com.google.firebase:firebase-core:12.0.0'
compile "com.google.firebase:firebase-messaging:12.0.0"
testCompile 'junit:junit:4.12'
}
apply plugin: 'com.google.gms.google-services'
答案 0 :(得分:1)
答案 1 :(得分:0)
已经晚了,但可能对其他人有帮助
我通过降级为“ android-ndk-r16b”解决了该问题
从此链接下载 https://developer.android.com/ndk/downloads/older_releases
,然后在项目结构窗口中设置ndk文件夹路径。