Bug#855689: jython.jar does not provide a Class-Path

2017-02-22 Thread Ole Streicher
Hi Gilles,

Am 21.02.2017 um 22:09 schrieb Gilles Filippini:
> Would the attached patch do the trick?

yes, I can confirm that this works well for me. Thank you for the quick fix.

Best regards

Ole

__
This is the maintainer address of Debian's Java team
. 
Please use
debian-j...@lists.debian.org for discussions and questions.


Bug#855689: jython.jar does not provide a Class-Path

2017-02-21 Thread Gilles Filippini
Hi Ole,

On Tue, 21 Feb 2017 09:54:48 +0100 Ole Streicher  wrote:
> Package: jython
> Version: 2.5.3-14
> Severity: serious
> 
> There is no classpath for the dependencies of jython.jar defined in its
> manifest:
> 
> $ unzip -p /usr/share/java/jython.jar META-INF/MANIFEST.MF | \
>   grep Class-Path
> $
> 
> This leads to the problem that dependent packages need to specify the
> classpath themself, which is difficult since it is not documented in
> /usr/share/docs/jython. Also, it requires tracking internal changes of
> jython, since some of the dependent jar names are version dependent;
> namely antlr3-runtime-3.2.jar, which makes it difficult to handle for
> the dependencies over long time (f.e. for backports).
> 
> Java policy requires to have the classpath documented. I would ask you
> to do this in the manifest (at least for the strong dependencies), since
> this makes the usage much easier.

Would the attached patch do the trick?

Thanks,

_g.
diff -Nru jython-2.5.3/debian/changelog jython-2.5.3/debian/changelog
--- jython-2.5.3/debian/changelog   2016-12-11 17:02:02.0 +0100
+++ jython-2.5.3/debian/changelog   2017-02-21 20:22:33.0 +0100
@@ -1,3 +1,9 @@
+jython (2.5.3-15) UNRELEASED; urgency=medium
+
+  * Set 'Class-Path' into jython.jar's manifest (closes: #855689)
+
+ -- Gilles Filippini   Tue, 21 Feb 2017 20:22:33 +0100
+
 jython (2.5.3-14) unstable; urgency=medium
 
   * debian/jython_perl: fix use of abs_path
diff -Nru jython-2.5.3/debian/patches/04-runtime-classpath.patch 
jython-2.5.3/debian/patches/04-runtime-classpath.patch
--- jython-2.5.3/debian/patches/04-runtime-classpath.patch  1970-01-01 
01:00:00.0 +0100
+++ jython-2.5.3/debian/patches/04-runtime-classpath.patch  2017-02-21 
20:22:33.0 +0100
@@ -0,0 +1,12 @@
+Index: jython/build.xml
+===
+--- jython.orig/build.xml
 jython/build.xml
+@@ -721,6 +721,7 @@ The readme text for the next release wil
+  
excludes="org/python/expose/generate/**,org/python/version.properties"/>   
+   
+   
++  
+   
+   
+   
diff -Nru jython-2.5.3/debian/patches/series jython-2.5.3/debian/patches/series
--- jython-2.5.3/debian/patches/series  2016-12-11 17:02:02.0 +0100
+++ jython-2.5.3/debian/patches/series  2017-02-21 20:22:33.0 +0100
@@ -1,3 +1,4 @@
 01-build.patch
 02-jnr_refactoring.patch
 03-default-cachedir.patch
+04-runtime-classpath.patch
diff -Nru jython-2.5.3/debian/rules jython-2.5.3/debian/rules
--- jython-2.5.3/debian/rules   2016-12-11 17:02:02.0 +0100
+++ jython-2.5.3/debian/rules   2017-02-21 20:22:33.0 +0100
@@ -1,5 +1,7 @@
 #!/usr/bin/make -f
 
+RTCLASSPATH := $(shell grep '^\s*appendJar' debian/jython_perl | sed 
"s/^.*('//;s/').*$$//" | tr '\n' ' ')
+
 %:
dh $@ --with python2 --with maven-repo-helper
 
@@ -31,7 +33,7 @@
 
 override_dh_auto_build:
# Build the class files.
-   ant -nouserlib developer-build jar javadoc
+   ant -nouserlib developer-build jar javadoc 
-DRuntimeClasspath="$(RTCLASSPATH)"
# -nouserlib is required to prevent conflicts with the ant jython plugin
 
# Generate OSGi metadata for jython.jar


signature.asc
Description: OpenPGP digital signature
__
This is the maintainer address of Debian's Java team
. 
Please use
debian-j...@lists.debian.org for discussions and questions.

Bug#855689: jython.jar does not provide a Class-Path

2017-02-21 Thread Ole Streicher
Package: jython
Version: 2.5.3-14
Severity: serious

There is no classpath for the dependencies of jython.jar defined in its
manifest:

$ unzip -p /usr/share/java/jython.jar META-INF/MANIFEST.MF | \
  grep Class-Path
$

This leads to the problem that dependent packages need to specify the
classpath themself, which is difficult since it is not documented in
/usr/share/docs/jython. Also, it requires tracking internal changes of
jython, since some of the dependent jar names are version dependent;
namely antlr3-runtime-3.2.jar, which makes it difficult to handle for
the dependencies over long time (f.e. for backports).

Java policy requires to have the classpath documented. I would ask you
to do this in the manifest (at least for the strong dependencies), since
this makes the usage much easier.

Thank you very much

Best regards

Ole

__
This is the maintainer address of Debian's Java team
. 
Please use
debian-j...@lists.debian.org for discussions and questions.