简体   繁体   中英

“The following artifacts could not be resolved” : Maven / Android / Eclipse

I am trying to run an android application in Eclipse using Maven . Some dependencies are unfortunately stopping the run (could not be found or resolved). I have already checked that I have the dependencies in my repository. Any suggestion is welcome. Thank you for your time and consideration.

Pom.xml :

<dependency>
        <groupId>android</groupId>
        <artifactId>android</artifactId>
        <version>4.4.2_r2</version>
        <scope>provided</scope> 
    </dependency>
    <dependency>
        <groupId>android.support</groupId>
        <artifactId>compatibility-v4</artifactId>
        <version>19.0.1</version>
    </dependency>

Console's error message:

The following artifacts could not be resolved: android:android:jar:4.4.2_r2, android.support:compatibility-v4:jar:19.0.1: Failure to find android:android:jar:4.4.2_r2 in http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced

The android:android:jar:4.4.2_r2 does not exist in your repository. Check really if it exists.

Due to legal problems, Google do not allow Android JAR files to be installed on the Maven Central repository. You need to manually install these dependencies in your local repository.

To do this you need to clone and execute the Maven Android SDK Deployer .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM