Hi,
Something is happening during the java task, fork="true" which changes
the value of my input file variable. I need to use fork as xalan 2_2_D6
won't work other wise. The only way I can get it to work is by setting
the xalan classpath in the shell prior to running ant which I really
don't want to do. The following shows the target and the outputs.
<target name="html" if="htmlset">
<!-- make sure directories exist -->
<mkdir dir="${output.dir}"/>
<!-- some properties -->
<property name="outfile.wo.ext"
value="${output.dir}/${file.wo.ext}"/>
<property name="output.file" value="${outfile.wo.ext}.html"/>
<echo message="Transforming: ${input.file}"/>
<echo message="Into : ${output.file}"/>
<!-- Transform document into HTML -->
<java fork="false"
classname="${xslt.processor}"
classpathref="xalan.classpath">
<arg line="-IN ${input.file}
-XSL ${xhtml.driver}
-OUT ${output.file}"/>
</java>
</target>
Without fork output
------------------
Buildfile: bin/../build.xml
html:
[echo] Transforming: example.xml
[echo] Into : ./example.html
XSLT Error (javax.xml.transform.TransformerConfigurationException):
Namespace not supported by SAXParser
--------------------------------
With fork on the java task it parses the XSL file okay but then makes
the input file into the following which can't be found.
Buildfile: /home/maxwell/jdocbook/build.xml
html:
[echo] Transforming: /home/maxwell/jdocbook/example.xml
[echo] Into : /home/maxwell/jdocbook/example.html
[java]
[java] XSLT Error (javax.xml.transform.TransformerException): File
"file:////home/maxwell/jdocbook//home/maxwell/jdocbook/example.xml" not
found.
The strange thing is that the echo looks fine. What could cause this?
Thanks,
Eric