maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Fred Vos <fred....@gmail.com>
Subject Can't get doxia-module-docbook-simple version 1.1 or 1.1.1 working
Date Sun, 06 Sep 2009 20:39:08 GMT
Hello,

Im struggling with this for some time now. I'm trying to setup
documentation using reStructuredText as the document format. But I'm
having troubles getting things done.

$ mvn -version
Apache Maven 2.2.1 (r801777; 2009-08-06 21:16:01+0200)
Java version: 1.6.0_14
Java home: /usr/lib/jvm/java-6-sun-1.6.0.14/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux" version: "2.6.28-15-generic" arch: "i386" Family: "unix"

I'm working under Kubuntu 9.04.

In the pre-site phase I transform the .rst files to Docbook .xml
files. This is done in two steps in an Ant task. First rst2xml from
the python-docutils package is used to transform the .rst files into
an intermediate XML format and then dn2dbk.xsl
(http://membres.lycos.fr/ebellot/dn2dbk/#dn2dbk) is used in an xslt
task to transform the intermediate XML into Docbook XML.

Using doxia-module-docbook-simple I should be able to use the
generated Docbook texts for the site. This works for version 1.0 of
doxia-module-docbook-simple, but that version doesn't support
images. To include images anyway I now include paragraphs like

image ../images/screenshot.png title=Screenshot alt=Screenshot width=600 egami

in my .rst file and in a post-site Ant task I convert such a paragraph
into a real <img .../> tag using a Perl script.

According to http://jira.codehaus.org/browse/DOXIA-321 version 1.1.1
of doxia-module-docbook-simple has solved the issue with images, but
for me this version causes problems in Maven.

In my pom.xml:

      <plugin>
        <artifactId>maven-site-plugin</artifactId>
        <!--version>2.0-beta-6</version-->
        <version>2.0.1</version>
        <dependencies>
          <dependency>
            <groupId>org.apache.maven.doxia</groupId>
            <artifactId>doxia-module-docbook-simple</artifactId>
            <!--version>1.0-alpha-10</version-->
            <version>1.1.1</version>
          </dependency>
        </dependencies>
        <configuration>
          <siteDirectory>${basedir}/target/pre-site</siteDirectory>
        </configuration>
      </plugin>

With a local repository that I cleaned up 10 minutes before (apologies
for the long listing):

$ mvn clean site
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Building Telex
[INFO]    task-segment: [clean, site]
[INFO] ------------------------------------------------------------------------
[INFO] [clean:clean {execution: default-clean}]
[INFO] Deleting directory /home/vosf/dev/mokolo/trunk/software/telex/target
[INFO] [antrun:run {execution: pre-site}]
[INFO] Executing tasks

init:
    [mkdir] Created dir: /home/vosf/dev/mokolo/trunk/software/telex/target

pre-copy:
     [copy] Copying 2 files to /home/vosf/dev/mokolo/trunk/software/telex/target/pre-site

rst2docbook:
    [mkdir] Created dir: /home/vosf/dev/mokolo/trunk/software/telex/target/pre-site/temp-xml/documentation
    [apply] Applied rst2xml to 1 file and 0 directories.
    [mkdir] Created dir: /home/vosf/dev/mokolo/trunk/software/telex/target/pre-site/docbook
     [xslt] Transforming into /home/vosf/dev/mokolo/trunk/software/telex/target/pre-site/docbook
     [xslt] Processing /home/vosf/dev/mokolo/trunk/software/telex/target/pre-site/temp-xml/documentation/introduction.xml
to /home/vosf/dev/mokolo/trunk/software/telex/target/pre-site/docbook/documentation/introduction.xml
     [xslt] Loading stylesheet /home/vosf/dev/mokolo/trunk/software/parent/dn2dbk.xsl
   [delete] Deleting directory /home/vosf/dev/mokolo/trunk/software/telex/target/pre-site/temp-xml

dot2png:
    [apply] Applied dot to 1 file and 0 directories.

pre-site:
[INFO] Executed tasks
[INFO] Preparing javadoc:javadoc
[INFO] No goals needed for project - skipping
[INFO] [site:site {execution: default-site}]
[INFO] Generating "Project Team" report.
[FATAL ERROR] org.apache.maven.plugins.site.SiteMojo#execute() caused a linkage error (java.lang.NoClassDefFoundError)
and may be out-of-date. Check the realms:
[FATAL ERROR] Plugin realm = app0.child-container[org.apache.maven.plugins:maven-site-plugin:2.0.1]
urls[0] = file:/home/vosf/.m2/repository/org/apache/maven/plugins/maven-site-plugin/2.0.1/maven-site-plugin-2.0.1.jar
urls[1] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-module-docbook-simple/1.1.1/doxia-module-docbook-simple-1.1.1.jar
urls[2] = file:/home/vosf/.m2/repository/org/codehaus/plexus/plexus-utils/1.5.1/plexus-utils-1.5.1.jar
urls[3] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-core/1.1.1/doxia-core-1.1.1.jar
urls[4] = file:/home/vosf/.m2/repository/xerces/xercesImpl/2.8.1/xercesImpl-2.8.1.jar
urls[5] = file:/home/vosf/.m2/repository/xml-apis/xml-apis/1.3.03/xml-apis-1.3.03.jar
urls[6] = file:/home/vosf/.m2/repository/commons-lang/commons-lang/2.4/commons-lang-2.4.jar
urls[7] = file:/home/vosf/.m2/repository/commons-httpclient/commons-httpclient/3.1/commons-httpclient-3.1.jar
urls[8] = file:/home/vosf/.m2/repository/commons-logging/commons-logging/1.0.4/commons-logging-1.0.4.jar
urls[9] = file:/home/vosf/.m2/repository/commons-codec/commons-codec/1.2/commons-codec-1.2.jar
urls[10] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-module-xhtml/1.0/doxia-module-xhtml-1.0.jar
urls[11] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-decoration-model/1.0/doxia-decoration-model-1.0.jar
urls[12] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-site-renderer/1.0/doxia-site-renderer-1.0.jar
urls[13] = file:/home/vosf/.m2/repository/org/codehaus/plexus/plexus-i18n/1.0-beta-7/plexus-i18n-1.0-beta-7.jar
urls[14] = file:/home/vosf/.m2/repository/org/codehaus/plexus/plexus-velocity/1.1.7/plexus-velocity-1.1.7.jar
urls[15] = file:/home/vosf/.m2/repository/org/apache/velocity/velocity/1.5/velocity-1.5.jar
urls[16] = file:/home/vosf/.m2/repository/commons-collections/commons-collections/3.2/commons-collections-3.2.jar
urls[17] = file:/home/vosf/.m2/repository/oro/oro/2.0.8/oro-2.0.8.jar
urls[18] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-module-apt/1.0/doxia-module-apt-1.0.jar
urls[19] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-module-fml/1.0/doxia-module-fml-1.0.jar
urls[20] = file:/home/vosf/.m2/repository/org/apache/maven/doxia/doxia-module-xdoc/1.0/doxia-module-xdoc-1.0.jar
urls[21] = file:/home/vosf/.m2/repository/org/apache/maven/shared/maven-doxia-tools/1.0.2/maven-doxia-tools-1.0.2.jar
urls[22] = file:/home/vosf/.m2/repository/commons-io/commons-io/1.4/commons-io-1.4.jar
urls[23] = file:/home/vosf/.m2/repository/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar
urls[24] = file:/home/vosf/.m2/repository/org/mortbay/jetty/jetty/6.1.5/jetty-6.1.5.jar
urls[25] = file:/home/vosf/.m2/repository/org/mortbay/jetty/jetty-util/6.1.5/jetty-util-6.1.5.jar
urls[26] = file:/home/vosf/.m2/repository/org/mortbay/jetty/servlet-api-2.5/6.1.5/servlet-api-2.5-6.1.5.jar
[FATAL ERROR] Container realm = plexus.core
urls[0] = file:/opt/apache-maven-2.2.1/lib/maven-2.2.1-uber.jar
[INFO] ------------------------------------------------------------------------
[ERROR] FATAL ERROR
[INFO] ------------------------------------------------------------------------
[INFO] org/apache/maven/doxia/sink/StructureSink
org.apache.maven.doxia.sink.StructureSink
[INFO] ------------------------------------------------------------------------
[INFO] Trace
java.lang.NoClassDefFoundError: org/apache/maven/doxia/sink/StructureSink
	at org.apache.maven.doxia.module.xhtml.XhtmlSink.link(XhtmlSink.java:1013)
	at org.apache.maven.doxia.module.xhtml.XhtmlSink.link(XhtmlSink.java:989)
	at org.apache.maven.reporting.AbstractMavenReportRenderer.link(AbstractMavenReportRenderer.java:263)
	at org.apache.maven.reporting.AbstractMavenReportRenderer.linkPatternedText(AbstractMavenReportRenderer.java:376)
	at org.apache.maven.reporting.AbstractMavenReportRenderer.tableCell(AbstractMavenReportRenderer.java:213)
	at org.apache.maven.reporting.AbstractMavenReportRenderer.tableCell(AbstractMavenReportRenderer.java:193)
	at org.apache.maven.report.projectinfo.TeamListReport$TeamListRenderer.renderDeveloper(TeamListReport.java:253)
	at org.apache.maven.report.projectinfo.TeamListReport$TeamListRenderer.renderBody(TeamListReport.java:184)
	at org.apache.maven.reporting.AbstractMavenReportRenderer.render(AbstractMavenReportRenderer.java:65)
	at org.apache.maven.report.projectinfo.TeamListReport.executeReport(TeamListReport.java:70)
	at org.apache.maven.reporting.AbstractMavenReport.generate(AbstractMavenReport.java:90)
	at org.apache.maven.plugins.site.ReportDocumentRenderer.renderDocument(ReportDocumentRenderer.java:139)
	at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.renderModule(DefaultSiteRenderer.java:303)
	at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.render(DefaultSiteRenderer.java:135)
	at org.apache.maven.plugins.site.SiteMojo.renderLocale(SiteMojo.java:133)
	at org.apache.maven.plugins.site.SiteMojo.execute(SiteMojo.java:100)
	at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556)
	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535)
	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348)
	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
	at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
	at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
	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.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
	at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
	at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
	at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.ClassNotFoundException: org.apache.maven.doxia.sink.StructureSink
	at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
	at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
	at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
	at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
	at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
	at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
	... 35 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 9 seconds
[INFO] Finished at: Sun Sep 06 22:22:25 CEST 2009
[INFO] Final Memory: 35M/127M
[INFO] ------------------------------------------------------------------------

I had the same problem with the Ubuntu version of Maven
2.0.9. Removing that version and unpacking a downloaded version 2.2.1
didn't help, nor did starting with a new local repo. Does anyone know
how I can get version 1.1.1 of doxia-module-docbook-simple working, so
I can use images in my reStructuredText documentation in a normal way?

Or is it possible to use reStructuredText for documentation in a Maven
site via another - less complicated - path?

Thanks for your help.

Fred Vos

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Mime
View raw message