Build failed with exit code 8 #184

nico3dfx opened this Issue Sep 30, 2015 · 6 comments


None yet

4 participants


I'm building the project with cordova 5.3.3 CLI
Android project created with cordova-android@4.1.1 (Android target: android-22)
The plugin versioni is 1.3.0
I have the Android Support Library 23.0.1 installed

But build fails with an exception

This is the build message

$ cordova build
Running command: cmd "/s /c "c:\xampp\htdocs\apps\saabate\platforms\android\cordova\build.bat""
ANDROID_HOME=C:\Program Files (x86)\Android\android-sdk
JAVA_HOME=C:\Program Files\Java\jdk1.7.0
Running: c:\xampp\htdocs\apps\saabate\platforms\android\gradlew cdvBuildDebug -b c:\xampp\htdocs\apps\saabate\platforms\android

FAILURE: Build failed with an exception.


Total time: 23.162 secs

throw e;
Error code 1 for command: cmd with args: /s /c "c:\xampp\htdocs\apps\saabate\platforms\android\gradlew cdvBuildDebug -b c:\xamp
latforms\android\build.gradle -Dorg.gradle.daemon=true"
ERROR building one of the platforms: Error: cmd: Command failed with exit code 8
You may not have the required environment or OS to build this project
Error: cmd: Command failed with exit code 8
at ChildProcess.whenDone (c:\Users\IS5\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\cordova\supers
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:735:16)

at Process.ChildProcess._handle.onexit (child_process.js:802:5)

For a build succesfull I need to remove the plugin, remove the platform and add the platform, without adding the push plugin

What's wrong?


@macdonst macdonst closed this Sep 30, 2015

Sorry but i already have the android support library
How to include the library in the cordova project?
I run cordova build android from the CLI



@nico3dfx I bet you don't have version 23 installed. You probably just need to upgrade.


Me too facing the same problem

Could not resolve all dependencies for configuration ':_debugCompile'.
Could not find any version that matches
Searched in the following locations:
Required by:

After removing the phonegap-plugin-push, i'm able to build the app successfully.

Please help me to figure out the problem.

Thanks in advance.


Run: android list sdk
Once you get the list look for al the dependencies that are listed here
Then run: android update sdk --no-ui --filter "numbers","on","the","list"


Thanks Nicoabie

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment