package/{glibc, localedef}: update to 2.35
PATCH 2/2 package/{glibc, localedef}: update to 2.35
https://sourceware.org/pipermail/libc-alpha/2022-February/136040.html
- allow to use optimization CFLAGS (not CPPFLAGS) which are nowadays supported by upstream (except nios2)
- enable support for or1k, which is now included upstream
- runtime tested with qemu-system for aarch64/arm/microblaze/mips/mips64/nios2/ or1k/powerpc/powerpc64/powerpc64le/riscv32/riscv64/s390x/sh4/sparc64/x86/x86_64
---
...v-linux-microblaze-pselect32.c-add-m.patch | 85 -------------------
.../glibc.hash | 2 +-
package/glibc/glibc.mk | 16 ++--
...ACK-only-build-and-install-localedef.patch | 0
...y-on-GCC-to-4.8-and-binutils-to-2.24.patch | 0
.../localedef.hash | 2 +-
package/localedef/localedef.mk | 2 +-
toolchain/toolchain-buildroot/Config.in | 3 +-
8 files changed, 15 insertions(+), 95 deletions(-)
delete mode 100644 package/glibc/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0001-sysdeps-unix-sysv-linux-microblaze-pselect32.c-add-m.patch
rename package/glibc/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/glibc.hash (70%)
rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/0001-HACK-only-build-and-install-localedef.patch (100%)
rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/0002-relax-dependency-on-GCC-to-4.8-and-binutils-to-2.24.patch (100%)
rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/localedef.hash (70%)package/glibc/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0001-sysdeps-unix-sysv-linux-microblaze-pselect32.c-add-m.patch deleted +0 -85
@@ -1,85 +0,0 @@ -From af06fe63f9babb6d0179ae5d7d9245daada6bf56 Mon Sep 17 00:00:00 2001 -From: Thomas Petazzoni <[email protected]> -Date: Sun, 26 Dec 2021 10:30:01 +0100 -Subject: [PATCH] sysdeps/unix/sysv/linux/microblaze/pselect32.c: add missing - implementation when !__ASSUME_TIME64_SYSCALLS - -In commit a92f4e6299fe0e3cb6f77e79de00817aece501ce ("linux: Add time64 -pselect support"), a Microblaze specific implementation of -__pselect32() was added to cover the case of kernels < 3.15 which lack -the pselect6 system call. - -This new file sysdeps/unix/sysv/linux/microblaze/pselect32.c takes -precedence over the default implementation -sysdeps/unix/sysv/linux/pselect32.c. - -However sysdeps/unix/sysv/linux/pselect32.c provides an implementation -of __pselect32() which is needed when __ASSUME_TIME64_SYSCALLS is not -defined. On Microblaze, which is a 32-bit architecture, -__ASSUME_TIME64_SYSCALLS is only true for kernels >= 5.1. - -Due to sysdeps/unix/sysv/linux/microblaze/pselect32.c taking -precedence over sysdeps/unix/sysv/linux/pselect32.c, it means that -when we are with a kernel >= 3.15 but < 5.1, we need a __pselect32() -implementation, but sysdeps/unix/sysv/linux/microblaze/pselect32.c -doesn't provide it, and sysdeps/unix/sysv/linux/pselect32.c which -would provide it is not compiled in. - -This causes the following build failure on Microblaze with for example -Linux kernel headers 4.9: - -/home/thomas/buildroot/buildroot/output/host/lib/gcc/microblazeel-buildroot-linux-gnu/10.3.0/../../../../microblazeel-buildroot-linux-gnu/bin/ld: /home/thomas/buildroot/buildroot/output/build/glibc-2.34-9-g9acab0bba6a5a57323b1f94bf95b21618a9e5aa4/build/libc_pic.os: in function `__pselect64': -(.text+0x120b44): undefined reference to `__pselect32' -collect2: error: ld returned 1 exit status - -To fix this, we take a crude approach: replicate in -sysdeps/unix/sysv/linux/microblaze/pselect32.c the -!__ASSUME_TIME64_SYSCALLS implementation that is already in -sysdeps/unix/sysv/linux/pselect32.c. - -Upstream: https://sourceware.org/pipermail/libc-alpha/2021-December/134635.html -Signed-off-by: Thomas Petazzoni <[email protected]> ---- - .../unix/sysv/linux/microblaze/pselect32.c | 22 +++++++++++++++++-- - 1 file changed, 20 insertions(+), 2 deletions(-) - -diff --git a/sysdeps/unix/sysv/linux/microblaze/pselect32.c b/sysdeps/unix/sysv/linux/microblaze/pselect32.c -index 70b7b52a48..6b6b3e8a2e 100644 ---- a/sysdeps/unix/sysv/linux/microblaze/pselect32.c -+++ b/sysdeps/unix/sysv/linux/microblaze/pselect32.c -@@ -22,7 +22,25 @@ - #include <sys/poll.h> - #include <sysdep-cancel.h> - --#ifndef __ASSUME_PSELECT -+#if !defined(__ASSUME_TIME64_SYSCALLS) -+int -+__pselect32 (int nfds, fd_set *readfds, fd_set *writefds, -+ fd_set *exceptfds, const struct __timespec64 *timeout, -+ const sigset_t *sigmask) -+{ -+ struct timespec ts32, *pts32 = NULL; -+ if (timeout != NULL) -+ { -+ ts32 = valid_timespec64_to_timespec (*timeout); -+ pts32 = &ts32; -+ } -+ -+ return SYSCALL_CANCEL (pselect6, nfds, readfds, writefds, exceptfds, -+ pts32, -+ ((__syscall_ulong_t[]){ (uintptr_t) sigmask, -+ __NSIG_BYTES })); -+} -+#elif !defined(__ASSUME_PSELECT) - int - __pselect32 (int nfds, fd_set *readfds, fd_set *writefds, - fd_set *exceptfds, const struct __timespec64 *timeout, -@@ -57,4 +75,4 @@ __pselect32 (int nfds, fd_set *readfds, fd_set *writefds, - - return ret; - } --#endif /* __ASSUME_PSELECT */ -+#endif --- -2.31.1 -
package/glibc/2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586/glibc.hash renamed from package/glibc/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/glibc.hash +1 -1
@@ -1,5 +1,5 @@ # Locally calculated (fetched from Github) -sha256 3c299a21468a80356b848ca341f45551616c4928a6c871e6d45cee942e8b0f24 glibc-2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c.tar.gz +sha256 0ca43b2a6cd74609519554303a16e350abdac0e66943c5d98d91228233c826a0 glibc-2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586.tar.gz # Hashes for license files sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 COPYING
package/glibc/glibc.mk +10 -6
@@ -7,7 +7,7 @@ # Generate version string using: # git describe --match 'glibc-*' --abbrev=40 origin/release/MAJOR.MINOR/master | cut -d '-' -f 2- # When updating the version, please also update localedef -GLIBC_VERSION = 2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c +GLIBC_VERSION = 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586 # Upstream doesn't officially provide an https download link. # There is one (https://sourceware.org/git/glibc.git) but it's not reliable, # sometimes the connection times out. So use an unofficial github mirror.
@@ -110,16 +110,20 @@ endif # # 2. We have to execute the configure script with bash and not sh. # -# Note that as mentionned in -# http://patches.openembedded.org/patch/38849/, glibc must be -# built with -O2, so we pass our own CFLAGS and CXXFLAGS below. +# Glibc nowadays can be build with optimization flags f.e. -Os + +# crash in qemu-system-nios2 with -Os +ifeq ($(BR2_nios2),y) +TARGET_FCFLAGS := -O2 +endif + define GLIBC_CONFIGURE_CMDS mkdir -p $(@D)/build # Do the configuration (cd $(@D)/build; \ $(TARGET_CONFIGURE_OPTS) \ - CFLAGS="-O2 $(GLIBC_EXTRA_CFLAGS)" CPPFLAGS="" \ - CXXFLAGS="-O2 $(GLIBC_EXTRA_CFLAGS)" \ + CFLAGS="$(TARGET_FCFLAGS) $(GLIBC_EXTRA_CFLAGS)" CPPFLAGS="" \ + CXXFLAGS="$(TARGET_FCFLAGS) $(GLIBC_EXTRA_CFLAGS)" \ $(GLIBC_CONF_ENV) \ $(SHELL) $(@D)/configure \ --target=$(GNU_TARGET_NAME) \
package/localedef/2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586/0001-HACK-only-build-and-install-localedef.patch renamed from package/localedef/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0001-HACK-only-build-and-install-localedef.patch +0 -0
package/localedef/2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586/0002-relax-dependency-on-GCC-to-4.8-and-binutils-to-2.24.patch renamed from package/localedef/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0002-relax-dependency-on-GCC-to-4.8-and-binutils-to-2.24.patch +0 -0
package/localedef/2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586/localedef.hash renamed from package/localedef/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/localedef.hash +1 -1
@@ -1,5 +1,5 @@ # Locally calculated (fetched from Github) -sha256 3c299a21468a80356b848ca341f45551616c4928a6c871e6d45cee942e8b0f24 glibc-2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c.tar.gz +sha256 0ca43b2a6cd74609519554303a16e350abdac0e66943c5d98d91228233c826a0 glibc-2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586.tar.gz # Hashes for license files sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 COPYING
package/localedef/localedef.mk +1 -1
@@ -7,7 +7,7 @@ # Use the same VERSION and SITE as target glibc # As in glibc.mk, generate version string using: # git describe --match 'glibc-*' --abbrev=40 origin/release/MAJOR.MINOR/master | cut -d '-' -f 2- -LOCALEDEF_VERSION = 2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c +LOCALEDEF_VERSION = 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586 LOCALEDEF_SOURCE = glibc-$(LOCALEDEF_VERSION).tar.gz LOCALEDEF_SITE = $(call github,bminor,glibc,$(LOCALEDEF_VERSION)) HOST_LOCALEDEF_DL_SUBDIR = glibc
toolchain/toolchain-buildroot/Config.in +2 -1
@@ -49,7 +49,8 @@ config BR2_TOOLCHAIN_BUILDROOT_GLIBC BR2_powerpc || BR2_powerpc64 || BR2_powerpc64le || \ BR2_riscv || BR2_s390x || BR2_sh || \ BR2_sparc64 || BR2_x86_64 || BR2_microblaze || \ - BR2_nios2 || (BR2_arc && BR2_ARC_ATOMIC_EXT) || BR2_csky + BR2_nios2 || (BR2_arc && BR2_ARC_ATOMIC_EXT) || \ + BR2_csky || BR2_or1k depends on BR2_USE_MMU depends on !BR2_STATIC_LIBS depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_2
Signature · 6 lines
2.30.2 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 19 lines · Waldemar Brodkorb
https://sourceware.org/pipermail/libc-alpha/2022-February/136040.html
- allow to use optimization CFLAGS (not CPPFLAGS) which are nowadays supported by upstream (except nios2)
- enable support for or1k, which is now included upstream
- runtime tested with qemu-system for aarch64/arm/microblaze/mips/mips64/nios2/ or1k/powerpc/powerpc64/powerpc64le/riscv32/riscv64/s390x/sh4/sparc64/x86/x86_64Signed-off-by Waldemar Brodkorb <[email protected]>--- ...v-linux-microblaze-pselect32.c-add-m.patch | 85 ------------------- .../glibc.hash | 2 +- package/glibc/glibc.mk | 16 ++-- ...ACK-only-build-and-install-localedef.patch | 0 ...y-on-GCC-to-4.8-and-binutils-to-2.24.patch | 0 .../localedef.hash | 2 +- package/localedef/localedef.mk | 2 +- toolchain/toolchain-buildroot/Config.in | 3 +- 8 files changed, 15 insertions(+), 95 deletions(-)
Quoted 5 lines
delete mode 100644
package/glibc/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0001-sysdeps-unix-sysv-linux-microblaze-pselect32.c-add-m.patch
rename package/glibc/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/glibc.hash (70%)
rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c =>2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/0001-HACK-only-build-and-install-localedef.patch(100%) rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c =>2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/0002-relax-dependency-on-GCC-to-4.8-and-binutils-to-2.24.patch(100%) rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/localedef.hash (70%)
with the removal of the csky fork in commit ebc6c7e, there's no longer a need
to version the patches, so perhaps you could take this opportunity to move them out of the directory.
[snip]
Quoted 15 lines
package/glibc/glibc.mk +1
-1@@ -7,7 +7,7 @@ # Generate version string using: # git describe --match 'glibc-*' --abbrev=40 origin/release/MAJOR.MINOR/master | cut -d '-' -f 2- # When updating the version, please also update localedef -GLIBC_VERSION = 2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c +GLIBC_VERSION = 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586 # Upstream doesn't officially provide an https download link. # There is one (https://sourceware.org/git/glibc.git) but it's not reliable, # sometimes the connection times out. So use an unofficial github mirror.@@ -110,16 +110,20 @@ endif #
package/glibc/glibc.mk endif · line 117
Quoted 10 lines
package/glibc/glibc.mk +5
-3# 2. We have to execute the configure script with bash and not sh. # -# Note that as mentionned in -# http://patches.openembedded.org/patch/38849/, glibc must be -# built with -O2, so we pass our own CFLAGS and CXXFLAGS below. +# Glibc nowadays can be build with optimization flags f.e. -Os + +# crash in qemu-system-nios2 with -Os +ifeq ($(BR2_nios2),y) +TARGET_FCFLAGS := -O2
You're overriding the global TARGET_FCFLAGS here, that's not allowed.
Instead, you should use
GLIBC_CFLAGS = $(TARGET_CFLAGS)
# crash in qemu-system-nios2 with -Os ifeq ($(BR2_nios2),y) GLIBC_CFLAGS += -O2 endif
(I'm not sure if += is OK here, if not, just use =)
And to make the below simpler, you can use
GLIBC_CFLAGS += $(GLIBC_EXTRA_CFLAGS)
Alternatively, if += is OK for nios, you can use
ifeq ($(BR2_nios2),y)GLIBC_EXTRA_CFLAGS += -O2
endif
...
CFLAGS="$(TARGET_CFLAGS) $(GLIBC_EXTRA_CFLAGS)" \
package/glibc/glibc.mk endif · line 125
Quoted 10 lines
package/glibc/glibc.mk +3
-2+endif + define GLIBC_CONFIGURE_CMDS mkdir -p $(@D)/build # Do the configuration (cd $(@D)/build; \ $(TARGET_CONFIGURE_OPTS) \ - CFLAGS="-O2 $(GLIBC_EXTRA_CFLAGS)" CPPFLAGS="" \ - CXXFLAGS="-O2 $(GLIBC_EXTRA_CFLAGS)" \ + CFLAGS="$(TARGET_FCFLAGS) $(GLIBC_EXTRA_CFLAGS)" CPPFLAGS="" \
FCFLAGS stands for Fortran Compilation flags. You should use TARGET_CFLAGS here.
Why is CPPFLAGS not set?
Marked as Changes Requested.
Regards,
Arnout
Quoted 44 lines
package/glibc/glibc.mk +1
-0+ CXXFLAGS="$(TARGET_FCFLAGS) $(GLIBC_EXTRA_CFLAGS)" \ $(GLIBC_CONF_ENV) \ $(SHELL) $(@D)/configure \ --target=$(GNU_TARGET_NAME) \package/localedef/2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586/0001-HACK-only-build-and-install-localedef.patch renamed from package/localedef/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0001-HACK-only-build-and-install-localedef.patch +0
-0package/localedef/2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586/0002-relax-dependency-on-GCC-to-4.8-and-binutils-to-2.24.patch renamed from package/localedef/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0002-relax-dependency-on-GCC-to-4.8-and-binutils-to-2.24.patch +0
-0package/localedef/2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586/localedef.hash renamed from package/localedef/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/localedef.hash +1
-1@@ -1,5 +1,5 @@ # Locally calculated (fetched from Github) -sha256 3c299a21468a80356b848ca341f45551616c4928a6c871e6d45cee942e8b0f24 glibc-2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c.tar.gz +sha256 0ca43b2a6cd74609519554303a16e350abdac0e66943c5d98d91228233c826a0 glibc-2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586.tar.gz # Hashes for license files sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 COPYINGpackage/localedef/localedef.mk +1
-1@@ -7,7 +7,7 @@ # Use the same VERSION and SITE as target glibc # As in glibc.mk, generate version string using: # git describe --match 'glibc-*' --abbrev=40 origin/release/MAJOR.MINOR/master | cut -d '-' -f 2- -LOCALEDEF_VERSION = 2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c +LOCALEDEF_VERSION = 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586 LOCALEDEF_SOURCE = glibc-$(LOCALEDEF_VERSION).tar.gz LOCALEDEF_SITE = $(call github,bminor,glibc,$(LOCALEDEF_VERSION)) HOST_LOCALEDEF_DL_SUBDIR = glibctoolchain/toolchain-buildroot/Config.in +0
-0
toolchain/toolchain-buildroot/Config.in config BR2_TOOLCHAIN_BUILDROOT_GLIBC · line 56
Quoted 9 lines
toolchain/toolchain-buildroot/Config.in +2
-1@@ -49,7 +49,8 @@ config BR2_TOOLCHAIN_BUILDROOT_GLIBC BR2_powerpc || BR2_powerpc64 || BR2_powerpc64le || \ BR2_riscv || BR2_s390x || BR2_sh || \ BR2_sparc64 || BR2_x86_64 || BR2_microblaze || \ - BR2_nios2 || (BR2_arc && BR2_ARC_ATOMIC_EXT) || BR2_csky + BR2_nios2 || (BR2_arc && BR2_ARC_ATOMIC_EXT) || \ + BR2_csky || BR2_or1k depends on BR2_USE_MMU depends on !BR2_STATIC_LIBS depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_2
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Hi Arnout,
Arnout Vandecappelle wrote,
Quoted 26 lines · Waldemar Brodkorb
Quoted 19 lines
https://sourceware.org/pipermail/libc-alpha/2022-February/136040.html
- allow to use optimization CFLAGS (not CPPFLAGS) which are nowadays supported by upstream (except nios2)
- enable support for or1k, which is now included upstream
- runtime tested with qemu-system for aarch64/arm/microblaze/mips/mips64/nios2/ or1k/powerpc/powerpc64/powerpc64le/riscv32/riscv64/s390x/sh4/sparc64/x86/x86_64Signed-off-by Waldemar Brodkorb <[email protected]>--- ...v-linux-microblaze-pselect32.c-add-m.patch | 85 ------------------- .../glibc.hash | 2 +- package/glibc/glibc.mk | 16 ++-- ...ACK-only-build-and-install-localedef.patch | 0 ...y-on-GCC-to-4.8-and-binutils-to-2.24.patch | 0 .../localedef.hash | 2 +- package/localedef/localedef.mk | 2 +- toolchain/toolchain-buildroot/Config.in | 3 +- 8 files changed, 15 insertions(+), 95 deletions(-)Quoted 5 lines
delete mode 100644
package/glibc/2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c/0001-sysdeps-unix-sysv-linux-microblaze-pselect32.c-add-m.patch
rename package/glibc/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/glibc.hash (70%)
rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c =>2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/0001-HACK-only-build-and-install-localedef.patch(100%) rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c =>2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/0002-relax-dependency-on-GCC-to-4.8-and-binutils-to-2.24.patch(100%) rename package/localedef/{2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c => 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586}/localedef.hash (70%)
Quoted 3 lines
with the removal of the csky fork in commit ebc6c7e, there's no longer a
need to version the patches, so perhaps you could take this opportunity to move them out of the directory.
Okay.
Quoted 65 lines
[snip]
Quoted 15 lines
package/glibc/glibc.mk +1
-1@@ -7,7 +7,7 @@ # Generate version string using: # git describe --match 'glibc-*' --abbrev=40 origin/release/MAJOR.MINOR/master | cut -d '-' -f 2- # When updating the version, please also update localedef -GLIBC_VERSION = 2.34-109-gd64b08d5ba7ffbc9155630f4843cf2e271b1629c +GLIBC_VERSION = 2.35-6-g491f2ef1f0ff849490f374917957018d07ee0586 # Upstream doesn't officially provide an https download link. # There is one (https://sourceware.org/git/glibc.git) but it's not reliable, # sometimes the connection times out. So use an unofficial github mirror.@@ -110,16 +110,20 @@ endif #package/glibc/glibc.mk endif · line 117
Quoted 10 lines
package/glibc/glibc.mk +5
-3# 2. We have to execute the configure script with bash and not sh. # -# Note that as mentionned in -# http://patches.openembedded.org/patch/38849/, glibc must be -# built with -O2, so we pass our own CFLAGS and CXXFLAGS below. +# Glibc nowadays can be build with optimization flags f.e. -Os + +# crash in qemu-system-nios2 with -Os +ifeq ($(BR2_nios2),y) +TARGET_FCFLAGS := -O2You're overriding the global
TARGET_FCFLAGShere, that's not allowed.Instead, you should use
GLIBC_CFLAGS= $(TARGET_CFLAGS)# crash in qemu-system-nios2 with -Os ifeq ($(BR2_nios2),y) GLIBC_CFLAGS += -O2 endif(I'm not sure if += is OK here, if not, just use =)
And to make the below simpler, you can use
GLIBC_CFLAGS+= $(GLIBC_EXTRA_CFLAGS)Alternatively, if += is OK for nios, you can use
ifeq ($(BR2_nios2),y)
GLIBC_EXTRA_CFLAGS+= -O2
endif
...CFLAGS="$(TARGET_CFLAGS) $(GLIBC_EXTRA_CFLAGS)" \package/glibc/glibc.mk endif · line 125
Quoted 10 lines
package/glibc/glibc.mk +3
-2+endif + define GLIBC_CONFIGURE_CMDS mkdir -p $(@D)/build # Do the configuration (cd $(@D)/build; \ $(TARGET_CONFIGURE_OPTS) \ - CFLAGS="-O2 $(GLIBC_EXTRA_CFLAGS)" CPPFLAGS="" \ - CXXFLAGS="-O2 $(GLIBC_EXTRA_CFLAGS)" \ + CFLAGS="$(TARGET_FCFLAGS) $(GLIBC_EXTRA_CFLAGS)" CPPFLAGS="" \FCFLAGS stands for Fortran Compilation flags. You should use
TARGET_CFLAGShere.
Quoted 1 line
Why is CPPFLAGS not set?
Glibc does not compile with the existing TARGET_CPPFLAGS which are added to TARGET_CFLAGS so I can not use TARGET_CFLAGS to optimize the build. I will use TARGET_OPTIMIZATION if that is okay.
best regards
Waldemar
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot