You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Michael McCallum <gh...@apache.org> on 2008/03/25 06:03:50 UTC

Compiler plugin picks up source from jars in classpath

I found that one of my dependencies bundles some source in the jar... the 
compiler plugin compiles it and it ends up in my artifact. Has anyone see 
this before?


-- 
Michael McCallum
Enterprise Engineer
mailto:gholam@apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Compiler plugin picks up source from jars in classpath

Posted by Benjamin Bentmann <be...@udo.edu>.
> I found that one of my dependencies bundles some source in the jar... the
> compiler plugin compiles it and it ends up in my artifact. Has anyone see
> this before?

This could be unrelated to the plugin but be a general issue with javac. If 
you read its tech docs [0], you notice that it reads source files from the 
class path as well and by default, also compiles them.

I didn't try it out, but the option "-implicit" sounds promising. As some 
last resort, shading the source files by moving them into a sub directory 
such that they cannot be found by type lookup should help.


Benjamin


[0] 
http://java.sun.com/javase/6/docs/technotes/tools/windows/javac.html#searching 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org