Android BuildError

I’m trying to build my application with Android. It works just fine in iOS.
After running ionic build android I get the error

Running command: "C:\Program Files (x86)\nodejs\node.exe" C:\Users\Zeskerr\Documents\ProjectsFolder\mobilityphone\hooks\after_prepare\010_add_platform_class.js C:/Users/Zeskerr/Documents/ProjectsFolder/mobilityphone add to body class: platform-android Running command: cmd "/s /c "C:\Users\Zeskerr\Documents\ProjectsFolder\mobilityphone\platforms\android\cordova\build.bat"" ANDROID_HOME=C:\Users\Zeskerr\AppData\Local\Android\android-sdk JAVA_HOME=C:\Program Files\Java\jdk1.8.0_65 Running: C:\Users\Zeskerr\Documents\ProjectsFolder\mobilityphone\platforms\android\gradlew cdvBuildDebug -b C:\Users\Zeskerr\Documents\ProjectsFolder\mobilityphone\platforms\android\build.gradle -Dorg.gradle.daemon=true

FAILURE: Build failed with an exception.
* What went wrong: A problem occurred configuring root project 'android'.
Could not resolve all dependencies for configuration ':_debugCompile'. Could not find any version that matches Searched in the following locations: Required by: :android:unspecified

* Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
Total time: 3.112 secs
throw e; ^ Error code 1 for command: cmd with args: /s /c "C:\Users\Zeskerr\Documents\ProjectsFolder\mobilityphone\platforms\android\gradlew cdvBuildDebug -b C:\Users\Zeskerr\Documents\ProjectsFolder\mobilityphone\platforms\android\build.gradle -Dorg.gradle.daemon=true" ERROR building one of the platforms: Error: cmd: Command failed with exit code 1 You may not have the required environment or OS to build this project Error: cmd: Command failed with exit code 1

Now, I created another test application simply using one of the ionic templates. In this case I made a generic tabs application by running the ionic start testapp tabs. And that application seems to build just fine, and even got it to run on my device. Samsung Note 5 (don’t know if it matters).

Any ideas on what might be the issue? I really need some input

Thanks !

Maybe your app uses a plugin and you did not install all its requirements from Android SDK.
Try installing the Extras packages from the SDK manager

Hey, thanks ! That did the trick and now it work just fine. :smiley: