[SCM] Packaging for libjna-java a library for dynamic access of native libraries from Java without JNI branch, master, updated. debian/3.2.7-2-2-g8e9e964
Andrew Ross
rockclimb-guest at alioth.debian.org
Sun Jun 5 20:22:51 UTC 2011
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Packaging for libjna-java a library for dynamic access of native libraries from Java without JNI".
The branch, master has been updated
via 8e9e9647e74fa657bea2773626e197a0bd1b8956 (commit)
via 96c0693628bfb6cfbf95f4b2a93eefaf8db099fe (commit)
from 562bf53402a853a6c630c685bf2ebc40517826c5 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 8e9e9647e74fa657bea2773626e197a0bd1b8956
Author: Andrew Ross <ubuntu at rossfamily.co.uk>
Date: Sun Jun 5 21:21:35 2011 +0100
Support multiarch.
commit 96c0693628bfb6cfbf95f4b2a93eefaf8db099fe
Author: Andrew Ross <ubuntu at rossfamily.co.uk>
Date: Sun Jun 5 21:20:47 2011 +0100
Updated to 3.2.7-4
-----------------------------------------------------------------------
Summary of changes:
debian/changelog | 15 +++
debian/control | 4 +-
debian/patches/07-include-platform-jar.patch | 6 +-
debian/patches/08-multiarch-support.patch | 139 ++++++++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 2 +-
6 files changed, 161 insertions(+), 6 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 9de783f..cacfb58 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,18 @@
+libjna-java (3.2.7-4) unstable; urgency=low
+
+ * Remove optional build time dependency on openjdk-6-jdk (depend on
+ default-jdk) to fix Debcheck warning.
+ * Install jna-platform.jar with javahelper instead of mavenhelper
+ (Closes: #629081).
+
+ -- Andrew Ross <ubuntu at rossfamily.co.uk> Fri, 03 Jun 2011 18:13:57 +0100
+
+libjna-java (3.2.7-3) experimental; urgency=low
+
+ * Seach multiarch paths for libraries (Closes: #620122)
+
+ -- Andrew Ross <ubuntu at rossfamily.co.uk> Wed, 25 May 2011 21:19:02 +0100
+
libjna-java (3.2.7-2) unstable; urgency=low
* Build and install platform.jar too.
diff --git a/debian/control b/debian/control
index 5ed7d18..14d6eec 100644
--- a/debian/control
+++ b/debian/control
@@ -4,9 +4,9 @@ Priority: optional
Maintainer: Debian Java maintainers <pkg-java-maintainers at lists.alioth.debian.org>
Uploaders: Michael Koch <konqueror at gmx.de>, Jan Dittberner <jandd at debian.org>,
Ludovic Claude <ludovic.claude at laposte.net>, Andrew Ross <ubuntu at rossfamily.co.uk>
-Build-Depends: debhelper (>= 7.0.50~), default-jdk | openjdk-6-jdk, ant,
+Build-Depends: debhelper (>= 7.0.50~), default-jdk, ant,
ant-optional, libx11-dev, libxt-dev, libffi-dev, pkg-config,
- maven-repo-helper (>= 1.5~)
+ maven-repo-helper (>= 1.5~), javahelper (>=0.32~)
Standards-Version: 3.9.2
Homepage: http://jna.dev.java.net/
Vcs-Git: git://git.debian.org/pkg-java/libjna-java.git
diff --git a/debian/patches/07-include-platform-jar.patch b/debian/patches/07-include-platform-jar.patch
index 00ba008..fc0ea23 100644
--- a/debian/patches/07-include-platform-jar.patch
+++ b/debian/patches/07-include-platform-jar.patch
@@ -23,7 +23,7 @@ Index: libjna-java-3.2.7/pom.xml
Index: libjna-java-3.2.7/contrib/platform/build.xml
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ libjna-java-3.2.7/contrib/platform/build.xml 2011-05-22 21:07:10.743504899 +0100
++++ libjna-java-3.2.7/contrib/platform/build.xml 2011-06-03 18:23:26.431989502 +0100
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="platform" default="jar" basedir=".">
@@ -45,7 +45,7 @@ Index: libjna-java-3.2.7/contrib/platform/build.xml
+ </target>
+
+ <target name="jar" depends="compile" description="jar" >
-+ <jar jarfile="${dist}/platform.jar" basedir="${build}"/>
++ <jar jarfile="${dist}/jna-platform.jar" basedir="${build}"/>
+ </target>
+
+ <target name="javadoc">
@@ -55,7 +55,7 @@ Index: libjna-java-3.2.7/contrib/platform/build.xml
+
+ <target name="clean" description="clean" >
+ <delete dir="${build}"/>
-+ <delete file="${dist}/platform.jar"/>
++ <delete file="${dist}/jna-platform.jar"/>
+ </target>
+</project>
+
diff --git a/debian/patches/08-multiarch-support.patch b/debian/patches/08-multiarch-support.patch
new file mode 100644
index 0000000..29c6d23
--- /dev/null
+++ b/debian/patches/08-multiarch-support.patch
@@ -0,0 +1,139 @@
+Index: libjna-java-3.2.7/src/com/sun/jna/Platform.java
+===================================================================
+--- libjna-java-3.2.7.orig/src/com/sun/jna/Platform.java 2009-07-07 05:41:18.000000000 +0100
++++ libjna-java-3.2.7/src/com/sun/jna/Platform.java 2011-05-25 23:24:11.725855192 +0100
+@@ -99,4 +99,57 @@
+ }
+ return Native.POINTER_SIZE == 8;
+ }
++ public static final boolean isGNU() {
++ String name = System.getProperty("os.name").toLowerCase().trim();
++ return "gnu".equals(name);
++ }
++ public static final boolean iskFreeBSD() {
++ String name = System.getProperty("os.name").toLowerCase().trim();
++ return "gnu/kfreebsd".equals(name);
++ }
++ public static final String getBaseArch() {
++ String arch =
++ System.getProperty("os.arch").toLowerCase().trim();
++ if("amd64".equals(arch))
++ arch = "x86_64";
++ if("i686-at386".equals(arch))
++ arch = "i386";
++ if("ppc".equals(arch))
++ arch = "powerpc";
++ if("ppc64".equals(arch))
++ arch = "powerpc64";
++ return arch;
++ }
++ public static final boolean isIntel() {
++ String arch =
++ System.getProperty("os.arch").toLowerCase().trim();
++ if (arch.equals("i386") ||
++ arch.equals("x86_64") ||
++ arch.equals("amd64")) {
++ return true;
++ } else {
++ return false;
++ }
++ }
++
++ public static final boolean isPPC() {
++ String arch =
++ System.getProperty("os.arch").toLowerCase().trim();
++ if (arch.equals("ppc") ||
++ arch.equals("ppc64")) {
++ return true;
++ } else {
++ return false;
++ }
++ }
++
++ public static final boolean isARM() {
++ String arch =
++ System.getProperty("os.arch").toLowerCase().trim();
++ if (arch.equals("arm")) {
++ return true;
++ } else {
++ return false;
++ }
++ }
+ }
+Index: libjna-java-3.2.7/src/com/sun/jna/NativeLibrary.java
+===================================================================
+--- libjna-java-3.2.7.orig/src/com/sun/jna/NativeLibrary.java 2010-07-19 08:57:18.000000000 +0100
++++ libjna-java-3.2.7/src/com/sun/jna/NativeLibrary.java 2011-05-25 23:27:45.045855352 +0100
+@@ -618,7 +618,7 @@
+ // 64bit machines, so we have to explicitly search the 64bit one when
+ // running a 64bit JVM.
+ //
+- if (Platform.isLinux() || Platform.isSolaris() || Platform.isFreeBSD()) {
++ if (Platform.isLinux() || Platform.isSolaris() || Platform.isFreeBSD() || Platform.iskFreeBSD()) {
+ // Linux & FreeBSD use /usr/lib32, solaris uses /usr/lib/32
+ archPath = (Platform.isSolaris() ? "/" : "") + Pointer.SIZE * 8;
+ }
+@@ -628,11 +628,48 @@
+ "/usr/lib",
+ "/lib",
+ };
+- // Linux 64-bit does not use /lib or /usr/lib
+- if (Platform.isLinux() && Pointer.SIZE == 8) {
++ // Fix for multi-arch support on Ubuntu (and other
++ // multi-arch distributions)
++ // paths is scanned against real directory
++ // so for platforms which are not multi-arch
++ // this should continue to work.
++ if (Platform.isLinux() || Platform.iskFreeBSD()) {
++ // Defaults - overridden below
++ String cpu = Platform.getBaseArch();
++ String kernel = "linux";
++ String libc = "gnu";
++
++ if (Platform.isARM()) {
++ libc = "gnueabi";
++ }
++
++ String multiArchPath =
++ cpu + "-" + kernel + "-" + libc;
++
++ // Assemble path with all possible options
++ paths = new String[] {
++ "/usr/lib/" + multiArchPath,
++ "/lib/" + multiArchPath,
++ "/usr/lib" + archPath,
++ "/lib" + archPath,
++ "/usr/lib",
++ "/lib",
++ };
++ }
++ if (Platform.isGNU()) {
++ String cpu = Platform.getBaseArch();
++ String libc = "gnu";
++ String multiArchPath =
++ cpu + "-" + libc;
++
++ // Assemble path with all possible options
+ paths = new String[] {
++ "/usr/lib/" + multiArchPath,
++ "/lib/" + multiArchPath,
+ "/usr/lib" + archPath,
+ "/lib" + archPath,
++ "/usr/lib",
++ "/lib",
+ };
+ }
+ for (int i=0;i < paths.length;i++) {
+Index: libjna-java-3.2.7/build.xml
+===================================================================
+--- libjna-java-3.2.7.orig/build.xml 2011-05-25 21:26:05.084188334 +0100
++++ libjna-java-3.2.7/build.xml 2011-05-25 21:28:42.574188163 +0100
+@@ -72,6 +72,8 @@
+ <echo>${java.vm.name} (${java.vm.vendor}, ${java.vm.version})</echo>
+ <echo>java.home=${java.home}</echo>
+ <echo>java.library.path=${java.library.path}</echo>
++ <echo>os.name=${os.name}</echo>
++ <echo>os.arch=${os.arch}</echo>
+
+ <replaceregexp match="(<version>).*(</version>)"
+ replace="\1${jna.version}\2"
diff --git a/debian/patches/series b/debian/patches/series
index 59772d0..7d354a1 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -5,3 +5,4 @@
05-support-gnu-kfreebsd.patch
06-remove-gjdoc-inexistent-options.patch
07-include-platform-jar.patch
+08-multiarch-support.patch
diff --git a/debian/rules b/debian/rules
index 653f715..91e4e4b 100755
--- a/debian/rules
+++ b/debian/rules
@@ -21,7 +21,7 @@ override_dh_auto_build:
# install. using platform.jar is a silly idea in /usr/share/java/ as it's bound to collide
override_dh_auto_install:
mh_installjar -plibjna-java -l --usj-name=jna pom.xml build/jna.jar
- mh_installjar -plibjna-java -l --usj-name=jna-platform pom.xml build/platform.jar
+ jh_installlibs -plibjna-java build/jna-platform.jar
override_dh_makeshlibs:
# don't call dh_makeshlibs
hooks/post-receive
--
Packaging for libjna-java a library for dynamic access of native libraries from Java without JNI
More information about the pkg-java-commits
mailing list