Bug#745380: src:eglibc: support non-multilib builds
On Mon, Apr 21, 2014 at 07:58:51AM +0200, Helmut Grohne wrote: > Please consider the attached patch to achieve this goal. Please find an updated patch attached. Changes since last version: * Add Build-Profiles headers to binary packages. * Don't treat optimized packages (e.g. i686) as multilib (thanks to Aurelien Jarno). * Introduce GLIBC_MULTILIB_PASSES to work the same way as DEB_ARCH_MULTILIB_PACKAGES (thanks to Aurelien Jarno). * Support new architectures (mips*). Helmut diff -Nru glibc-2.19/debian/changelog glibc-2.19/debian/changelog --- glibc-2.19/debian/changelog 2014-07-13 01:31:22.0 +0200 +++ glibc-2.19/debian/changelog 2014-07-19 07:38:01.0 +0200 @@ -1,3 +1,11 @@ +glibc (2.19-7.1) UNRELEASED; urgency=low + + * Non-maintainer upload. + * Add a "nobiarch" build profile that inhibits all multilib packages from +being built. (Closes: #745380) + + -- Helmut Grohne Sat, 19 Jul 2014 07:37:22 +0200 + glibc (2.19-7) unstable; urgency=high * debian/patches/localedata/unsubmitted-tst-setlocale3-ENV.diff: Apply diff -Nru glibc-2.19/debian/control.in/amd64 glibc-2.19/debian/control.in/amd64 --- glibc-2.19/debian/control.in/amd64 2014-06-27 04:28:51.0 +0200 +++ glibc-2.19/debian/control.in/amd64 2014-07-19 07:53:34.0 +0200 @@ -4,7 +4,7 @@ Priority: optional Depends: libc6 (= ${binary:Version}), ${misc:Depends} Conflicts: amd64-libs (<= 1.2) -Build-Profiles: !stage1 +Build-Profiles: !stage1 !nobiarch Description: GNU C Library: 64bit Shared libraries for AMD64 This package includes shared versions of the standard C library and the standard math library, as well as many others. This is the 64bit version @@ -19,6 +19,7 @@ Conflicts: libc6-dev (<< 2.13-14) Replaces: amd64-libs-dev (<= 1.2), libc6-dev (<< 2.13-11) Provides: lib64c-dev +Build-Profiles: !nobiarch Description: GNU C Library: 64bit Development Libraries for AMD64 Contains the symlinks and object files needed to compile and link programs which use the standard C library. This is the 64bit version of the diff -Nru glibc-2.19/debian/control.in/armel glibc-2.19/debian/control.in/armel --- glibc-2.19/debian/control.in/armel 2014-06-27 04:28:51.0 +0200 +++ glibc-2.19/debian/control.in/armel 2014-07-19 07:53:48.0 +0200 @@ -3,7 +3,7 @@ Section: libs Priority: optional Depends: libc6 (= ${binary:Version}), ${misc:Depends} -Build-Profiles: !stage1 +Build-Profiles: !stage1 !nobiarch Description: GNU C Library: ARM softfp shared libraries for armhf This package includes shared versions of the standard C library and the standard math library, as well as many others. @@ -15,6 +15,7 @@ Priority: optional Depends: libc6-armel (= ${binary:Version}), libc6-dev (= ${binary:Version}), ${misc:Depends} Recommends: gcc-multilib +Build-Profiles: !nobiarch Description: GNU C Library: ARM softfp development libraries for armhf Contains the symlinks and object files needed to compile and link programs which use the standard C library. This is the ARM softfp version of the diff -Nru glibc-2.19/debian/control.in/armhf glibc-2.19/debian/control.in/armhf --- glibc-2.19/debian/control.in/armhf 2014-06-27 04:28:51.0 +0200 +++ glibc-2.19/debian/control.in/armhf 2014-07-19 07:54:00.0 +0200 @@ -3,7 +3,7 @@ Section: libs Priority: optional Depends: libc6 (= ${binary:Version}), ${misc:Depends} -Build-Profiles: !stage1 +Build-Profiles: !stage1 !nobiarch Description: GNU C Library: ARM hard float shared libraries for armel This package includes shared versions of the standard C library and the standard math library, as well as many others. @@ -15,6 +15,7 @@ Priority: optional Depends: libc6-armhf (= ${binary:Version}), libc6-dev (= ${binary:Version}), ${misc:Depends} Recommends: gcc-multilib +Build-Profiles: !nobiarch Description: GNU C Library: ARM hard float development libraries for armel Contains the symlinks and object files needed to compile and link programs which use the standard C library. This is the ARM hard float version of the diff -Nru glibc-2.19/debian/control.in/i386 glibc-2.19/debian/control.in/i386 --- glibc-2.19/debian/control.in/i386 2014-06-27 04:28:51.0 +0200 +++ glibc-2.19/debian/control.in/i386 2014-07-19 07:54:14.0 +0200 @@ -5,7 +5,7 @@ Depends: libc6 (= ${binary:Version}), ${misc:Depends} Replaces: libc6-dev-i386 Breaks: fakeroot (<< 1.12.3), gnu-efi (<< 3.0e-3), fakechroot (<< 2.9-1.1), fglrx-glx-ia32 (<< 1:9-6-1), ia32-libs (<< 20090804), ia32-libs-gtk (<< 20090804), lib32asound2 (<< 1.0.20-3), lib32asound2-dev (<< 1.0.20-3), lib32bz2-1.0 (<< 1.0.5-3), lib32bz2-dev (<< 1.0.5-3), lib32ffi-dev (<< 3.0.9~rc9-1), lib32ffi5 (<< 3.0.9~rc9-1), lib32g2c0 (<< 1:3.4.6-10), lib32gcc1 (<< 1:4.4.0-7), lib32gfortran3 (<< 4.4.0-7), lib32gmp3 (<< 2:4.3.1+dfsg-3), lib32gmp3-dev (<< 2:4.3.1+dfsg-3), lib32gmpxx4 (<< 2:4.3.1+dfsg-3), lib32gomp1 (<< 4.4.0-7), lib32icu-dev (<< 4.0.1-3), lib32icu40 (<< 4.0.1-3),
Bug#745380: src:eglibc: support non-multilib builds
Package: src:eglibc Version: 2.18-4 Severity: wishlist Tags: patch User: helm...@debian.org Usertags: rebootstrap It would be awesome, if eglibc had a variant to drop all the multilib packages. In particular this helps for cross-building into an architecture where a sibling architectures is momentarily broken. The gcc-X.Y source packages have this feature for quite a while now and it goes by the name DEB_CROSS_NO_BIARCH=yes. When I talked to Adam Conrad, he indicated that he'd prefer using build profiles instead. So I am suggesting to use "nobiarch" as the name for that profile, because it is close to gcc's way of calling things. Please consider the attached patch to achieve this goal. Helmut diff -Nru eglibc-2.18/debian/changelog eglibc-2.18/debian/changelog --- eglibc-2.18/debian/changelog +++ eglibc-2.18/debian/changelog @@ -1,3 +1,11 @@ +eglibc (2.18-4.1) UNRELEASED; urgency=low + + * Non-maintainer upload. + * Add a "nobiarch" stage that inhibits all multilib packages from being +built. (Closes: #-1) + + -- Helmut Grohne Mon, 21 Apr 2014 07:44:15 +0200 + eglibc (2.18-4) unstable; urgency=high [ Aurelien Jarno ] diff -Nru eglibc-2.18/debian/rules eglibc-2.18/debian/rules --- eglibc-2.18/debian/rules +++ eglibc-2.18/debian/rules @@ -173,6 +173,10 @@ -include debian/sysdeps/$(DEB_HOST_ARCH_OS).mk -include debian/sysdeps/$(DEB_HOST_ARCH).mk +ifeq ($(filter nobiarch,$(DEB_BUILD_PROFILES)),) +DEB_ARCH_REGULAR_PACKAGES += $(DEB_ARCH_MULTILIB_PACKAGES) +endif + # Don't run dh_strip on this package NOSTRIP_$(libc)-dbg = 1 @@ -196,6 +200,10 @@ endif endif +ifneq ($(filter nobiarch,$(DEB_BUILD_PROFILES)),) +override EGLIBC_PASSES = libc +endif + # And now the rules... include debian/rules.d/*.mk diff -Nru eglibc-2.18/debian/sysdeps/alpha.mk eglibc-2.18/debian/sysdeps/alpha.mk --- eglibc-2.18/debian/sysdeps/alpha.mk +++ eglibc-2.18/debian/sysdeps/alpha.mk @@ -4,7 +4,7 @@ # build an ev67 optimized library EGLIBC_PASSES += alphaev67 -DEB_ARCH_REGULAR_PACKAGES += libc6.1-alphaev67 +DEB_ARCH_MULTILIB_PACKAGES += libc6.1-alphaev67 alphaev67_add-ons = ports nptl $(add-ons) alphaev67_configure_target = alphaev67-linux-gnu alphaev67_extra_cflags = -mcpu=ev67 -mtune=ev67 -O2 diff -Nru eglibc-2.18/debian/sysdeps/amd64.mk eglibc-2.18/debian/sysdeps/amd64.mk --- eglibc-2.18/debian/sysdeps/amd64.mk +++ eglibc-2.18/debian/sysdeps/amd64.mk @@ -3,7 +3,7 @@ # build 32-bit (i386) alternative library EGLIBC_PASSES += i386 -DEB_ARCH_REGULAR_PACKAGES += libc6-i386 libc6-dev-i386 +DEB_ARCH_MULTILIB_PACKAGES += libc6-i386 libc6-dev-i386 libc6-i386_shlib_dep = libc6-i386 (>= $(shlib_dep_ver)) i386_add-ons = nptl $(add-ons) i386_configure_target = i686-linux-gnu @@ -39,7 +39,7 @@ # build x32 ABI alternative library EGLIBC_PASSES += x32 -DEB_ARCH_REGULAR_PACKAGES += libc6-x32 libc6-dev-x32 +DEB_ARCH_MULTILIB_PACKAGES += libc6-x32 libc6-dev-x32 libc6-x32_shlib_dep = libc6-x32 (>= $(shlib_dep_ver)) x32_add-ons = nptl $(add-ons) x32_configure_target = x86_64-linux-gnux32 diff -Nru eglibc-2.18/debian/sysdeps/armel.mk eglibc-2.18/debian/sysdeps/armel.mk --- eglibc-2.18/debian/sysdeps/armel.mk +++ eglibc-2.18/debian/sysdeps/armel.mk @@ -2,7 +2,7 @@ extra_config_options = --enable-multi-arch #EGLIBC_PASSES += armhf -#DEB_ARCH_REGULAR_PACKAGES += libc6-armhf libc6-dev-armhf +#DEB_ARCH_MULTILIB_PACKAGES += libc6-armhf libc6-dev-armhf #armhf_add-ons = ports nptl $(add-ons) #armhf_configure_target = arm-linux-gnueabihf #armhf_CC = $(CC) -march=armv7-a -mfpu=vfpv3-d16 -mfloat-abi=hard diff -Nru eglibc-2.18/debian/sysdeps/armhf.mk eglibc-2.18/debian/sysdeps/armhf.mk --- eglibc-2.18/debian/sysdeps/armhf.mk +++ eglibc-2.18/debian/sysdeps/armhf.mk @@ -13,7 +13,7 @@ endef #EGLIBC_PASSES += armel -#DEB_ARCH_REGULAR_PACKAGES += libc6-armel libc6-dev-armel +#DEB_ARCH_MULTILIB_PACKAGES += libc6-armel libc6-dev-armel #armel_add-ons = ports nptl $(add-ons) #armel_configure_target = arm-linux-gnueabi #armel_CC = $(CC) -mfloat-abi=soft diff -Nru eglibc-2.18/debian/sysdeps/hurd-i386.mk eglibc-2.18/debian/sysdeps/hurd-i386.mk --- eglibc-2.18/debian/sysdeps/hurd-i386.mk +++ eglibc-2.18/debian/sysdeps/hurd-i386.mk @@ -1,7 +1,7 @@ # We use -march=i686 and glibc's i686 routines use cmov, so require it. # A Debian-local glibc patch adds cmov to the search path. EGLIBC_PASSES += i686 -DEB_ARCH_REGULAR_PACKAGES += libc0.3-i686 +DEB_ARCH_MULTILIB_PACKAGES += libc0.3-i686 i686_add-ons = $(libc_add-ons) i686_configure_target=i686-gnu i686_extra_cflags = -march=i686 -mtune=generic diff -Nru eglibc-2.18/debian/sysdeps/i386.mk eglibc-2.18/debian/sysdeps/i386.mk --- eglibc-2.18/debian/sysdeps/i386.mk +++ eglibc-2.18/debian/sysdeps/i386.mk @@ -4,7 +4,7 @@ # A Debian-local glibc patch adds cmov to the search path. # The optimized libraries also use NPTL! EGLIBC_PASSES += i686 -DEB_ARCH_REGULAR_PACKAGES += libc6-i686 +DEB_ARCH_MULTILIB_PACKAGES += libc6-i686 i686_add-ons = nptl $(add-ons) i686_con