Build error on android


#1

Hi !

I have big problem only with android build.

When i do “cordova emulate android” or “cordova build android” I have a build failed with this message :

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':processDebugResources'.
> com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/Users/userMe/Library/Android/sdk/build-tools/22.0.1/aapt'' finished with non-zero exit value 1

What should I do to make it work ?
I’ve tried “cordova platforms rm android” then re-add the android platforms but still the same issue.

Hope someone will help me

Thanks


#2

Here is log after cordova build android :

[...]
:processDebugResources FAILED

FAILURE: Build failed with an exception.

*What went wrong:
Execution failed for task ':processDebugResources'.
.>com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command '/Users/userMe/Library/Android/sdk/build-tools/24.0.0/aapt'' finished with non-zero exit value 1

*Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Total time: 3.772 secs
Error: Error code 1 for command: /Users/userMe/Desktop/Développement/Multi-plateforme/myApp/platforms/android/gradlew with args: cdvBuildDebug,-b,/Users/userMe/Desktop/Développement/Multi-plateforme/myApp/platforms/android/build.gradle,-Dorg.gradle.daemon=true,-Pandroid.useDeprecatedNdk=true

I really need help guys !


#3

The problem can be the non utf-8 char in the path (…Développement…), but you can also try to reset gradle, you can find more here: Android Build Failed


#4

It is not the non utf-8 char in the path because I have working android project under this directory :wink:


#5

…then try to reset gradle as specified in the linked message. If this not works, try to delete all the .gradle directory in the home (is something like a cache for the gradle), this works for me.