I am building Ionic project for android using cordova. I am running into following error.
Execution failed for task ':app:mergeDebugResources'.
> java.util.concurrent.ExecutionException:
com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2
aapt2-3.3.0-5013011-windows Daemon #5: Daemon startup failed
I pretty much tried all the solution recommended and none of them worked in my case. I cant even read the log file. Same project I can able to build in macos.
Things I have tried.
Updated the Gradle to 5.4.1
remove and added android project
- ionic cordova platform remove android
- ionic cordava platform add android
Updated android studio to 3.4.1
added resolutionStrategy
to in platform\android\build.gradle
configurations.all {
resolutionStrategy.force 'com.android.support:support-v4:27.1.0'
}
added android.enableAapt2=false
in gradle.properties
added com.android.support:support-v4:27.1.0
in project.properties
Error message I got
Execution failed for task ':app:mergeDebugResources'.
> java.util.concurrent.ExecutionException:
com.android.builder.internal.aapt.v2.Aapt2InternalException: AAPT2
aapt2-3.3.0-5013011-windows Daemon #0: Daemon startup failed
command i used to build the project: ionic cordova run android
- Cordova version 9.0.0
- ionic version 5.0.0
- angular version 4.4.3