maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mark (JIRA)" <j...@apache.org>
Subject [jira] [Created] (MCOMPILER-263) basedir system property is wrong when executing annotation processor in non-forked mode
Date Thu, 03 Mar 2016 11:37:18 GMT
Mark created MCOMPILER-263:
------------------------------

             Summary: basedir system property is wrong when executing annotation processor
in non-forked mode
                 Key: MCOMPILER-263
                 URL: https://issues.apache.org/jira/browse/MCOMPILER-263
             Project: Maven Compiler Plugin
          Issue Type: Bug
    Affects Versions: 3.5.1
         Environment: Ubuntu Wily desktop, amd64, oracle java 8 1.8.0_74, maven 3.3.9
            Reporter: Mark


You can replay the problem by checking out

git clone https://github.com/jjYBdx4IL/example-maven-project-setups

and running

mvn clean install -f example-maven-project-setups/compile-time-annotation-processing

to verify it's okay.

Then switch fork mode to false in example-maven-project-setups/compile-time-annotation-processing/pom.xml

and re-run the command and watch it failing.

At the bottom of

example-maven-project-setups/compile-time-annotation-processing/src/main/java/com/github/jjYBdx4IL/maven/examples/annotations/AnnotationProcessor.java

you can see that I'm using the basedir sys prop to determine where to write code to. There
is now a target dir right where you executed the command, so it seems basedir is set to user.dir
when running the non-forked compiler/annotation processing.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message