error while generating signed apk task app:package

2019-04-26 20:48发布

Error:A problem was found with the configuration of task ':app:packageRelease'. File '/Volumes/Data/Android apps/NammaKarnataka-master/app/build/intermediates/res/resources-release-stripped.ap_' specified for property 'resourceFile' does not exist.

The following error message occurred while I tried to generate signed apk on Android studio 2.2.
What additional information is required in order to solve this issue?

1条回答
可以哭但决不认输i
2楼-- · 2019-04-26 21:32

Add shrinkResources, set to false, to the release clause:

buildTypes {
    release {
        signingConfig signingConfigs.release
        minifyEnabled false
        shrinkResources false  //ADD THIS
        zipAlignEnabled true
        debuggable false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}
查看更多
登录 后发表回答