I try to build an ionic app for android and I've this error :
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 com.android.support:support-v4:+.
Searched in the following locations:
https://repo1.maven.org/maven2/com/android/support/support-v4/maven-metadata.xml
https://repo1.maven.org/maven2/com/android/support/support-v4/
Required by:
:android:unspecified
Android Support Library and Android support Repository are installed.
Thank for your help
EDIT:
I try to update cordova and cordova-cli but it didn't work.
The location https://repo1.maven.org/maven2/com/android/support/
does not exist anymore (404
). So the maven configuration seems to be the issue.
I found a GitHub issue about the same problem you encountered and it was solved by running updating the SDK (which you did already) and readding the Android platform to the Ionic project:
# Update Android SDK
android list sdk
android update sdk --no-ui --filter extra
# Refresh Ionic Android configuration
ionic platform remove android
ionic platform add android
Please see my answer in this related question.
In short: the source of the error maybe an plugin that depends on the com.android.support:support-v4 support library.
If you use cordova >= 5.0.0 update to the new official plugins.
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