"兼容性-V4-r4.jar"在Maven的回购缺失 [英] "compatibility-v4-r4.jar" is missing in Maven Repo

查看:267
本文介绍了"兼容性-V4-r4.jar"在Maven的回购缺失的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在过去的两天我试图通过Maven来导入这个库:

In the last two days I tried to import this Library through Maven:

<一个href="https://github.com/JakeWharton/Android-ViewPagerIndicator">https://github.com/JakeWharton/Android-ViewPagerIndicator

我不得不说,我是新到Maven,所以如果这是容易解决的,请原谅 我,我用Google搜索的问题,并研究了错误页面,但我无法找到 针对此问题的解决方案。 但每次我尝试我得到一个错误这样的:

I have to say that I'm new to maven so if this is easy to solve please forgive me I googled the problem and studied the error pages but I could not find a solution for this problem. But everytime I try i get an error like that:

c:\JakeWharton-Android-ViewPagerIndicator-3db7585>mvn install
[INFO] Scanning for projects...
[WARNING]
[WARNING] Some problems were encountered while building the effective model for
com.viewpagerindicator:library:apklib:2.2.0
[WARNING] 'build.plugins.plugin.version' for com.jayway.maven.plugins.android.ge
neration2:maven-android-plugin is missing. @ line 36, column 12
[WARNING]
[WARNING] Some problems were encountered while building the effective model for
com.viewpagerindicator:sample:apk:2.2.0
[WARNING] 'build.plugins.plugin.version' for com.jayway.maven.plugins.android.ge
neration2:maven-android-plugin is missing. @ line 48, column 12
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten t
he stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support buildin
g such malformed projects.
[WARNING]
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] Android-ViewPagerIndicator (Parent)
[INFO] Android-ViewPagerIndicator
[INFO] Android-ViewPagerIndicator Sample
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Android-ViewPagerIndicator (Parent) 2.2.0
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.3.1:install (default-install) @ parent ---
[INFO] Installing c:\JakeWharton-Android-ViewPagerIndicator-3db7585\pom.xml to C
:\Users\Cracksoldier\.m2\repository\com\viewpagerindicator\parent\2.2.0\parent-2
.2.0.pom
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Android-ViewPagerIndicator 2.2.0
[INFO] ------------------------------------------------------------------------
Downloading: http://r.jakewharton.com/maven/release/android/support/compatibilit
y-v4/r4/compatibility-v4-r4.pom
Downloading: http://repo1.maven.org/maven2/android/support/compatibility-v4/r4/c
ompatibility-v4-r4.pom
[WARNING] The POM for android.support:compatibility-v4:jar:r4 is missing, no dep
endency information available
Downloading: http://r.jakewharton.com/maven/release/android/support/compatibilit
y-v4/r4/compatibility-v4-r4.jar
Downloading: http://repo1.maven.org/maven2/android/support/compatibility-v4/r4/c
ompatibility-v4-r4.jar
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Android-ViewPagerIndicator (Parent) ............... SUCCESS [0.204s]
[INFO] Android-ViewPagerIndicator ........................ FAILURE [1.636s]
[INFO] Android-ViewPagerIndicator Sample ................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.953s
[INFO] Finished at: Thu Dec 22 18:29:20 CET 2011
[INFO] Final Memory: 10M/108M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project library: Could not resolve dependencie
s for project com.viewpagerindicator:library:apklib:2.2.0: Could not find artifa
ct android.support:compatibility-v4:jar:r4 in com.jakewharton (http://r.jakewhar
ton.com/maven/release) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit
ch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please rea
d the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyReso
lutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command

[ERROR]   mvn <goals> -rf :library

通过量我的问题张贴在github上我得到的信息,我要改变COMPAT depencies从R4到R6在pom.xml的,所以我尝试过了,从改变了它:

Throug my Issues Post on github I got the Info that I have to change the compat depencies from r4 to r6 in the pom.xml and so I tried it and changed it from:

<android.support.version>r4</android.support.version>

这样:

<android.support.version>r6</android.support.version>

但是,这没有工作,所以我感动,并尝试了这种方式。 我从这个编辑的Depencies部分:

But this didnt work and so I moved on and tried it that way. I edited the Depencies section from this:

            <dependency>
            <groupId>android.support</groupId>
            <artifactId>compatibility-v4</artifactId>
            <version>${android.support.version}</version>
        </dependency>

这样:

            <dependency>
            <groupId>android.support</groupId>
            <artifactId>compatibility-v4-r6</artifactId>
            <version>${android.support.version}</version>
        </dependency>

和我也试图取代兼容性-V4有:

and I also tried to replace "compatibility-v4" with:

兼容性-V6和 兼容性-R6

compatibility-v6 and compatibility-r6

但没有奏效。我也查了.m2目录目录,它不存在。 我也recked如果proberly安装Maven和它。 我希望有人能帮助我。

but nothing worked. I also checked the .m2 directory and it is not there. I also recked if Maven is installed proberly and it is. I hope somebody can help me.

最好的问候

推荐答案

怎样的方式Maven的工作非常简单,下载来自互联网所需的jar依赖于你的本地仓库的,后来构建应用程序时,它解决所有需要从这里你的本地仓库的jar文件。

The way how maven works is quite straightforward, download the required jar dependencies from internet to your local maven repository first, when building your application later, it resolve all required jar files from your local maven repository here.

您的问题:
Maven是试图下载从 HTTP一个jar文件://ř .jakewharton.com /行家/发行/安卓/支持/兼容-V4 / R4 / ,自己尝试一下,这是一个死链接。这通常意味着开发商不维持他们的行家释放正确。

Your problem:
Maven is trying to download a jar file from http://r.jakewharton.com/maven/release/android/support/compatibility-v4/r4/, try it yourself, this is a dead link. this usually means the developer doesn't maintain their maven release properly.

在sulotion:
我想这个帖子在GitHub是你的,你需要使用的 Maven的Andr​​oid的SDK-部署,请查看如何使用部分在这里。基本上,你需要运行Maven,Android的SDK-部署,从本地的Andr​​oid SDK目录需要的jar(这是不是可以通过互联网尚)复制到你的Maven本地存储库,正如我所说,如果没有特别指明, ,行家总是从你的本地仓库解决jar文件。

The sulotion:
I suppose this post on GitHub is from you, you need to use maven-android-sdk-deployer, check out the "How to Use" section here. basically, you need run maven-android-sdk-deployer to copy the required jars (which are not available through internet yet) from your local Android SDK directory into your maven local repository, as I said, If you don't specify it explicitly, maven always resolve jar files from your local maven repository.

这篇关于&QUOT;兼容性-V4-r4.jar&QUOT;在Maven的回购缺失的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆