Tomcat's JSP precompiler does not seem to be able to handle tag files
containing Java 5 syntax -- it acts as if it were in "-source 1.4" [or
"-source 1.3", we don't use asserts much] mode.
Is this a known issue? Is there something to be done about this?
I'm doing:
<jasper2 uriroot="${docBase}" outputDir="${jspcJavaOutputDir}"
webXmlFragment="${jspcJavaOutputDir}/generated_web.xml"
compilerSourceVM="${sourceVer}" compilerTargetVM="${targetVer}"
validateXml="false" listErrors="true"
verbose="${jspcVerbosityLevel}" jspFiles="${jspFileList}" />
where jasper2 is taskdef'ed to org.apache.jasper.JspC. sourceVer and
targetVer are both 1.5.
And, yes, of course, my <javac> specifies target and source versions as
well ala:
<javac destdir="${classesOutputDir}" optimize="off" fork="yes"
memoryMaximumSize="${maxMem}" source="${sourceVer}"
target="${targetVer}" debug="on" failonerror="yes" encoding="UTF-8"
srcdir="${jspcJavaOutputDir}" excludes="**/*.smap"
verbose="${verboseJavac}">....
[Note the Tomcat docs should be updated to state that
encoding="UTF-8" should be used as that's the default output of JspC
and /not/ the default input of <javac>...]
Am I missing something here?
Note that the tag files in question work fine at runtime -- they just
won't precompile.
--
Jess Holle