[
https://issues.apache.org/jira/browse/MCOMPILER-559?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Guillaume Nodet closed MCOMPILER-559.
-------------------------------------
Fix Version/s: 3.12.0
Resolution: Fixed
> Warn if overriding the project's artifact's file
> ------------------------------------------------
>
> Key: MCOMPILER-559
> URL: https://issues.apache.org/jira/browse/MCOMPILER-559
> Project: Maven Compiler Plugin
> Issue Type: Improvement
> Reporter: Benjamin Marwell
> Assignee: Guillaume Nodet
> Priority: Major
> Fix For: 3.12.0
>
>
> The use case is the following:
> * a module needs to consume (unpack) another module with resources
> * the consumed module thus specifies the jar goal to be run at compile time
> or before
> * the unpack fails because the artifact's file has been reset to
> {{${basedir}/target/classes}} by the m-compiler-p
> Diagnosing this problem took quite some time and debugging to understand what
> was happening.
> A warning in m-compiler-p to (at least) warn the user that something weird is
> going on would be welcomed. The other option is to not override and warn or
> reject (because compiling after the artifact has been packaged is quite
> unexpected).
> I'm not sure why this would be responsibility of the m-compiler-p to actually
> set the artifact's file to {{${basedir}/target/classes}}, as this could also
> be done by m-resource-p which also writes to that directory, or even earlier,
> when starting a given project build, by maven-core itself.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)