I just did a fresh checkout and build on a Linux machine without any
problems.

It looks like on your system ant is for some reason using a buggy version of
saxon rather than the one included in lib.  Maybe you have an old version of
saxon installed in ~/.ant/lib or as a java extension?

To verify try:

  java -jar lib/saxon9.jar -s:modules.xml -xsl:build.xsl -o:modbuild.xml

You will see that it works fine, just give a warning about running an XSLT
1.0 stylesheet with an XSLT 2.0 processor.

James

On Wed, Dec 24, 2008 at 11:40 AM, blaine_simpson <[email protected]>wrote:

> Your suggestion doesn't work, but I gave up on Jing-Trang and easily
> customized Sun's MSV to do what I want.  This isn't a trivial
> environment or installation problem (evidence follows).  I'm an Ant,
> UNIX, and Java guru.  I post here only to give some info for others
> with setups similar to mine (OpenSUSE 11.0 + latest Ant + Sun JDK) who
> will run into the same problem.
>
> beyla$ declare -x | grep -i ant
> declare -x
>
> PATH="/usr/lib/jvm/java-1.6.0-sun/bin:/opt/kde3/bin:/local/ant/bin:/home/blaine/bgi/codeshare:.:/home/blaine/bin:/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/X11R6/bin:/usr/games:/usr/lib/mit/bin:/usr/lib/mit/sbin:/usr/NX/bin:/local/maven/bin"
> beyla$ which ant
> /local/ant/bin/ant
> beyla$ type ant
> ant is /local/ant/bin/ant
> beyla$ ls -ld /local/ant
> lrwxrwxrwx 1 root root 9 2008-12-24 06:27 /local/ant -> ant-1.7.1
> beyla$ echo $CLASSPATH
>
> beyla$ echo $JAVA_HOME
> /usr/lib/jvm/java-1.6.0-sun
> beyla$ type java
> java is /usr/lib/jvm/java-1.6.0-sun/bin/java
> beyla$ java -version
> java version "1.6.0_07"
> Java(TM) SE Runtime Environment (build 1.6.0_07-b06)
> Java HotSpot(TM) Server VM (build 10.0-b23, mixed mode)
> beyla$ type javac
> javac is /usr/lib/jvm/java-1.6.0-sun/bin/javac
> beyla$ ./ant clean
> Buildfile: ./build.xml
>
> clean:
>
> BUILD SUCCESSFUL
> Total time: 0 seconds
> beyla$ ./ant
> Buildfile: ./build.xml
>
> check-modules:
>
> modules:
>
> check-modbuild:
>
> modbuild:
>     [xslt] Processing /tmp/jing-trang/modules.xml to
> /tmp/jing-trang/modbuild.xml
>     [xslt] Loading stylesheet /tmp/jing-trang/build.xsl
>     [xslt] /tmp/jing-trang/build.xsl:183:105: Fatal Error! Required
> item type of second argument of document() is node(); supplied value
> has item type xs:string
>     [xslt] /tmp/jing-trang/build.xsl:78:30: Fatal Error! Required
> item type of second argument of document() is node(); supplied value
> has item type xs:string
>     [xslt] Failed to process /tmp/jing-trang/modules.xml
>
> BUILD FAILED
> javax.xml.transform.TransformerConfigurationException: Failed to
> compile stylesheet. 2 errors detected.
>        at
> net.sf.saxon.PreparedStylesheet.prepare(PreparedStylesheet.java:176)
>        at
>
> net.sf.saxon.TransformerFactoryImpl.newTemplates(TransformerFactoryImpl.java:139)
>        at
>
> org.apache.tools.ant.taskdefs.optional.TraXLiaison.readTemplates(TraXLiaison.java:303)
>        at
>
> org.apache.tools.ant.taskdefs.optional.TraXLiaison.createTransformer(TraXLiaison.java:320)
>        at
>
> org.apache.tools.ant.taskdefs.optional.TraXLiaison.transform(TraXLiaison.java:170)
>        at
> org.apache.tools.ant.taskdefs.XSLTProcess.process(XSLTProcess.java:709)
>        at
> org.apache.tools.ant.taskdefs.XSLTProcess.execute(XSLTProcess.java:333)
>        at
> org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
>        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>        at
>
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>        at
>
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>        at java.lang.reflect.Method.invoke(Method.java:597)
>        at
> org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
>        at org.apache.tools.ant.Task.perform(Task.java:348)
>        at org.apache.tools.ant.Target.execute(Target.java:357)
>        at org.apache.tools.ant.Target.performTasks(Target.java:385)
>        at
> org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
>        at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
>        at
>
> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
>        at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
>        at org.apache.tools.ant.Main.runBuild(Main.java:758)
>        at org.apache.tools.ant.Main.startAnt(Main.java:217)
>        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
>        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
>
> Total time: 0 seconds
> beyla$
>
> --- In [email protected], "James Clark" <j...@...> wrote:
> >
> > Are you building using the command
> >
> >   ./ant
> >
> > (which will make it use the jars in the lib directory, including ant
> > 1.7.1)?  If not, try that, after doing
> >
> >  ./ant clean
> >
> > to clean up from previous attempts.
> >
> > James
> >
> > On Tue, Dec 23, 2008 at 8:53 PM, blaine_simpson
> <blaine.simp...@...>wrote:
> >
> > > Hi.  I have a very clean Linux environment, but the build is failing
> > > with Sun JDK 1.5 and 1.6:
> > >
> > >     [xslt] : Error! file:/tmp/jing-trang/build.xsl: line 183: Second
> > > argument to document() function must be a node-set.
> > >
> > > Ant 1.7.0 with no CLASSPATH set.  The failing XSLT line is:
> > >
> > >        <xsl:for-each select="document(concat('mod/',
> @module,'/mod.xml'),
> > > $root)/module/ant/@precompile">
> > >
> > > with the transformer apparently unappy with "$root".  $root doesn't
> > > seem like a variable name for a node "set".
> > >
> > > I build tons of Java software successfully on this system.  I don't
> > > have days to spend debugging this XSLT problem.
> > >
> > > Does anybody out there have a recently built jing.jar?  I need the
> > > catalog feature, and that was added shortly after the last available
> > > distro on 10/28.
> > >
> > >
> > > ------------------------------------
> > >
> > > Yahoo! Groups Links
> > >
> > >
> > >
> > >
> >
>
>
>
> ------------------------------------
>
> Yahoo! Groups Links
>
>
>
>

Reply via email to