I have a similar problem with the maven-dependency-plugin when switching to the recent version 0.16.0 of Tycho as discussed in bug 393978. As I cannot find any reliably working solution, I am addressing the
mailing list now.
In my software project, I am using the maven-dependency-plugin to copy some dependencies to legacy libraries (available as pure JAR-files in a company-local Maven Artifactory) into a legacy OSGi bundle which
then reexports those dependencies while adding some additional legacy code.
The attached demo project org.example.tycho.legacy is just an example similar to the original bundle causing the problem. It just uses one dependency to the jtds library instead of the real dependencies which
are only resolvable via our company-local Maven Artifactory. Furthermore, the demo project contains all the configuration in its own pom.xml instead of using a two-level hierarchy of parent poms as it is done in the original bundle. OSGi dependencies are also
resolved against our own company-local p2 repositories in the original bundle, while the demo project uses the Eclipse Indigo p2 site directly. All those adaptions are just made to make the demo project generally working without our company-local Maven Artifactory
and do not make any difference concerning the actual problem.
The observed invalid behavior is the following: Every second run of "mvn clean install", the build fails with the following error message:
Failed to execute goal org.apache.maven.plugins:maven-dependency-plugin:2.6:copy-dependencies (copy-dependencies) on project org.example.tycho.legacy: Error copying artifact from C:\development\workspaces_mpng\tycho-copy-dependencies2\org.example.tycho.legacy\lib\jtds-1.2.4.jar
to C:\development\workspaces_mpng\tycho-copy-dependencies2\org.example.tycho.legacy\lib\org.example.tycho.legacy.source-1.0.0.qualifier-lib\jtds-1.2.4.jar.jar: File C:\development\workspaces_mpng\tycho-copy-dependencies2\org.example.tycho.legacy\lib\jtds-1.2.4.jar
does not exist -> [Help 1]