Source: jpy
Severity: normal
Tags: patch

Dear Maintainer,

The package jpy fails to build from source on ppc64el, because of
discrepancies between the identifier for ppc64el architecture.

OpenJDK currently uses ppc64le on the arch directory, while jpy uses
`dpkg-architecture -qDEB_BUILD_ARCH_CPU` to get the arch string.
It returns 'ppc64el' and the search never finds the shared objects
needed to finish the build.

The patch attached works around that and changes 'ppc64el' to 'ppc64le'
during the build.

Thanks and regards.

Fernando
diff -Nru jpy-0.8/debian/changelog jpy-0.8/debian/changelog
--- jpy-0.8/debian/changelog	2016-07-07 04:43:08.000000000 -0400
+++ jpy-0.8/debian/changelog	2016-08-01 13:50:10.000000000 -0400
@@ -1,3 +1,11 @@
+jpy (0.8-4.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * debian/patches/ppc64el.patch: fixing ppc64el arch dir to fix FTBFS.
+    OpenJDK is currently using notation 'ppc64le'.
+
+ -- Fernando Seiti Furusato <ferse...@br.ibm.com>  Mon, 01 Aug 2016 13:48:50 -0400
+
 jpy (0.8-4) unstable; urgency=medium
 
   * Adapt patch to detect more archs correctly
diff -Nru jpy-0.8/debian/patches/ppc64el.patch jpy-0.8/debian/patches/ppc64el.patch
--- jpy-0.8/debian/patches/ppc64el.patch	1969-12-31 19:00:00.000000000 -0500
+++ jpy-0.8/debian/patches/ppc64el.patch	2016-08-01 13:51:43.000000000 -0400
@@ -0,0 +1,20 @@
+--- a/jpyutil.py
++++ b/jpyutil.py
+@@ -161,6 +161,8 @@
+     arch = check_output(['dpkg-architecture','-q', 'DEB_BUILD_ARCH_CPU']).strip()
+     if type(arch) != str: # python3
+         arch = arch.decode('utf-8')
++    if arch == 'ppc64el':
++        arch = 'ppc64le'
+     return (os.path.join(java_home_dir, 'bin'),
+             os.path.join(java_home_dir, 'bin', 'server'),
+             os.path.join(java_home_dir, 'bin', 'client'),
+@@ -200,6 +202,8 @@
+     arch = check_output(['dpkg-architecture','-q', 'DEB_BUILD_ARCH_CPU']).strip()
+     if type(arch) != str: # python3
+         arch = arch.decode('utf-8')
++    if arch == 'ppc64el':
++        arch = 'ppc64le'
+     search_dirs += "/usr/lib/jvm/default-java/jre/lib/%s/server" % arch
+ 
+     search_dirs = _add_paths_if_exists([], *search_dirs)
diff -Nru jpy-0.8/debian/patches/series jpy-0.8/debian/patches/series
--- jpy-0.8/debian/patches/series	2016-07-07 04:43:08.000000000 -0400
+++ jpy-0.8/debian/patches/series	2016-08-01 13:47:36.000000000 -0400
@@ -2,3 +2,4 @@
 default_jvm.patch
 python3.patch
 reproducible.patch
+ppc64el.patch

Reply via email to