[Pkg-db-devel] Bug#405858: build a libdb4.5-java-gcj package

Matthias Klose doko at cs.tu-berlin.de
Sat Jan 6 20:49:28 CET 2007


Package: db4.5
Severity: wishlist
Tags: patch

diff -u db4.5-4.5.20/debian/changelog db4.5-4.5.20/debian/changelog
--- db4.5-4.5.20/debian/changelog
+++ db4.5-4.5.20/debian/changelog
@@ -1,3 +1,10 @@
+db4.5 (4.5.20-1ubuntu1) feisty; urgency=low
+
+  * Build libdb4.5-java-gcj.
+  * Honor nocheck in DEB_BUILD_OPTIONS.
+
+ -- Matthias Klose <doko at ubuntu.com>  Sat,  6 Jan 2007 19:23:12 +0100
+
 db4.5 (4.5.20-1) unstable; urgency=low
 
   * Package Berkeley DB 4.5 based on db4.4 packaging.
diff -u db4.5-4.5.20/debian/control db4.5-4.5.20/debian/control
--- db4.5-4.5.20/debian/control
+++ db4.5-4.5.20/debian/control
@@ -97,10 +97,22 @@
 Provides: libdb-java
 Conflicts: libdb-java
 Depends: ${shlibs:Depends}
+Recommends: libdb4.5-java-gcj
 Description: Berkeley v4.5 Database Libraries for Java
  This package provides the Java interface for the Berkeley v4.5 database
  library.
 
+Package: libdb4.5-java-gcj
+Architecture: any
+Section: libs
+Priority: optional
+Depends: libdb4.5-java (>= ${source:Version}), ${misc:Depends}, ${shlibs:Depends}
+Description: Berkeley v4.4 Database Libraries for Java (native code)
+ This package provides the Java interface for the Berkeley v4.5 database
+ library.
+ .
+ This package contains the natively compiled code for use by gij.
+
 Package: libdb4.5-java-dev
 Architecture: any
 Section: libs
diff -u db4.5-4.5.20/debian/rules db4.5-4.5.20/debian/rules
--- db4.5-4.5.20/debian/rules
+++ db4.5-4.5.20/debian/rules
@@ -16,6 +16,7 @@
 INSTALL_PROGRAM += -s
 endif
 
+DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
 DEB_BUILD_GNU_CPU ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_CPU)
 DEB_BUILD_GNU_SYSTEM ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_SYSTEM)
 DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
@@ -25,6 +26,7 @@
 
 JAVA_UNSUPPORTED_CPUS = zm32rz zm68kz zarmz zmipsz zmipselz
 JAVA_UNSUPPORTED_SYSTEMS = zgnuz zkfreebsd-gnuz zknetbsd-gnuz
+-include /usr/share/gcj/debian_defaults
 
 NPTL_SUPPORTED_CPUS = zamd64z
 NPTL_SUPPORTED_SYSTEMS = zlinux-gnuz
@@ -50,6 +52,9 @@
 CONFIGURE_VARS += JAVAC="$(JAVA_BIN)/javac" JAVA="$(JAVA_BIN)/java" JAR="$(JAVA_BIN)/jar"
 CONFIGURE_SWITCHES += --enable-java
 DB_BINARY_PKGS += libdb4.5-java libdb4.5-java-dev
+ifneq (,$(filter $(DEB_BUILD_ARCH), $(gcj_native_archs)))
+DB_BINARY_PKGS += libdb4.5-java-gcj
+endif
 endif
 endif
 
@@ -82,10 +87,12 @@
 	cd obj && $(MAKE)
 
 #ifneq (,$(findstring $(DEB_BUILD_GNU_CPU),ia64))
+ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
 	chmod +x ./debian/runtests.tclsh
 	cd obj && ../debian/runtests.tclsh || true
 
 	grep ^FAIL obj/ALL.OUT || true
+endif
 #endif
 
 	touch build
@@ -161,6 +168,9 @@
 		debian/lib$(package)-java/usr/share/java/lib$(package)-java-$(version).jar
 	ln -s lib$(package)-java-$(version).jar \
 		debian/lib$(package)-java/usr/share/java/lib$(package)-java.jar
+ifneq (,$(filter $(DEB_BUILD_ARCH), $(gcj_native_archs)))
+	dh_nativejava -plib$(package)-java-gcj
+endif
 endif
 endif
 	mv debian/lib$(package)-dev/usr/lib/*cxx* debian/lib$(package)++-dev/usr/lib




More information about the Pkg-db-devel mailing list