Source: zlib Version: 1:1.2.11.dfsg-2 Tags: ftbfs patch User: helm...@debian.org Usertags: rebootstrap X-Debbugs-Cc: Alexey Brodkin <abrod...@synopsys.com>
debian/rules uses findstring to configure its multilib layout. When it encounters DEB_HOST_ARCH=arc, that happens to be a substring of "sparc" and thus it attempts to build multilib, but that doesn't work. Please fix the architecture match to properly tell arc and sparc apart. I'm attaching a patch for your convenience. Helmut
diff --minimal -Nru zlib-1.2.11.dfsg/debian/changelog zlib-1.2.11.dfsg/debian/changelog --- zlib-1.2.11.dfsg/debian/changelog 2020-02-24 22:07:12.000000000 +0100 +++ zlib-1.2.11.dfsg/debian/changelog 2022-03-05 06:48:19.000000000 +0100 @@ -1,3 +1,10 @@ +zlib (1:1.2.11.dfsg-2.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix FTBFS on arc: Fix overmatching of sparc (closes: #-1). + + -- Helmut Grohne <hel...@subdivi.de> Sat, 05 Mar 2022 06:48:19 +0100 + zlib (1:1.2.11.dfsg-2) unstable; urgency=low * Acknowledge previous NMUs (closes: #949388). diff --minimal -Nru zlib-1.2.11.dfsg/debian/rules zlib-1.2.11.dfsg/debian/rules --- zlib-1.2.11.dfsg/debian/rules 2020-02-24 22:07:12.000000000 +0100 +++ zlib-1.2.11.dfsg/debian/rules 2022-03-05 06:48:18.000000000 +0100 @@ -39,24 +39,24 @@ 32-ARCHS=amd64 ppc64 kfreebsd-amd64 s390x 64-ARCHS=s390 sparc i386 powerpc mips mipsel mipsn32 mipsn32el mipsr6 mipsr6el mipsn32r6 mipsn32r6el x32 -ifneq (,$(findstring $(DEB_HOST_ARCH), $(32-ARCHS))) +ifneq (,$(filter $(DEB_HOST_ARCH), $(32-ARCHS))) EXTRA_INSTALL=install32 EXTRA_BUILD=build32-stamp # s390x fails at compatibility. -ifneq (,$(findstring $(DEB_HOST_ARCH), s390x)) +ifneq (,$(filter $(DEB_HOST_ARCH), s390x)) m32=-m31 else m32=-m32 endif endif -ifneq (,$(findstring s390x, $(DEB_HOST_ARCH))) +ifneq (,$(filter s390x, $(DEB_HOST_ARCH))) else -ifneq (,$(findstring $(DEB_HOST_ARCH), $(64-ARCHS))) +ifneq (,$(filter $(DEB_HOST_ARCH), $(64-ARCHS))) EXTRA_INSTALL=install64 EXTRA_BUILD=build64-stamp # MIPS doesn't use -m64 -ifneq (,$(findstring $(DEB_HOST_ARCH), mips mipsel mipsn32 mipsn32el mipsr6 mipsr6el mipsn32r6 mipsn32r6el)) +ifneq (,$(filter $(DEB_HOST_ARCH), mips mipsel mipsn32 mipsn32el mipsr6 mipsr6el mipsn32r6 mipsn32r6el)) m64=-mabi=64 else m64=-m64 @@ -65,7 +65,7 @@ endif N32-ARCHS=mips mipsel -ifneq (,$(findstring $(DEB_HOST_ARCH), $(N32-ARCHS))) +ifneq (,$(filter $(DEB_HOST_ARCH), $(N32-ARCHS))) EXTRA_INSTALL+=installn32 EXTRA_BUILD+=buildn32-stamp mn32=-mabi=n32 @@ -74,7 +74,7 @@ endif # !nobiarch UNALIGNED_ARCHS=i386 amd64 kfreebsd-i386 kfreebsd-amd64 hurd-i386 lpia -ifneq (,$(findstring $(DEB_HOST_ARCH), $(UNALIGNED_ARCHS))) +ifneq (,$(filter $(DEB_HOST_ARCH), $(UNALIGNED_ARCHS))) CFLAGS+=-DUNALIGNED_OK endif @@ -199,13 +199,13 @@ dh_fixperms -a dh_makeshlibs -pzlib1g -V"zlib1g (>= 1:1.2.3.3.dfsg-1)" --add-udeb=zlib1g-udeb ifeq (,$(filter nobiarch,$(DEB_BUILD_PROFILES))) -ifneq (,$(findstring $(DEB_HOST_ARCH), $(32-ARCHS))) +ifneq (,$(filter $(DEB_HOST_ARCH), $(32-ARCHS))) dh_makeshlibs -plib32z1 -V"lib32z1 (>= 1:1.2.3.3.dfsg-1)" endif -ifneq (,$(findstring $(DEB_HOST_ARCH), $(64-ARCHS))) +ifneq (,$(filter $(DEB_HOST_ARCH), $(64-ARCHS))) dh_makeshlibs -plib64z1 -V"lib64z1 (>= 1:1.2.3.3.dfsg-1)" endif -ifneq (,$(findstring $(DEB_HOST_ARCH), $(N32-ARCHS))) +ifneq (,$(filter $(DEB_HOST_ARCH), $(N32-ARCHS))) dh_makeshlibs -plibn32z1 -V"libn32z1 (>= 1:1.2.3.3.dfsg-1)" endif endif