[SCM] libbluray/master: Set JAVA_HOME variable correctly to accomodate the multiarch changes

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Thu Sep 29 16:55:50 UTC 2011


The following commit has been merged in the master branch:
commit 0488b2d29c5a7d26412fce8f8580da3b2e6ac0d2
Author: Reinhard Tartler <siretart at tauware.de>
Date:   Thu Sep 29 18:22:02 2011 +0200

    Set JAVA_HOME variable correctly to accomodate the multiarch changes
    
    After openjdk-6_6b23~pre8-2, JAVA_HOME needs to be set differently on
    every architecture.
    
    Thanks: Mònica Ramírez Arceda <monica at probeta.net> for reporting
    Closes: #640337

diff --git a/debian/rules b/debian/rules
index 8bcd826..9429fa3 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,13 +1,24 @@
 #!/usr/bin/make -f
 
-export JAVA_HOME=/usr/lib/jvm/java-6-openjdk
-export DEB_BUILD_ARCH_OS ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS)
+DEB_BUILD_ARCH_OS ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH_OS)
+DEB_BUILD_ARCH := $(shell dpkg-architecture -qDEB_BUILD_ARCH)
+
+# openjdk-6_6b23~pre8-2 and later have multiarchified JAVA_HOME
+JAVA_HOME=/usr/lib/jvm/java-6-openjdk-$(DEB_BUILD_ARCH)
+ifeq (,$(wildcard $(JAVA_HOME)))
+JAVA_HOME=/usr/lib/jvm/java-6-openjdk
+ifeq (,$(wildcard $(JAVA_HOME)))
+     $(info "warning: No suitable jni.h was found. Package will most probably FTBFS!"))
+endif
+endif
+
+$(info Located java at $(JAVA_HOME))
 
 confflags := --enable-doxygen-doc
 
 # enable bdjava on linux hosts only
 ifneq (,$(findstring linux,$(DEB_BUILD_ARCH_OS)))
-confflags += --enable-bdjava
+confflags += --enable-bdjava --with-jdk=$(JAVA_HOME)
 endif
 
 # Set CFLAGS to DEB_CFLAGS

-- 
libbluray packaging



More information about the pkg-multimedia-commits mailing list