After updating to Gradle 4.1 I'm unable to build my project (all works fine with previous releases).
Basically it doesn't recognize AndroidManifest tags anymore and gives me errors in the generated manifest in /build/intermediates/manifests/full/debug
.
Here's the build log:
/home/paolorotolo/dev/exp/***/build/intermediates/manifests/full/debug/AndroidManifest.xml
Error:(30) unknown element <action> found
Error:(32) unknown element <category> found
Error:(33) unknown element <category> found
Error:/home/paolorotolo/dev/exp/core/***/build/intermediates/manifests/full/debug/AndroidManifest.xml:30 unknown element <action> found
Error:/home/paolorotolo/dev/exp/core/***/build/intermediates/manifests/full/debug/AndroidManifest.xml:33 unknown element <category> found
Error:java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.AaptException: AAPT2 link failed:
Error:com.android.builder.internal.aapt.AaptException: AAPT2 link failed:
Error:Execution failed for task ':***:processDebugResources'.
> Failed to execute aapt
Information:BUILD FAILED in 6s
The issue has been fixed in new gradle release (gradle-4.1-rc-2).
To solve add in your gradle-wrapper.properties
:
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-rc-2-all.zip
For now using gradle 4.1, or even 4.2 on your gradle wrapper will break builds that have dependencies
I solved this issue by taking back my gradle classpath depency back to gradle 2.3.3
dependencies {
classpath 'com.android.tools.build:gradle:2.3.3'
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With