2007/12/18, Marcus Better <[EMAIL PROTECTED]>:
> Arnaud Vandyck wrote:
> > if mvn present:
> >   mvn install -DgroupId=... -DversionId=... -DartifactId=...
> > /usr/share/java/my.jar
>
> If it's meant to be run in postinst then Maven might not be installed yet.

Yes, I was thinking about putting the code in postinst...

> But I wonder how we are going to handle versioned dependencies. Maven
> projects tend to specify exact version numbers, right? That could be a real
> headache. I don't think we can ignore the version number, but we cannot use
> it as a hard dependency either.

There is a -SNAPSHOT special versionning that could be used. But My
first thought was to "install" the jar so: duplicate the jar with the
exact version number:

If you install liblog4j1.2-java 1.2.13-5, then, you'll have:

/usr/share/java/log4j-1.2.jar -> log4j-1.2.13
/usr/share/java/log4j-1.2.13.jar
+
/var/lib/maven/repository/log4j/log4j/1.2.13/log4j-1.2.13.jar (+sha, pom, etc)

if you install liblog4j1.2-java 1.2.15-2, no more 1.2.13 in /usr/share/java but:

/usr/share/java/log4j-1.2.jar -> log4j-1.2.15
/usr/share/java/log4j-1.2.15.jar
+
/var/lib/maven/repository/log4j/log4j/1.2.13/log4j-1.2.13.jar (+sha, pom, etc)
/var/lib/maven/repository/log4j/log4j/1.2.15/log4j-1.2.15.jar (+sha, pom, etc)

The idea is to provide a local "debian" repo for maven. But maybe it's
not the best idea! Other comments will be in other responses.

-- 
Arnaud Vandyck

_______________________________________________
pkg-java-maintainers mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/pkg-java-maintainers

Reply via email to