Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.6-beta-2
-
Fix Version/s: 1.6.4, 1.7-beta-1
-
Component/s: Ant integration
-
Labels:None
-
Number of attachments :
Description
If using groovyc with an embedded javac it is no longer possible to use Ant property substitution on the javac attributes.
For example having a call to groovyc like this:
<groovyc destdir="build" srcdir="src">
<javac source="$
</groovyc>
will lead to this error:
[groovyc] javac: invalid source release: ${javac.source}
This works fine with Groovy 1.5.7
I have attached a simple test case with a build.xml file which loads an external build.properties and then attempts to compile a single Java file.
To test simply edit the build.properties file to point groovy.home at a relevant Groovy installation.
Pointing it a my 1.6 b2 fails but 1.5.7 works.
I wasn't sure how to turn this into a Junit test easily though.
Issue Links
- is duplicated by
-
GROOVY-3450
Ant properties don't work within the source / target attributes on javac Ant task within groovyc task
-
I must say this sounds quite strange. the nested javac task is the normal javac as you know it from ant. We did not add something to the task Also when you say this works in 1.5.7... isn't it the same there? But I can reproduce the issue.