当前位置 : 主页 > 网页制作 > xml >

DocBook-XML和webhelp

来源:互联网 收集:自由互联 发布时间:2021-06-13
按照这里提到的步骤: http://docbook.sourceforge.net/release/xsl/current/webhelp/docs/ch02s01.html ant webhelp -Doutput-dir = test-ouput(ouput是我认为的文档中的拼写错误,但我用test-ouput和test-output测试了它的结
按照这里提到的步骤: http://docbook.sourceforge.net/release/xsl/current/webhelp/docs/ch02s01.html

ant webhelp -Doutput-dir = test-ouput(ouput是我认为的文档中的拼写错误,但我用test-ouput和test-output测试了它的结果相同)

经过测试

> Windows 8和Windows 8.1
> java版“1.7.0_51”
> ant 1.8.2和ant 1.9.3
> docbook-xsl-1.78.1
> xerces-2_11_0
> saxon6-5-5

知道我应该去哪看?

输出:

Buildfile: D:\apps\docbook-xsl-1.78.1\webhelp\build.xml

validate:

clean:
   [delete] Deleting directory D:\apps\docbook-xsl-1.78.1\webhelp\test-ouput

chunk:
    [mkdir] Created dir: D:\apps\docbook-xsl-1.78.1\webhelp\test-ouput
     [xslt] Processing D:\apps\docbook-xsl-1.78.1\webhelp\docsrc\readme.xml to D:\apps\docbook-xsl-1.78.1\webhelp\test-ouput\null2007605189
     [xslt] Loading stylesheet D:\apps\docbook-xsl-1.78.1\profiling\profile.xsl
     [xslt] Processing D:\apps\docbook-xsl-1.78.1\webhelp\test-ouput\null2007605189 to D:\apps\docbook-xsl-1.78.1\webhelp\test-ouput\null295245132
     [xslt] Loading stylesheet D:\apps\docbook-xsl-1.78.1\webhelp\xsl\webhelp.xsl
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/autoidx.xsl: line 551: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/autoidx.xsl: line 600: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/autoidx.xsl: line 600: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/autoidx.xsl: line 624: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/autoidx.xsl: line 624: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/lists.xsl: line 815: Attribut 'type' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/callout.xsl: line 109: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/xref.xsl: line 181: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/xref.xsl: line 966: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 96: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 96: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 131: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 131: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 171: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 171: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 707: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 924: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 1041: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 1171: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 1171: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 1271: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/inline.xsl: line 1309: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/glossary.xsl: line 329: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/glossary.xsl: line 329: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/glossary.xsl: line 402: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/glossary.xsl: line 402: Attribut 'href' befindet sich nicht in einem Element.
     [xslt] : Warning! file:/D:/apps/docbook-xsl-1.78.1/xhtml/annotations.xsl: line 106: Attribut 'onClick' befindet sich nicht in einem Element.
     [xslt] : Error! null
     [xslt] Failed to process D:\apps\docbook-xsl-1.78.1\webhelp\test-ouput\null2007605189

BUILD FAILED
D:\apps\docbook-xsl-1.78.1\webhelp\build.xml:62: javax.xml.transform.TransformerException: java.lang.NullPointerException
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:716)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:313)
        at org.apache.tools.ant.taskdefs.optional.TraXLiaison.transform(TraXLiaison.java:194)
        at org.apache.tools.ant.taskdefs.XSLTProcess.process(XSLTProcess.java:852)
        at org.apache.tools.ant.taskdefs.XSLTProcess.execute(XSLTProcess.java:388)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
        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:390)
        at org.apache.tools.ant.Target.performTasks(Target.java:411)
        at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
        at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
        at org.apache.tools.ant.Main.runBuild(Main.java:809)
        at org.apache.tools.ant.Main.startAnt(Main.java:217)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
Caused by: java.lang.NullPointerException
        at com.sun.org.apache.xalan.internal.xsltc.runtime.BasisLibrary.referenceToNodeSet(BasisLibrary.java:998)
        at webhelp.l10n$dot$language()
        at webhelp.topLevel()
        at webhelp.transform()
        at com.sun.org.apache.xalan.internal.xsltc.runtime.AbstractTranslet.transform(AbstractTranslet.java:603)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:709)
        ... 21 more
---------
java.lang.NullPointerException
        at com.sun.org.apache.xalan.internal.xsltc.runtime.BasisLibrary.referenceToNodeSet(BasisLibrary.java:998)
        at webhelp.l10n$dot$language()
        at webhelp.topLevel()
        at webhelp.transform()
        at com.sun.org.apache.xalan.internal.xsltc.runtime.AbstractTranslet.transform(AbstractTranslet.java:603)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:709)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:313)
        at org.apache.tools.ant.taskdefs.optional.TraXLiaison.transform(TraXLiaison.java:194)
        at org.apache.tools.ant.taskdefs.XSLTProcess.process(XSLTProcess.java:852)
        at org.apache.tools.ant.taskdefs.XSLTProcess.execute(XSLTProcess.java:388)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
        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:390)
        at org.apache.tools.ant.Target.performTasks(Target.java:411)
        at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
        at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
        at org.apache.tools.ant.Main.runBuild(Main.java:809)
        at org.apache.tools.ant.Main.startAnt(Main.java:217)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)

Total time: 13 seconds
基于堆栈跟踪,您似乎正在使用Xalan进行xsl转换.建议将Saxon 6.5.5与Webhelp一起使用,这也是一个Java impl.您可以通过将build.properties中的xslt-processor-classpath设置为撒克逊jar的位置来指向Saxon.同时,您还应该设置xercesImpl.jar和xml-apis.jar属性.

修改webhelp build.properties中的以下内容,使它们指向您的本地
 罐子的副本表明:

>撒克逊人6.5罐
> Xerces 2:xercesImpl.jar
> xml-commons:xml-apis.jar

XSLT处理器的类路径= / USR /共享/爪哇/撒克逊6.5.5.jar

xercesImpl.jar =的/ usr /共享/ JAVA / xercesImpl.jar

XML-apis.jar =的/ usr /共享/ JAVA / XML的apis.jar

网友评论