我使用ant构建时遇到错误:
BUILD FAILED
/Users/rajeevprasanna/Desktop/Nutch/nutch-release-1.14/build.xml:116: The following error occurred while executing this line:
/Users/rajeevprasanna/Desktop/Nutch/nutch-release-1.14/src/plugin/build.xml:34: The following error occurred while executing this line:
/Users/rajeevprasanna/Desktop/Nutch/nutch-release-1.14/src/plugin/build-plugin.xml:230: impossible to ivy retrieve: java.lang.RuntimeException: problem during retrieve of org.apache.nutch#lib-selenium: java.lang.RuntimeException: Multiple artifacts of the module commons-codec#commons-codec;1.10 are retrieved to the same file! Update the retrieve pattern to fix this error.
at org.apache.ivy.core.retrieve.RetrieveEngine.retrieve(RetrieveEngine.java:206)
at org.apache.ivy.Ivy.retrieve(Ivy.java:540)
at org.apache.ivy.ant.IvyRetrieve.doExecute(IvyRetrieve.java:59)
at org.apache.ivy.ant.IvyTask.execute(IvyTask.java:277)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
我按照post:
设置了配置<target name="resolve-default" depends="clean-default-lib" description="--> resolve and retrieve dependencies with ivy">
<ivy:resolve file="${ivy.file}" conf="default" log="download-only"/>
<ivy:retrieve pattern="${build.lib.dir}/[artifact]-[type]-[revision].[ext]" symlink="false" log="quiet"/>
<antcall target="copy-libs"/>
</target>
<target name="resolve-test" depends="clean-test-lib, init" description="--> resolve and retrieve dependencies with ivy">
<ivy:resolve file="${ivy.file}" conf="test" log="download-only"/>
<ivy:retrieve pattern="${test.build.lib.dir}/[artifact]-[type]-[revision].[ext]" symlink="false" log="quiet"/>
<antcall target="copy-libs"/>
</target>
commons-codec依赖关系如下所示:ivy.xml:
<dependency org="commons-codec" name="commons-codec" rev="1.10" conf="*->default" />
有人能告诉我我做错了吗?