From becb01ce84d6da8ec549f042055ac58648eebd44 Mon Sep 17 00:00:00 2001 From: Theodore Ts'o Date: Sat, 28 Dec 2013 17:21:17 -0500 Subject: [PATCH] debian: fix cross build support We need to explicitly specify the $DEB_BUILD_HOST when querying for the version of the libblkid1 package. Addresses-Debian-Bug: #721365 Signed-off-by: "Theodore Ts'o" --- debian/rules | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/debian/rules b/debian/rules index de7d614f..245cf508 100755 --- a/debian/rules +++ b/debian/rules @@ -12,13 +12,6 @@ # be paranoid export LC_ALL ?= C -# Allow distro-specific behaviour -DISTRO :=$(shell sed -ne '/DISTRIB_ID/s/.*=//p' /etc/lsb-release 2>/dev/null || echo Debian) -SYS_BLKID_VER := $(shell dpkg-query -W libblkid1 | cut -f 2 | cut -b 1) -ifeq ($(SYS_BLKID_VER),2) -UTIL_LINUX_NG ?= yes -endif - # These are used for cross-compiling and for saving the configure script # from having to guess our platform (since we know it already) DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH) @@ -28,6 +21,13 @@ DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH 2>/dev/null) +# Allow distro-specific behaviour +DISTRO :=$(shell sed -ne '/DISTRIB_ID/s/.*=//p' /etc/lsb-release 2>/dev/null || echo Debian) +SYS_BLKID_VER := $(shell dpkg-query -W libblkid1:$(DEB_HOST_ARCH) | cut -f 2 | cut -b 1) +ifeq ($(SYS_BLKID_VER),2) +UTIL_LINUX_NG ?= yes +endif + # find the version for the main package, from changelog file MAIN_VERSION = $(shell head -n 1 debian/changelog | cut '-d ' -f 2 | sed 's/[()]//g') # find versions for libraries going into their own packages, from their Makefile.in's,