Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to resolve the errors after running "mvn compile" on guava-libraries project?

Tags:

maven

guava

I checked out guava-libraries and tried to build it with "mvn compile".

A mysterious error popped out and I failed to find a solution. But "mvn package" or "mvn install" succeeded without any errors.

Is 'compile' not a valid maven lifecycle for guava-libraries?

The core error message is below for your reference. Thanks for any help in advance.

[INFO] Unpacking /home/xxx/guava-libraries/guava/target/classes to /home/xxx/guava-libraries/guava-gwt/target/guava-sources with includes "" and excludes "META-INF/MANIFEST.MF"
org.codehaus.plexus.archiver.ArchiverException: The source must not be a directory.
    at org.codehaus.plexus.archiver.AbstractUnArchiver.validate(AbstractUnArchiver.java:185)
    at org.codehaus.plexus.archiver.AbstractUnArchiver.extract(AbstractUnArchiver.java:118)
    at org.apache.maven.plugin.dependency.AbstractDependencyMojo.unpack(AbstractDependencyMojo.java:258)

Note: the paths in the error message are correct.

like image 648
Cuper Hector Avatar asked Jan 15 '23 19:01

Cuper Hector


1 Answers

You ran into the bug MDEP-98 of the maven-dependency-plugin, which is executed during the build of guava-gwt. Unfortunately, there is no solution to work around this bug, except not using mvn compile but mvn package or mvn install instead.

like image 138
Stefan Ferstl Avatar answered Apr 26 '23 17:04

Stefan Ferstl