Source: libselinux
Version: 2.7-1
Tags: patch
User: helm...@debian.org
Usertags: rebootstrap

Hi,

Since 2.7-1, libselinux stage1 no longer cross builds. With 2.6-3
DEB_STAGE=stage1 did cross build. Somehow it is now using the build
architecture pkg-config and thus fails finding required packages (e.g.
pcre). After switching it to the host architecture pkg-config,
libselinux stage1 cross builds again. Please apply the attached patch.

I also suggest updating the override_dh_auto_build to call dh_auto_build
with extra arguments. When doing so, dh_auto_build automatically passes
CC and PKG_CONFIG to make for cross builds and can take care of parallel
builds.

Helmut
diff --minimal -Nru libselinux-2.7/debian/changelog 
libselinux-2.7/debian/changelog
--- libselinux-2.7/debian/changelog     2017-09-09 23:32:59.000000000 +0200
+++ libselinux-2.7/debian/changelog     2017-09-11 21:41:20.000000000 +0200
@@ -1,3 +1,10 @@
+libselinux (2.7-1.1) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Fix FTCBFS: Add the host architecture to pkg-config (Closes: #-1)
+
+ -- Helmut Grohne <hel...@subdivi.de>  Mon, 11 Sep 2017 21:41:20 +0200
+
 libselinux (2.7-1) unstable; urgency=medium
 
   * New upstream release
diff --minimal -Nru libselinux-2.7/debian/rules libselinux-2.7/debian/rules
--- libselinux-2.7/debian/rules 2017-09-09 23:32:59.000000000 +0200
+++ libselinux-2.7/debian/rules 2017-09-11 21:41:13.000000000 +0200
@@ -8,7 +8,8 @@
 DEB_HOST_GNU_CPU       := $(shell dpkg-architecture -qDEB_HOST_GNU_CPU)
 DEB_HOST_GNU_TYPE      := $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
 DEB_HOST_MULTIARCH     := $(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
-LIBDIR_LIBSEPOL                := $(shell pkg-config --variable=libdir 
libsepol)
+PKG_CONFIG              ?= $(DEB_HOST_GNU_TYPE)-pkg-config
+LIBDIR_LIBSEPOL                := $(shell $(PKG_CONFIG) --variable=libdir 
libsepol)
 
 PREFIX = /usr
 
@@ -52,6 +53,7 @@
 extra_make_args  = LIBSEPOLA=$(LIBDIR_LIBSEPOL)/libsepol.a
 extra_make_args += ARCH=$(DEB_HOST_GNU_CPU)
 extra_make_args += CC=$(DEB_HOST_GNU_TYPE)-gcc
+extra_make_args += PKG_CONFIG=$(PKG_CONFIG)
 override_dh_auto_build: FORCE
        +$(MAKE) PREFIX="$(PREFIX)" LIBBASE="lib/${DEB_HOST_MULTIARCH}" 
$(extra_make_args) all
 
_______________________________________________
SELinux-devel mailing list
SELinux-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/selinux-devel

Reply via email to