[snappy-java] 16/51: Replace calls to OSInfo.class by calls to dpkg-architecture.

Emmanuel Bourg ebourg-guest at moszumanska.debian.org
Tue Nov 25 17:16:43 GMT 2014


This is an automated email from the git hooks/post-receive script.

ebourg-guest pushed a commit to branch master
in repository snappy-java.

commit a10fa4dbfe4c16d340e98d78ef8c020a1adb79f8
Author: Charles Plessy <plessy at debian.org>
Date:   Sat Nov 5 21:54:14 2011 +0900

    Replace calls to OSInfo.class by calls to dpkg-architecture.
---
 .../replace_OSInfo_by_dpkg-architecture.patch      | 38 ++++++++++++++++++++++
 debian/patches/series                              |  1 +
 2 files changed, 39 insertions(+)

diff --git a/debian/patches/replace_OSInfo_by_dpkg-architecture.patch b/debian/patches/replace_OSInfo_by_dpkg-architecture.patch
new file mode 100644
index 0000000..285ed6a
--- /dev/null
+++ b/debian/patches/replace_OSInfo_by_dpkg-architecture.patch
@@ -0,0 +1,38 @@
+Description: replace calls to OSInfo.class by calls to dpkg-architecture.
+ The ‘lib’ directory is removed from this package, see ‘debian/README.source’.
+Author: Charles Plessy <plessy at debian.org>
+Forwarded: not-needed
+diff --git a/Makefile.common b/Makefile.common
+index f4a3fdd..991c5e0 100644
+--- a/Makefile.common
++++ b/Makefile.common
+@@ -11,17 +11,9 @@ JAVA  := "$$JAVA_HOME/bin/java"
+ JAVAC := "$$JAVA_HOME/bin/javac" 
+ JAVAH := "$$JAVA_HOME/bin/javah"
+ 
+-OSINFO_CLASS := org.xerial.snappy.OSInfo
+-OSINFO_PROG := lib/org/xerial/snappy/OSInfo.class
+-
+-## building OSInfo.java 
+-#$(info compiling OSInfo.java)
+-#$(shell mkdir -p lib)
+-#$(shell $(JAVAC) src/main/java/org/sqlite/OSInfo.java -d lib)
+-
+-OS_NAME := $(shell $(JAVA) -cp lib $(OSINFO_CLASS) --os)
+-OS_ARCH := $(shell $(JAVA) -cp lib $(OSINFO_CLASS) --arch)
+-LIB_FOLDER := $(shell $(JAVA) -cp lib $(OSINFO_CLASS))
++OS_NAME := $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS)
++OS_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH)
++LIB_FOLDER := $(OS_NAME)/$(OS_ARCH)
+ 
+ # Windows uses different path separators
+ ifeq ($(OS_NAME),Windows)
+@@ -41,7 +33,7 @@ endif
+ 
+ # os=Default is meant to be generic unix/linux
+ 
+-known_os_archs := Linux-i386 Linux-amd64 Mac-i386 Mac-x86_64 Windows-x86 Windows-amd64
++known_os_archs := linux-i386 linux-amd64 Mac-i386 Mac-x86_64 Windows-x86 Windows-amd64
+ os_arch := $(OS_NAME)-$(OS_ARCH)
+ 
+ ifeq (,$(findstring $(strip $(os_arch)),$(known_os_archs)))
diff --git a/debian/patches/series b/debian/patches/series
index d60bab3..2049ee8 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
 replace_silk-weaver_by_xml_grep.patch
+replace_OSInfo_by_dpkg-architecture.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/snappy-java.git



More information about the pkg-java-commits mailing list