[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: java dependency substvars and native compilation

On Wed May 02 16:54, Michael Koch wrote:
> On Wed, May 02, 2007 at 03:15:39PM +0100, Matthew Johnson wrote:
> > On Wed May 02 15:57, Michael Koch wrote:
> > > On Wed, May 02, 2007 at 01:58:46PM +0100, Matthew Johnson wrote:
> > > > Two subjects to this mail. Firstly, I had a go at writing a dh_javadeps
> > > > which will search for jar files, find the classes they reference and
> > > > find the packages they are in. This can be found at
> > > > http://mjj29.matthew.ath.cx/dh_javadeps It updates $package.substvars so
> > > > you can use ${java:Depends} in control files.
> > > 
> > > Thats really nice to have. Unfortunately it didnt worked on a pretty
> > > simple example for me.
> > 
> > Hmm, could you let me know what the example was (it worked on my pretty
> > simple example)
> I created debian/test and put ant.jar into it. Then I executed
> dh_javadeps -p test
> As output I got this:
> xargs: unmatched einfache quote; by default quotes are special to xargs
> unless you use the -0 option

Hmm, odd. I've just updated the one at that URL in case I rewrote it and
the following works for me:

 mkdir -p debian/test
 cp /usr/share/java/ant-1.6.jar debian/test
 touch debian/control
 dh_javadeps -p test
 cat debian/test.substvars 

> I think about code paths that are only used when you use certain
> features of a program. When the dependency itself has a long list of
> depdencies it can make sense to not hardly depend on it when its only
> needed/used by 0.1% of the users of a program.

and you assume the program nicely handles this case? I think anything
which causes the JVM to throw an exception failing to load a class
requires a depends. (not that my code above does this, it's a bit of a
hack and is likely to over-depend)

> No, thats no bug. E.g. we ship different versions of the servlet
> specification in Debian. ASM is another example. We have currently two
> major versions in Debian. A third is coming soon. All have similar to
> equal class names (with sometimes different APIs). Thats no bug. Thats
> common practice in Java-land.

Hmm, that feels totally wrong to me. Possibly a --prefer= parameter?


Matthew Johnson

Attachment: signature.asc
Description: Digital signature

Reply to: