Source: grep
Version: 3.7-1
Tags: ftbfs patch
User: helm...@debian.org
Usertags: rebootstrap

grep fails to build from source on musl-linux-any, because it assumes a
regex library, but musl doesn't provide it. Indeed, grep has its own
regex library and the packaging unconditionally disables that during
build. We should enable it for musl. Please consider applying the
attached patch.

Helmut
--- a/debian/rules
+++ b/debian/rules
@@ -26,10 +26,12 @@
 DEB_CONFIGURE_SCRIPT_ENV += CPPFLAGS="$(CPPFLAGS)"
 ##########################################################################

+include /usr/share/dpkg/architecture.mk
+
 DEB_UPSTREAM_URL = http://ftp.gnu.org/gnu/grep/
 DEB_UPSTREAM_TARBALL_EXTENSION = tar.xz

-DEB_CONFIGURE_EXTRA_FLAGS += --without-included-regex
+DEB_CONFIGURE_EXTRA_FLAGS += --with$(if $(filter $(DEB_HOST_ARCH_LIBC),musl),,out)-included-regex
 DEB_CONFIGURE_SCRIPT_ENV += LIBS="$(LIBS)"

 # FIXME: CDBS should include a specific var for this

Reply via email to