From 8e0165e329b95bc913ca86cd5616144584f7aef7 Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Thu, 29 Apr 2010 01:55:06 -0400 Subject: [PATCH] Update build flags for biarch packages. Notably, fix the path for lib32nss-nonlocal on squeeze. Signed-off-by: Anders Kaseorg --- debian/changelog | 2 ++ debian/rules | 22 +++++++++++++++++----- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/debian/changelog b/debian/changelog index c3060f0..8538dce 100644 --- a/debian/changelog +++ b/debian/changelog @@ -5,6 +5,8 @@ libnss-nonlocal (1.11-0debathena1) UNRELEASED; urgency=low - Update licensing to LGPLv2.1+. - Change syslog priority when removing local groups from non-local users + * Update build flags for biarch packages (fixes lib32nss-nonlocal path + on squeeze). -- Anders Kaseorg Thu, 29 Apr 2010 00:12:44 -0400 diff --git a/debian/rules b/debian/rules index 53bd2c1..c92070c 100755 --- a/debian/rules +++ b/debian/rules @@ -13,8 +13,11 @@ DEB_DESTDIR = $(CURDIR)/debian/tmp/ DEB_DH_INSTALL_SOURCEDIR = $(DEB_DESTDIR) DEB_CONFIGURE_PREFIX = / +IS_UBUNTU := $(if $(filter Ubuntu, $(shell lsb_release -is)), y) LIBC6_VERSION := $(shell dpkg-query --showformat='$${Version}' --show libc6) -ifeq ($(shell dpkg --compare-versions '$(LIBC6_VERSION)' '>=' '2.8+20080809' && echo y),y) +libc6_ge = $(shell dpkg --compare-versions '$(LIBC6_VERSION)' ge '$(1)' && echo y) + +ifeq ($(call libc6_ge, 2.8+20080809), y) DEB_DH_SHLIBDEPS_ARGS = -- -xglibc-private endif @@ -29,20 +32,29 @@ DEB_BUILDDIR = $(or $(DEB_BUILDDIR_$(cdbs_curpkg)),debian/build) REAL_DEB_HOST_GNU_TYPE := $(DEB_HOST_GNU_TYPE) DEB_BUILDDIR_lib32nss-nonlocal = debian/build_32 -configure/lib32nss-nonlocal:: CC += -m32 cleanbuilddir/lib32nss-nonlocal:: clean/lib32nss-nonlocal -ifeq ($(shell lsb_release -is), Ubuntu) +# i386_configure_target in eglibc/debian/sysdeps/amd64.mk +ifeq ($(or $(IS_UBUNTU), $(call libc6_ge, 2.8+20080809)), y) configure/lib32nss-nonlocal:: DEB_BUILD_GNU_TYPE = i686-linux -configure/lib32nss-nonlocal:: DEB_CONFIGURE_EXTRA_FLAGS += --libdir="\$${prefix}/lib32" else configure/lib32nss-nonlocal:: DEB_BUILD_GNU_TYPE = i486-linux +endif +# i386_CC in eglibc/debian/sysdeps/amd64.mk +configure/lib32nss-nonlocal:: CC += -m32 +# i386_slibdir in eglibc/debian/sysdeps/amd64.mk +ifeq ($(or $(IS_UBUNTU), $(call libc6_ge, 2.9-14~)), y) +configure/lib32nss-nonlocal:: DEB_CONFIGURE_EXTRA_FLAGS += --libdir="\$${prefix}/lib32" +else configure/lib32nss-nonlocal:: DEB_CONFIGURE_PREFIX = /emul/ia32-linux endif DEB_BUILDDIR_lib64nss-nonlocal = debian/build_64 +cleanbuilddir/lib64nss-nonlocal:: clean/lib64nss-nonlocal +# amd64_configure_target in eglibc/debian/sysdeps/i386.mk configure/lib64nss-nonlocal:: DEB_BUILD_GNU_TYPE = x86_64-linux +# amd64_CC in eglibc/debian/sysdeps/i386.mk configure/lib64nss-nonlocal:: CC += -m64 -D__x86_64__ -cleanbuilddir/lib64nss-nonlocal:: clean/lib64nss-nonlocal +# amd64_slibdir in eglibc/debian/sysdeps/i386.mk configure/lib64nss-nonlocal:: DEB_CONFIGURE_EXTRA_FLAGS += --libdir="\$${prefix}/lib64" configure/lib32nss-nonlocal configure/lib64nss-nonlocal:: -- 2.45.0