FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian Java

 
 
LinkBack Thread Tools
 
Old 05-30-2011, 04:48 PM
Miguel Telleria de Esteban
 
Default maven and javadoc packaging

Hello again,

I am still quarreling against my first java and maven package[1]. Now I
have two issues to report with the javadoc .jar file.

MINOR
* In the debuild process the javadoc:jar target is CALLED TWICE:

- First in the build target (after the package)
- Second in the fakeroot debian/rules binary target

In both cases the javadoc API files (html) are placed under
target/apidocs and a .jar file is placed in the target directory
(together with the jar class file).

MAYOR

* The javadoc files are not included in the binary package.

Instead the generated esper-4.0.0-javadoc.jar is copied to

debian/null/usr/share/maven-repo/com/espertech/esper/4.0.0

These are the operations that I have done related with packaging:

* Define a libesper-java-doc package in control

* In debian/rules, I have added the lines:

DEB_MAVEN_DOC_TARGET := javadoc:jar
DEB_DOC_PACKAGE := libesper-java-doc

* I have the following tag in the pom.xml (unchanged from upstream)

<plugin>
<artifactId>maven-site-plugin</artifactId>
<configuration>
<locales>en</locales>
<templateFile>src/site/site.vm</templateFile>
</configuration>
<version>2.1</version>
</plugin>

inside <build></plugins>

Any insight will be greatly appreciated. The current status of my
packaging is available at:

[1] http://mtelleria.com/esper_maven_debian/

I am in #debian-java IRC now (nick snapy).

Regards,

Miguel

PS: Once I clarify all my question I will happily volunteer to
document my work in the wiki.

--

(O-O)
---oOO-(_)-OOo-----------------------------------------------------
Miguel TELLERIA DE ESTEBAN http://www.mtelleria.com
Email: miguel at mtelleria.com Tel GSM: +34 650 801098
Tel Fix: +34 942 280174

Miembro de http://www.linuca.org Membre du http://www.bxlug.be
¿Usuario captivo o libre? http://www.obtengalinux.org/windows/
Free or captive user? http://www.getgnulinux.org/windows/
-------------------------------------------------------------------
 
Old 05-31-2011, 12:00 PM
Miguel Telleria de Esteban
 
Default maven and javadoc packaging

I just comment the progress of my work,

On Mon, 30 May 2011 18:48:51 +0200 Miguel Telleria de Esteban wrote:

> Hello again,
>
> I am still quarreling against my first java and maven package[1].
> Now I have two issues to report with the javadoc .jar file.
>
> MINOR
> * In the debuild process the javadoc:jar target is CALLED TWICE:
>
> - First in the build target (after the package)
> - Second in the fakeroot debian/rules binary target

Nothing done to fix it. For the moment it doesn't bother me (much)

> MAYOR
>
> * The javadoc files are not included in the binary package.
>
> Instead the generated esper-4.0.0-javadoc.jar is copied to
>
> debian/null/usr/share/maven-repo/com/espertech/esper/4.0.0
>

Several things to note.

The "null" directory string originates from an unitialized attribute in
InstallDocMojo.java inside debian-maven-helper. I have submitted a bug
on this with a patch.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=628693

with this fix the javadoc.jar is installed inside /usr/share/maven-repo
as an artifact.

However now the question is:

do I really need to install the javadoc .jar file as a maven
artifact?

and the answer is NO. I only wanted to place javadoc HTML files in

/usr/share/doc/libesper-java-doc/api dir.

and, as suggested in #debian-java IRC, this can is easily done with
a DH file:

debian/libesper-java-doc.install file containing

target/apidocs/* usr/share/doc/libesper-java-doc/api

so I did it and it works, I have my javadoc html files properly
installed.

There is still a problem, the javadoc .jar file is installed as well in
the u.s.maven-repo and I decided to disable this by setting in
debian/rules

DEB_MAVEN_INSTALL_DOC_TARGET :=

A final note on this: Of course I shouldn't need to do this javadoc
manggling myself, mh_make should have done it for me, but I guess this
is due to me not answering mh_make questions or having a bogus control
file.

SO, REMAINING QUESTIONS:

* Why is the javadoc:jar goal called twice

* How do I have to use mh_make to:

* Automagically get a libesper-java-doc.install file.
* Not having the install-doc goal called

Regards,

Miguel


--

(O-O)
---oOO-(_)-OOo-----------------------------------------------------
Miguel TELLERIA DE ESTEBAN http://www.mtelleria.com
Email: miguel at mtelleria.com Tel GSM: +34 650 801098
Tel Fix: +34 942 280174

Miembro de http://www.linuca.org Membre du http://www.bxlug.be
¿Usuario captivo o libre? http://www.obtengalinux.org/windows/
Free or captive user? http://www.getgnulinux.org/windows/
-------------------------------------------------------------------
 
Old 05-31-2011, 12:00 PM
Miguel Telleria de Esteban
 
Default maven and javadoc packaging

I just comment the progress of my work,

On Mon, 30 May 2011 18:48:51 +0200 Miguel Telleria de Esteban wrote:

> Hello again,
>
> I am still quarreling against my first java and maven package[1].
> Now I have two issues to report with the javadoc .jar file.
>
> MINOR
> * In the debuild process the javadoc:jar target is CALLED TWICE:
>
> - First in the build target (after the package)
> - Second in the fakeroot debian/rules binary target

Nothing done to fix it. For the moment it doesn't bother me (much)

> MAYOR
>
> * The javadoc files are not included in the binary package.
>
> Instead the generated esper-4.0.0-javadoc.jar is copied to
>
> debian/null/usr/share/maven-repo/com/espertech/esper/4.0.0
>

Several things to note.

The "null" directory string originates from an unitialized attribute in
InstallDocMojo.java inside debian-maven-helper. I have submitted a bug
on this with a patch.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=628693

with this fix the javadoc.jar is installed inside /usr/share/maven-repo
as an artifact.

However now the question is:

do I really need to install the javadoc .jar file as a maven
artifact?

and the answer is NO. I only wanted to place javadoc HTML files in

/usr/share/doc/libesper-java-doc/api dir.

and, as suggested in #debian-java IRC, this can is easily done with
a DH file:

debian/libesper-java-doc.install file containing

target/apidocs/* usr/share/doc/libesper-java-doc/api

so I did it and it works, I have my javadoc html files properly
installed.

There is still a problem, the javadoc .jar file is installed as well in
the u.s.maven-repo and I decided to disable this by setting in
debian/rules

DEB_MAVEN_INSTALL_DOC_TARGET :=

A final note on this: Of course I shouldn't need to do this javadoc
manggling myself, mh_make should have done it for me, but I guess this
is due to me not answering mh_make questions or having a bogus control
file.

SO, REMAINING QUESTIONS:

* Why is the javadoc:jar goal called twice

* How do I have to use mh_make to:

* Automagically get a libesper-java-doc.install file.
* Not having the install-doc goal called

Regards,

Miguel


--

(O-O)
---oOO-(_)-OOo-----------------------------------------------------
Miguel TELLERIA DE ESTEBAN http://www.mtelleria.com
Email: miguel at mtelleria.com Tel GSM: +34 650 801098
Tel Fix: +34 942 280174

Miembro de http://www.linuca.org Membre du http://www.bxlug.be
¿Usuario captivo o libre? http://www.obtengalinux.org/windows/
Free or captive user? http://www.getgnulinux.org/windows/
-------------------------------------------------------------------
 

Thread Tools




All times are GMT. The time now is 11:01 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org