maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Karl Heinz Marbaise (JIRA)" <>
Subject [jira] [Commented] (MCOMPILER-244) Compiler plugin silently drops -XD flags when fork=false
Date Sat, 12 Aug 2017 19:18:00 GMT


Karl Heinz Marbaise commented on MCOMPILER-244:

If you use {{<fork>true</fork>}} javac  be called which then can use the given
options. If you don't use {{<fork>true</fork>}} the internal compiler api be used
and no such options can be changed during the build of Maven. You could give them via {{MAVEN_OPTS}}
also to the JVM which is used by Maven.

> Compiler plugin silently drops -XD flags when fork=false
> --------------------------------------------------------
>                 Key: MCOMPILER-244
>                 URL:
>             Project: Maven Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 3.0, 3.1, 3.2, 3.3
>            Reporter: Paweł Kozioł
> I have Java code that uses two classes from private Java API (\*). When
i tried to compile it using jdk1.8.0_45 it failed with error saying that package\*
does not exist. I found that i should add flag {{-XDignore.symbol.file}} to compiler arguments.
> It turns out that Maven Compiler Plugin silently ignores that flag and it does not work
unless you also specify {{<fork>true</fork>}} ([thanks to karmakaze from StackOverflow
for sollution|])
> If you cannot fix this to work with fork=false maybe you could add printing warning/error
to stdout?

This message was sent by Atlassian JIRA

View raw message