PR: MPJAVA-42
Also check for ${maven.gen.src} before compiling.
git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@379596 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
1 parent
54a4c7bfdb
commit
ae7c9ed703
2 files changed
+15
-2
No files matched your search
+14
-2
@@ -42,9 +42,21 @@
|
||||
<goal name="java:compile"
|
||||
description="Compile the project"
|
||||
prereqs="java:prepare-filesystem">
|
||||
<ant:echo>Compiling to ${maven.build.dest}</ant:echo>
|
||||
|
||||
<maven:get var="generatedSources" plugin="maven-javacc-plugin" property="maven.gen.src" />
|
||||
<ant:available
|
||||
property="generatedSourcesPresent"
|
||||
file="${generatedSources}"/>
|
||||
|
||||
<j:if test="${generatedSourcesPresent}">
|
||||
<ant:path id="maven.generated.src.set" location="${generatedSources}"/>
|
||||
<maven:addPath id="maven.compile.src.set" refid="maven.generated.src.set"/>
|
||||
</j:if>
|
||||
|
||||
<j:choose>
|
||||
<j:when test="${sourcesPresent == 'true'}">
|
||||
<j:when test="${sourcesPresent == 'true' or generatedSourcesPresent == 'true'}">
|
||||
|
||||
<ant:echo>Compiling to ${maven.build.dest}</ant:echo>
|
||||
|
||||
<j:if test="${context.getVariable('maven.compile.target') == null}">
|
||||
<ant:echo>
|
||||
|
||||
Reference in new issue
Block a user