Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-dev] setting Eclipse build path to exclude package.html to avoid [WARNING] javadoc: warning - Multiple sources of package comments found for package...

This looks like a bug and will likely need changing m2e to fix. Since
this is a dev list I will assume change m2e is what you want to do ;-)

org.eclipse.m2e.jdt.internal.AbstractJavaProjectConfigurator already has
the logic to read maven-compiler-plugin includes/excludes configuration
parameter and apply corresponding patterns to Eclipse JDT source folder
IClasspathEntry. For some reason this logic does not work for your
project. So I would start by setting up a regression test that
demonstrates the problem first and once you have the test fixing the
problem should be a simple matter of writing code :-)

m2e development environment setup and ways to submit patches is
documented in

   http://wiki.eclipse.org/M2E_Development_Environment

--
Regards,
Igor

On 2013-09-10 9:47 AM, Marshall Schor wrote:
We're getting these in our build, if we use Eclipse auto-builds, and don't run
Maven with "clean" first.

An analysis of this (using info from the maven-javadoc-plugin -Ddebug option)
shows why:

Eclipse builds both "compiles" files to the output directory,and also "copies"
non-java files to the output directory.  This is different from Maven builds,
which only compiles files from the src/main/java folder, and copies files from
the src/main/resources folder (by default).

The result: If the maven build has an invocation of the maven-javadoc-plugin, it
has the source folder in the javadoc "sources", and the output directory (e.g.
target/classes) in the classpath.

When Eclipse "built" this, and then Maven is run without "clean", the javadoc
finds the package.html in both the sources, and in its classpath, and after Java
1.5, now generates the warning message about multiple sources of package
comments found...


Can the m2e setup for Eclipse do something when setting up the Eclipse
build-path add an exclusion to the src/main/java path to exclude (not copy)
files which Maven's build would not copy, like package.html?

-Marshall Schor
_______________________________________________
m2e-dev mailing list
m2e-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/m2e-dev



Back to the top