From 531cce6878d9367f6b707535970cbd276bdb25c7 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Mon, 28 Jul 2025 18:29:09 -0700 Subject: glibc: Upgrade to 2.42 release * GCC 12.1 or later is now required to build the GNU C Library. * GNU Binutils 2.39 or later is now required to build the GNU C Library. * Support for lightweight stack guard pages via madvise and the MADV_GUARD_INSTALL flag has been added to pthread_create. * This is major release, changelog [1] [1] https://sourceware.org/pipermail/libc-announce/2025/000048.html (From OE-Core rev: 7c55e2da96f40ee0e40f6fd534573ce64013145c) Signed-off-by: Khem Raj Signed-off-by: Richard Purdie --- meta/conf/distro/include/tcmode-default.inc | 2 +- .../glibc/cross-localedef-native_2.41.bb | 52 -------- .../glibc/cross-localedef-native_2.42.bb | 52 ++++++++ meta/recipes-core/glibc/glibc-common.inc | 2 +- meta/recipes-core/glibc/glibc-locale_2.41.bb | 1 - meta/recipes-core/glibc/glibc-locale_2.42.bb | 1 + meta/recipes-core/glibc/glibc-mtrace_2.41.bb | 1 - meta/recipes-core/glibc/glibc-mtrace_2.42.bb | 1 + meta/recipes-core/glibc/glibc-scripts_2.41.bb | 1 - meta/recipes-core/glibc/glibc-scripts_2.42.bb | 1 + meta/recipes-core/glibc/glibc-testsuite_2.41.bb | 36 ------ meta/recipes-core/glibc/glibc-testsuite_2.42.bb | 36 ++++++ meta/recipes-core/glibc/glibc-version.inc | 8 +- ...e-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch | 24 ---- ...def-Add-hardlink-resolver-from-util-linux.patch | 2 +- ...lib-Add-single-threaded-fast-path-to-rand.patch | 47 ------- ...ledef-fix-ups-hardlink-to-make-it-compile.patch | 2 +- ...libc-Look-for-host-system-ld.so.cache-as-.patch | 8 +- ...libc-Fix-buffer-overrun-with-a-relocated-.patch | 6 +- ...libc-Raise-the-size-of-arrays-containing-.patch | 26 ++-- ...ivesdk-glibc-Allow-64-bit-atomics-for-x86.patch | 2 +- ...libc-Make-relocatable-install-for-locales.patch | 6 +- ...libc-Fall-back-to-faccessat-on-faccess2-r.patch | 2 +- ...thin-the-path-sets-wrong-config-variables.patch | 6 +- ...c-Cross-building-and-testing-instructions.patch | 2 +- ...011-eglibc-Help-bootstrap-cross-toolchain.patch | 4 +- ...0012-eglibc-Resolve-__fpscr_values-on-SH4.patch | 2 +- ...ward-port-cross-locale-generation-support.patch | 6 +- ...dd-to-archive-uses-a-hard-coded-locale-pa.patch | 4 +- ...erpc-Do-not-ask-compiler-for-finding-arch.patch | 2 +- ...-Unify-the-header-between-arm-and-aarch64.patch | 26 ++-- ...o-with-printf-builtin-in-nscd-init-script.patch | 2 +- ...-configure.ac-Set-libc_cv_rootsbindir-onl.patch | 2 +- ...ke-shell-interpreter-overridable-in-tzsel.patch | 4 +- ....ksh-Use-bin-sh-default-shell-interpreter.patch | 2 +- ...thread-failed-in-unprivileged-process-BZ-.patch | 2 +- ...oded-build-time-paths-in-the-output-binar.patch | 4 +- ...2-qemu-tests-that-can-hang-in-oe-selftest.patch | 12 +- ...e-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch | 28 ++++ meta/recipes-core/glibc/glibc_2.41.bb | 142 --------------------- meta/recipes-core/glibc/glibc_2.42.bb | 141 ++++++++++++++++++++ 41 files changed, 331 insertions(+), 379 deletions(-) delete mode 100644 meta/recipes-core/glibc/cross-localedef-native_2.41.bb create mode 100644 meta/recipes-core/glibc/cross-localedef-native_2.42.bb delete mode 100644 meta/recipes-core/glibc/glibc-locale_2.41.bb create mode 100644 meta/recipes-core/glibc/glibc-locale_2.42.bb delete mode 100644 meta/recipes-core/glibc/glibc-mtrace_2.41.bb create mode 100644 meta/recipes-core/glibc/glibc-mtrace_2.42.bb delete mode 100644 meta/recipes-core/glibc/glibc-scripts_2.41.bb create mode 100644 meta/recipes-core/glibc/glibc-scripts_2.42.bb delete mode 100644 meta/recipes-core/glibc/glibc-testsuite_2.41.bb create mode 100644 meta/recipes-core/glibc/glibc-testsuite_2.42.bb delete mode 100644 meta/recipes-core/glibc/glibc/0001-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch delete mode 100644 meta/recipes-core/glibc/glibc/0001-stdlib-Add-single-threaded-fast-path-to-rand.patch create mode 100644 meta/recipes-core/glibc/glibc/0024-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch delete mode 100644 meta/recipes-core/glibc/glibc_2.41.bb create mode 100644 meta/recipes-core/glibc/glibc_2.42.bb diff --git a/meta/conf/distro/include/tcmode-default.inc b/meta/conf/distro/include/tcmode-default.inc index fefd3324b6..d8c378f560 100644 --- a/meta/conf/distro/include/tcmode-default.inc +++ b/meta/conf/distro/include/tcmode-default.inc @@ -11,7 +11,7 @@ PREFERRED_PROVIDER_virtual/gettext ??= "gettext" GCCVERSION ?= "15.%" SDKGCCVERSION ?= "${GCCVERSION}" -GLIBCVERSION ?= "2.41%" +GLIBCVERSION ?= "2.42%" RUSTVERSION ?= "1.88.0%" PREFERRED_VERSION_gcc ?= "${GCCVERSION}" diff --git a/meta/recipes-core/glibc/cross-localedef-native_2.41.bb b/meta/recipes-core/glibc/cross-localedef-native_2.41.bb deleted file mode 100644 index 95acb3fc56..0000000000 --- a/meta/recipes-core/glibc/cross-localedef-native_2.41.bb +++ /dev/null @@ -1,52 +0,0 @@ -SUMMARY = "Cross locale generation tool for glibc" -HOMEPAGE = "http://www.gnu.org/software/libc/libc.html" -SECTION = "libs" -LICENSE = "LGPL-2.1-only" - -LIC_FILES_CHKSUM = "file://LICENSES;md5=df6e0948b55669789c30764c5fd9bc41 \ - file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \ - file://posix/rxspencer/COPYRIGHT;md5=dc5485bb394a13b2332ec1c785f5d83a \ - file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c" - -require glibc-version.inc - -# Tell autotools that we're working in the localedef directory -# -AUTOTOOLS_SCRIPT_PATH = "${S}/localedef" - -inherit autotools -inherit native - -FILESEXTRAPATHS =. "${FILE_DIRNAME}/${PN}:${FILE_DIRNAME}/glibc:" - -SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \ - git://github.com/kraj/localedef;branch=master;name=localedef;destsuffix=${BB_GIT_DEFAULT_DESTSUFFIX}/localedef;protocol=https \ - \ - file://0001-localedef-Add-hardlink-resolver-from-util-linux.patch \ - file://0002-localedef-fix-ups-hardlink-to-make-it-compile.patch \ - \ - file://0010-eglibc-Cross-building-and-testing-instructions.patch \ - file://0011-eglibc-Help-bootstrap-cross-toolchain.patch \ - file://0012-eglibc-Resolve-__fpscr_values-on-SH4.patch \ - file://0013-eglibc-Forward-port-cross-locale-generation-support.patch \ - file://0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch \ - file://0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch \ - file://0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch \ - " -# Makes for a rather long rev (22 characters), but... -# -SRCREV_FORMAT = "glibc_localedef" - -EXTRA_OECONF = "--with-glibc=${S}" - -# We do not need bash to run tzselect script, the default is to use -# bash but it can be configured by setting KSHELL Makefile variable -EXTRA_OEMAKE += "KSHELL=/bin/sh" - -CFLAGS += "-fgnu89-inline -std=gnu99 -DIS_IN\(x\)='0'" - -do_install() { - install -d ${D}${bindir} - install -m 0755 ${B}/localedef ${D}${bindir}/cross-localedef - install -m 0755 ${B}/cross-localedef-hardlink ${D}${bindir}/cross-localedef-hardlink -} diff --git a/meta/recipes-core/glibc/cross-localedef-native_2.42.bb b/meta/recipes-core/glibc/cross-localedef-native_2.42.bb new file mode 100644 index 0000000000..95acb3fc56 --- /dev/null +++ b/meta/recipes-core/glibc/cross-localedef-native_2.42.bb @@ -0,0 +1,52 @@ +SUMMARY = "Cross locale generation tool for glibc" +HOMEPAGE = "http://www.gnu.org/software/libc/libc.html" +SECTION = "libs" +LICENSE = "LGPL-2.1-only" + +LIC_FILES_CHKSUM = "file://LICENSES;md5=df6e0948b55669789c30764c5fd9bc41 \ + file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \ + file://posix/rxspencer/COPYRIGHT;md5=dc5485bb394a13b2332ec1c785f5d83a \ + file://COPYING.LIB;md5=4fbd65380cdd255951079008b364516c" + +require glibc-version.inc + +# Tell autotools that we're working in the localedef directory +# +AUTOTOOLS_SCRIPT_PATH = "${S}/localedef" + +inherit autotools +inherit native + +FILESEXTRAPATHS =. "${FILE_DIRNAME}/${PN}:${FILE_DIRNAME}/glibc:" + +SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \ + git://github.com/kraj/localedef;branch=master;name=localedef;destsuffix=${BB_GIT_DEFAULT_DESTSUFFIX}/localedef;protocol=https \ + \ + file://0001-localedef-Add-hardlink-resolver-from-util-linux.patch \ + file://0002-localedef-fix-ups-hardlink-to-make-it-compile.patch \ + \ + file://0010-eglibc-Cross-building-and-testing-instructions.patch \ + file://0011-eglibc-Help-bootstrap-cross-toolchain.patch \ + file://0012-eglibc-Resolve-__fpscr_values-on-SH4.patch \ + file://0013-eglibc-Forward-port-cross-locale-generation-support.patch \ + file://0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch \ + file://0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch \ + file://0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch \ + " +# Makes for a rather long rev (22 characters), but... +# +SRCREV_FORMAT = "glibc_localedef" + +EXTRA_OECONF = "--with-glibc=${S}" + +# We do not need bash to run tzselect script, the default is to use +# bash but it can be configured by setting KSHELL Makefile variable +EXTRA_OEMAKE += "KSHELL=/bin/sh" + +CFLAGS += "-fgnu89-inline -std=gnu99 -DIS_IN\(x\)='0'" + +do_install() { + install -d ${D}${bindir} + install -m 0755 ${B}/localedef ${D}${bindir}/cross-localedef + install -m 0755 ${B}/cross-localedef-hardlink ${D}${bindir}/cross-localedef-hardlink +} diff --git a/meta/recipes-core/glibc/glibc-common.inc b/meta/recipes-core/glibc/glibc-common.inc index fb62a4af94..7422ede04d 100644 --- a/meta/recipes-core/glibc/glibc-common.inc +++ b/meta/recipes-core/glibc/glibc-common.inc @@ -22,6 +22,6 @@ ARM_INSTRUCTION_SET:armv6 = "arm" # COMPATIBLE_HOST:libc-musl:class-target = "null" -PV = "2.41+git" +PV = "2.42+git" TOOLCHAIN = "gcc" diff --git a/meta/recipes-core/glibc/glibc-locale_2.41.bb b/meta/recipes-core/glibc/glibc-locale_2.41.bb deleted file mode 100644 index f7702e0358..0000000000 --- a/meta/recipes-core/glibc/glibc-locale_2.41.bb +++ /dev/null @@ -1 +0,0 @@ -require glibc-locale.inc diff --git a/meta/recipes-core/glibc/glibc-locale_2.42.bb b/meta/recipes-core/glibc/glibc-locale_2.42.bb new file mode 100644 index 0000000000..f7702e0358 --- /dev/null +++ b/meta/recipes-core/glibc/glibc-locale_2.42.bb @@ -0,0 +1 @@ +require glibc-locale.inc diff --git a/meta/recipes-core/glibc/glibc-mtrace_2.41.bb b/meta/recipes-core/glibc/glibc-mtrace_2.41.bb deleted file mode 100644 index 0b69bad46a..0000000000 --- a/meta/recipes-core/glibc/glibc-mtrace_2.41.bb +++ /dev/null @@ -1 +0,0 @@ -require glibc-mtrace.inc diff --git a/meta/recipes-core/glibc/glibc-mtrace_2.42.bb b/meta/recipes-core/glibc/glibc-mtrace_2.42.bb new file mode 100644 index 0000000000..0b69bad46a --- /dev/null +++ b/meta/recipes-core/glibc/glibc-mtrace_2.42.bb @@ -0,0 +1 @@ +require glibc-mtrace.inc diff --git a/meta/recipes-core/glibc/glibc-scripts_2.41.bb b/meta/recipes-core/glibc/glibc-scripts_2.41.bb deleted file mode 100644 index 5a89bd8022..0000000000 --- a/meta/recipes-core/glibc/glibc-scripts_2.41.bb +++ /dev/null @@ -1 +0,0 @@ -require glibc-scripts.inc diff --git a/meta/recipes-core/glibc/glibc-scripts_2.42.bb b/meta/recipes-core/glibc/glibc-scripts_2.42.bb new file mode 100644 index 0000000000..5a89bd8022 --- /dev/null +++ b/meta/recipes-core/glibc/glibc-scripts_2.42.bb @@ -0,0 +1 @@ +require glibc-scripts.inc diff --git a/meta/recipes-core/glibc/glibc-testsuite_2.41.bb b/meta/recipes-core/glibc/glibc-testsuite_2.41.bb deleted file mode 100644 index 3a2764e40b..0000000000 --- a/meta/recipes-core/glibc/glibc-testsuite_2.41.bb +++ /dev/null @@ -1,36 +0,0 @@ -require glibc_${PV}.bb -require glibc-tests.inc - -inherit qemu - -SRC_URI += "file://check-test-wrapper" - -# strip provides -PROVIDES = "" - -DEPENDS += "${@'qemu-native' if d.getVar('TOOLCHAIN_TEST_TARGET') == 'user' else ''}" - -TOOLCHAIN_TEST_TARGET ??= "user" -TOOLCHAIN_TEST_HOST ??= "localhost" -TOOLCHAIN_TEST_HOST_USER ??= "root" -TOOLCHAIN_TEST_HOST_PORT ??= "2222" - -do_check[nostamp] = "1" -do_check[network] = "1" -do_check:append () { - chmod 0755 ${UNPACKDIR}/check-test-wrapper - - oe_runmake -i \ - QEMU_SYSROOT="${RECIPE_SYSROOT}" \ - QEMU_OPTIONS="${@qemu_target_binary(d)} ${QEMU_OPTIONS}" \ - SSH_HOST="${TOOLCHAIN_TEST_HOST}" \ - SSH_HOST_USER="${TOOLCHAIN_TEST_HOST_USER}" \ - SSH_HOST_PORT="${TOOLCHAIN_TEST_HOST_PORT}" \ - test-wrapper="${UNPACKDIR}/check-test-wrapper ${TOOLCHAIN_TEST_TARGET}" \ - check -} - -inherit nopackages -deltask do_stash_locale -deltask do_install -deltask do_populate_sysroot diff --git a/meta/recipes-core/glibc/glibc-testsuite_2.42.bb b/meta/recipes-core/glibc/glibc-testsuite_2.42.bb new file mode 100644 index 0000000000..3a2764e40b --- /dev/null +++ b/meta/recipes-core/glibc/glibc-testsuite_2.42.bb @@ -0,0 +1,36 @@ +require glibc_${PV}.bb +require glibc-tests.inc + +inherit qemu + +SRC_URI += "file://check-test-wrapper" + +# strip provides +PROVIDES = "" + +DEPENDS += "${@'qemu-native' if d.getVar('TOOLCHAIN_TEST_TARGET') == 'user' else ''}" + +TOOLCHAIN_TEST_TARGET ??= "user" +TOOLCHAIN_TEST_HOST ??= "localhost" +TOOLCHAIN_TEST_HOST_USER ??= "root" +TOOLCHAIN_TEST_HOST_PORT ??= "2222" + +do_check[nostamp] = "1" +do_check[network] = "1" +do_check:append () { + chmod 0755 ${UNPACKDIR}/check-test-wrapper + + oe_runmake -i \ + QEMU_SYSROOT="${RECIPE_SYSROOT}" \ + QEMU_OPTIONS="${@qemu_target_binary(d)} ${QEMU_OPTIONS}" \ + SSH_HOST="${TOOLCHAIN_TEST_HOST}" \ + SSH_HOST_USER="${TOOLCHAIN_TEST_HOST_USER}" \ + SSH_HOST_PORT="${TOOLCHAIN_TEST_HOST_PORT}" \ + test-wrapper="${UNPACKDIR}/check-test-wrapper ${TOOLCHAIN_TEST_TARGET}" \ + check +} + +inherit nopackages +deltask do_stash_locale +deltask do_install +deltask do_populate_sysroot diff --git a/meta/recipes-core/glibc/glibc-version.inc b/meta/recipes-core/glibc/glibc-version.inc index a2cfd0f308..3a89e153bd 100644 --- a/meta/recipes-core/glibc/glibc-version.inc +++ b/meta/recipes-core/glibc/glibc-version.inc @@ -1,7 +1,7 @@ -SRCBRANCH ?= "release/2.41/master" -PV = "2.41+git" -SRCREV_glibc ?= "6e489c17f827317bcf8544efefa65f13b5a079dc" -SRCREV_localedef ?= "fab74f31b3811df543e24b6de47efdf45b538abc" +SRCBRANCH ?= "release/2.42/master" +PV = "2.42+git" +SRCREV_glibc ?= "d2097651cc57834dbfcaa102ddfacae0d86cfb66" +SRCREV_localedef ?= "cba02c503d7c853a38ccfb83c57e343ca5ecd7e5" GLIBC_GIT_URI ?= "git://sourceware.org/git/glibc.git;protocol=https" diff --git a/meta/recipes-core/glibc/glibc/0001-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch b/meta/recipes-core/glibc/glibc/0001-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch deleted file mode 100644 index b42b186418..0000000000 --- a/meta/recipes-core/glibc/glibc/0001-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch +++ /dev/null @@ -1,24 +0,0 @@ -From 603e50d6b8ccadb32d59b0497f76629665c1794b Mon Sep 17 00:00:00 2001 -From: Khem Raj -Date: Wed, 16 Apr 2025 19:51:01 -0700 -Subject: [PATCH] Propagate -ffile-prefix-map from CFLAGS to ASFLAGS. - -Upstream-Status: Submitted [https://sourceware.org/pipermail/libc-alpha/2025-April/165969.html] -Signed-off-by: Khem Raj ---- - Makeconfig | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/Makeconfig b/Makeconfig -index e35c5cfe4e..7a19c731c6 100644 ---- a/Makeconfig -+++ b/Makeconfig -@@ -1172,7 +1172,7 @@ endif - - # The assembler can generate debug information too. - ifndef ASFLAGS --ASFLAGS := $(filter -g% -fdebug-prefix-map=%,$(CFLAGS)) -+ASFLAGS := $(filter -g% -fdebug-prefix-map=% -ffile-prefix-map=%,$(CFLAGS)) - endif - override ASFLAGS += -Werror=undef $(ASFLAGS-config) $(asflags-cpu) - diff --git a/meta/recipes-core/glibc/glibc/0001-localedef-Add-hardlink-resolver-from-util-linux.patch b/meta/recipes-core/glibc/glibc/0001-localedef-Add-hardlink-resolver-from-util-linux.patch index dbe3ce8c32..b63e05b2a3 100644 --- a/meta/recipes-core/glibc/glibc/0001-localedef-Add-hardlink-resolver-from-util-linux.patch +++ b/meta/recipes-core/glibc/glibc/0001-localedef-Add-hardlink-resolver-from-util-linux.patch @@ -1,4 +1,4 @@ -From cecd20fa2ff3ee2bd887b1d427088f32678cc04f Mon Sep 17 00:00:00 2001 +From 47dfcfdc8399801ee18317ec155295eef33882ef Mon Sep 17 00:00:00 2001 From: Jason Wessel Date: Sat, 7 Dec 2019 09:59:22 -0800 Subject: [PATCH] localedef: Add hardlink resolver from util-linux diff --git a/meta/recipes-core/glibc/glibc/0001-stdlib-Add-single-threaded-fast-path-to-rand.patch b/meta/recipes-core/glibc/glibc/0001-stdlib-Add-single-threaded-fast-path-to-rand.patch deleted file mode 100644 index 736fc51f38..0000000000 --- a/meta/recipes-core/glibc/glibc/0001-stdlib-Add-single-threaded-fast-path-to-rand.patch +++ /dev/null @@ -1,47 +0,0 @@ -From 4f54b0dfc16dbe0df86afccb90e447df5f7f571e Mon Sep 17 00:00:00 2001 -From: Wilco Dijkstra -Date: Mon, 18 Mar 2024 15:18:20 +0000 -Subject: [PATCH] stdlib: Add single-threaded fast path to rand() -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -Improve performance of rand() and __random() by adding a single-threaded -fast path. Bench-random-lock shows about 5x speedup on Neoverse V1. - -Upstream-Status: Backport [be0cfd848d9ad7378800d6302bc11467cf2b514f] - -Reviewed-by: Adhemerval Zanella  -Signed-off-by: Haixiao Yan ---- - stdlib/random.c | 7 +++++++ - 1 file changed, 7 insertions(+) - -diff --git a/stdlib/random.c b/stdlib/random.c -index 17cc61ba8f55..5d482a857065 100644 ---- a/stdlib/random.c -+++ b/stdlib/random.c -@@ -51,6 +51,7 @@ - SUCH DAMAGE.*/ - - #include -+#include - #include - #include - #include -@@ -288,6 +289,12 @@ __random (void) - { - int32_t retval; - -+ if (SINGLE_THREAD_P) -+ { -+ (void) __random_r (&unsafe_state, &retval); -+ return retval; -+ } -+ - __libc_lock_lock (lock); - - (void) __random_r (&unsafe_state, &retval); --- -2.34.1 - diff --git a/meta/recipes-core/glibc/glibc/0002-localedef-fix-ups-hardlink-to-make-it-compile.patch b/meta/recipes-core/glibc/glibc/0002-localedef-fix-ups-hardlink-to-make-it-compile.patch index 59d71a0d8b..cbb0ad3ef9 100644 --- a/meta/recipes-core/glibc/glibc/0002-localedef-fix-ups-hardlink-to-make-it-compile.patch +++ b/meta/recipes-core/glibc/glibc/0002-localedef-fix-ups-hardlink-to-make-it-compile.patch @@ -1,4 +1,4 @@ -From e31f032ae87ba38645c66dd7d2dfaa8606602e70 Mon Sep 17 00:00:00 2001 +From 5ca14c7ac7f389d8a1bf34bb49cdbb2029779dab Mon Sep 17 00:00:00 2001 From: Jason Wessel Date: Sat, 7 Dec 2019 10:01:37 -0800 Subject: [PATCH] localedef: fix-ups hardlink to make it compile diff --git a/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch b/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch index 0f7db0d500..04ae8fda97 100644 --- a/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch +++ b/meta/recipes-core/glibc/glibc/0003-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch @@ -1,4 +1,4 @@ -From f794ec18764a59ad45e242092e2ae6f5e3b19761 Mon Sep 17 00:00:00 2001 +From 8c06fcbaf863f83b72445a8b2b70c62a5ae55fe7 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Sat, 3 Feb 2024 13:54:16 -0800 Subject: [PATCH] nativesdk-glibc: Look for host system ld.so.cache as well @@ -30,10 +30,10 @@ Signed-off-by: Khem Raj 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/elf/dl-load.c b/elf/dl-load.c -index f905578a65..d4dd0fbc2a 100644 +index 00b9da9ec7..bb31af89da 100644 --- a/elf/dl-load.c +++ b/elf/dl-load.c -@@ -2038,6 +2038,14 @@ _dl_map_object (struct link_map *loader, const char *name, +@@ -2038,6 +2038,14 @@ _dl_map_new_object (struct link_map *loader, const char *name, &loader->l_runpath_dirs, &realname, &fb, loader, LA_SER_RUNPATH, &found_other_class); @@ -48,7 +48,7 @@ index f905578a65..d4dd0fbc2a 100644 #ifdef USE_LDCONFIG if (fd == -1 && (__glibc_likely ((mode & __RTLD_SECURE) == 0) -@@ -2096,14 +2104,6 @@ _dl_map_object (struct link_map *loader, const char *name, +@@ -2096,14 +2104,6 @@ _dl_map_new_object (struct link_map *loader, const char *name, } #endif diff --git a/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch b/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch index d9731a6fb7..25c824c3bc 100644 --- a/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch +++ b/meta/recipes-core/glibc/glibc/0004-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch @@ -1,4 +1,4 @@ -From e8af7c91033875cfaf419c840d3283d71eb72d50 Mon Sep 17 00:00:00 2001 +From c89731d75a2c15be0c1402556407ddecccd3e561 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 01:50:00 +0000 Subject: [PATCH] nativesdk-glibc: Fix buffer overrun with a relocated SDK @@ -21,10 +21,10 @@ Signed-off-by: Khem Raj 1 file changed, 12 insertions(+) diff --git a/elf/dl-load.c b/elf/dl-load.c -index d4dd0fbc2a..0cd5221d6a 100644 +index bb31af89da..d331e0f01a 100644 --- a/elf/dl-load.c +++ b/elf/dl-load.c -@@ -1749,7 +1749,19 @@ open_path (const char *name, size_t namelen, int mode, +@@ -1750,7 +1750,19 @@ open_path (const char *name, size_t namelen, int mode, given on the command line when rtld is run directly. */ return -1; diff --git a/meta/recipes-core/glibc/glibc/0005-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch b/meta/recipes-core/glibc/glibc/0005-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch index 0ee03c95d8..23163d307f 100644 --- a/meta/recipes-core/glibc/glibc/0005-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch +++ b/meta/recipes-core/glibc/glibc/0005-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch @@ -1,4 +1,4 @@ -From d7c4488ff48992631e14a53c27252790eaefe928 Mon Sep 17 00:00:00 2001 +From 3bc3bbda6092b1b6d497d24e319a10b4c8c48caf Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 01:51:38 +0000 Subject: [PATCH] nativesdk-glibc: Raise the size of arrays containing dl paths @@ -26,10 +26,10 @@ Signed-off-by: Khem Raj 8 files changed, 15 insertions(+), 10 deletions(-) diff --git a/elf/dl-cache.c b/elf/dl-cache.c -index 300aa1b6dd..6df873e08b 100644 +index f9ca40de3f..407db2aa54 100644 --- a/elf/dl-cache.c +++ b/elf/dl-cache.c -@@ -336,6 +336,10 @@ search_cache (const char *string_table, uint32_t string_table_size, +@@ -335,6 +335,10 @@ search_cache (const char *string_table, uint32_t string_table_size, return best; } @@ -41,7 +41,7 @@ index 300aa1b6dd..6df873e08b 100644 _dl_cache_libcmp (const char *p1, const char *p2) { diff --git a/elf/dl-load.c b/elf/dl-load.c -index 0cd5221d6a..9b9593f8d8 100644 +index d331e0f01a..ee024f7136 100644 --- a/elf/dl-load.c +++ b/elf/dl-load.c @@ -107,8 +107,8 @@ enum { ncapstr = 1, max_capstrlen = 0 }; @@ -56,11 +56,11 @@ index 0cd5221d6a..9b9593f8d8 100644 SYSTEM_DIRS_LEN }; diff --git a/elf/dl-usage.c b/elf/dl-usage.c -index c6d13ac2ee..1dac82102d 100644 +index 31b27e5ea6..3cdb99caa7 100644 --- a/elf/dl-usage.c +++ b/elf/dl-usage.c -@@ -25,6 +25,8 @@ - #include +@@ -24,6 +24,8 @@ + #include +extern const char LD_SO_CACHE[4096] __attribute__ ((section (".ldsocache"))); @@ -68,7 +68,7 @@ index c6d13ac2ee..1dac82102d 100644 void _dl_usage (const char *argv0, const char *wrong_option) { -@@ -185,7 +187,7 @@ setting environment variables (which would be inherited by subprocesses).\n\ +@@ -184,7 +186,7 @@ setting environment variables (which would be inherited by subprocesses).\n\ --list list all dependencies and how they are resolved\n\ --verify verify that given object really is a dynamically linked\n\ object we can handle\n\ @@ -77,7 +77,7 @@ index c6d13ac2ee..1dac82102d 100644 --library-path PATH use given PATH instead of content of the environment\n\ variable LD_LIBRARY_PATH\n\ --glibc-hwcaps-prepend LIST\n\ -@@ -204,7 +206,7 @@ setting environment variables (which would be inherited by subprocesses).\n\ +@@ -203,7 +205,7 @@ setting environment variables (which would be inherited by subprocesses).\n\ \n\ This program interpreter self-identifies as: " RTLD "\n\ ", @@ -98,10 +98,10 @@ index cc49e13c86..394c1ce0c5 100644 +const char __invoke_dynamic_linker__[4096] __attribute__ ((section (".interp"))) = RUNTIME_LINKER; diff --git a/elf/ldconfig.c b/elf/ldconfig.c -index 1432187e9b..0654e02389 100644 +index 39b154c72c..c1014b773b 100644 --- a/elf/ldconfig.c +++ b/elf/ldconfig.c -@@ -151,6 +151,8 @@ static struct argp argp = +@@ -150,6 +150,8 @@ static struct argp argp = options, parse_opt, NULL, doc, NULL, more_help, NULL }; @@ -111,10 +111,10 @@ index 1432187e9b..0654e02389 100644 static error_t parse_opt (int key, char *arg, struct argp_state *state) diff --git a/elf/rtld.c b/elf/rtld.c -index f32058bba6..434ea6d0c5 100644 +index 493f9696ea..2ae4a5d28b 100644 --- a/elf/rtld.c +++ b/elf/rtld.c -@@ -190,6 +190,7 @@ dso_name_valid_for_suid (const char *p) +@@ -189,6 +189,7 @@ dso_name_valid_for_suid (const char *p) } return *p != '\0'; } diff --git a/meta/recipes-core/glibc/glibc/0006-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch b/meta/recipes-core/glibc/glibc/0006-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch index 597923e792..dc9e73832f 100644 --- a/meta/recipes-core/glibc/glibc/0006-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch +++ b/meta/recipes-core/glibc/glibc/0006-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch @@ -1,4 +1,4 @@ -From 9b408439eb042c4fc5cb33c8929dea419bf25b41 Mon Sep 17 00:00:00 2001 +From 2152334c3be94993763c5abfb2911ace0b191cd1 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Thu, 31 Dec 2015 14:35:35 -0800 Subject: [PATCH] nativesdk-glibc: Allow 64 bit atomics for x86 diff --git a/meta/recipes-core/glibc/glibc/0007-nativesdk-glibc-Make-relocatable-install-for-locales.patch b/meta/recipes-core/glibc/glibc/0007-nativesdk-glibc-Make-relocatable-install-for-locales.patch index 2886d461c8..ca1160bf78 100644 --- a/meta/recipes-core/glibc/glibc/0007-nativesdk-glibc-Make-relocatable-install-for-locales.patch +++ b/meta/recipes-core/glibc/glibc/0007-nativesdk-glibc-Make-relocatable-install-for-locales.patch @@ -1,4 +1,4 @@ -From 1a57ab6f7d602401396a18b0270498ff9228cf64 Mon Sep 17 00:00:00 2001 +From bfd7e42968f20a8c46716c4319def621e8c75d1e Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Fri, 3 Aug 2018 09:55:12 -0700 Subject: [PATCH] nativesdk-glibc: Make relocatable install for locales @@ -54,10 +54,10 @@ index 058a467cde..af62f3c304 100644 /* Size of initial mapping window, optimal if large enough to cover the header plus the initial locale. */ diff --git a/locale/localeinfo.h b/locale/localeinfo.h -index ab1b5e5659..92aef8d58e 100644 +index f503792d04..c71be7f4d9 100644 --- a/locale/localeinfo.h +++ b/locale/localeinfo.h -@@ -347,7 +347,7 @@ _nl_lookup_word (locale_t l, int category, int item) +@@ -346,7 +346,7 @@ _nl_lookup_word (locale_t l, int category, int item) } /* Default search path if no LOCPATH environment variable. */ diff --git a/meta/recipes-core/glibc/glibc/0008-nativesdk-glibc-Fall-back-to-faccessat-on-faccess2-r.patch b/meta/recipes-core/glibc/glibc/0008-nativesdk-glibc-Fall-back-to-faccessat-on-faccess2-r.patch index 025ad153d6..e43c81203a 100644 --- a/meta/recipes-core/glibc/glibc/0008-nativesdk-glibc-Fall-back-to-faccessat-on-faccess2-r.patch +++ b/meta/recipes-core/glibc/glibc/0008-nativesdk-glibc-Fall-back-to-faccessat-on-faccess2-r.patch @@ -1,4 +1,4 @@ -From 789083eea1feb1249ec5817710552dc31653b36e Mon Sep 17 00:00:00 2001 +From bd5a7b22d32d47a7d3b9ae0deb6e2d196025e57c Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Sat, 6 Mar 2021 14:48:56 -0800 Subject: [PATCH] nativesdk-glibc: Fall back to faccessat on faccess2 returns diff --git a/meta/recipes-core/glibc/glibc/0009-yes-within-the-path-sets-wrong-config-variables.patch b/meta/recipes-core/glibc/glibc/0009-yes-within-the-path-sets-wrong-config-variables.patch index dbb6d674d5..dfc734a707 100644 --- a/meta/recipes-core/glibc/glibc/0009-yes-within-the-path-sets-wrong-config-variables.patch +++ b/meta/recipes-core/glibc/glibc/0009-yes-within-the-path-sets-wrong-config-variables.patch @@ -1,4 +1,4 @@ -From 4a1ff3c313645aa425a0a87459c907dad1b9ca4b Mon Sep 17 00:00:00 2001 +From 8a67937e136ba22f062802c1df276604b3f58579 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 00:31:06 +0000 Subject: [PATCH] 'yes' within the path sets wrong config variables @@ -31,7 +31,7 @@ Signed-off-by: Khem Raj mode change 100644 => 100755 sysdeps/unix/sysv/linux/powerpc/powerpc64/configure diff --git a/sysdeps/aarch64/configure b/sysdeps/aarch64/configure -index 4bd5496a4a..6c051369fb 100755 +index f364e65fe7..258a344620 100755 --- a/sysdeps/aarch64/configure +++ b/sysdeps/aarch64/configure @@ -157,12 +157,12 @@ else case e in #( @@ -50,7 +50,7 @@ index 4bd5496a4a..6c051369fb 100755 libc_cv_aarch64_be=yes else case e in #( diff --git a/sysdeps/aarch64/configure.ac b/sysdeps/aarch64/configure.ac -index 56d12d661d..80fca20873 100644 +index a9a1b747f1..879db7c57c 100644 --- a/sysdeps/aarch64/configure.ac +++ b/sysdeps/aarch64/configure.ac @@ -13,8 +13,8 @@ AC_DEFINE(SUPPORT_STATIC_PIE) diff --git a/meta/recipes-core/glibc/glibc/0010-eglibc-Cross-building-and-testing-instructions.patch b/meta/recipes-core/glibc/glibc/0010-eglibc-Cross-building-and-testing-instructions.patch index b1bed71f2b..25330faef5 100644 --- a/meta/recipes-core/glibc/glibc/0010-eglibc-Cross-building-and-testing-instructions.patch +++ b/meta/recipes-core/glibc/glibc/0010-eglibc-Cross-building-and-testing-instructions.patch @@ -1,4 +1,4 @@ -From 7d158af5750b351b3b08e78bb6c5fe80e7cb36ba Mon Sep 17 00:00:00 2001 +From b8806cd4e2595bbad4d7c1e39554a382572e1e94 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 00:42:58 +0000 Subject: [PATCH] eglibc: Cross building and testing instructions diff --git a/meta/recipes-core/glibc/glibc/0011-eglibc-Help-bootstrap-cross-toolchain.patch b/meta/recipes-core/glibc/glibc/0011-eglibc-Help-bootstrap-cross-toolchain.patch index 13190125eb..d5ad72d8dd 100644 --- a/meta/recipes-core/glibc/glibc/0011-eglibc-Help-bootstrap-cross-toolchain.patch +++ b/meta/recipes-core/glibc/glibc/0011-eglibc-Help-bootstrap-cross-toolchain.patch @@ -1,4 +1,4 @@ -From 435b57e8327555b273a52df672b2611050a8c579 Mon Sep 17 00:00:00 2001 +From 86e15dc8bc5c4756bc6fa9326226ada7721b8c3c Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 00:49:28 +0000 Subject: [PATCH] eglibc: Help bootstrap cross toolchain @@ -29,7 +29,7 @@ Signed-off-by: Khem Raj create mode 100644 include/stubs-bootstrap.h diff --git a/Makefile b/Makefile -index 97b4328af8..5c20ed3cff 100644 +index cb927fb9f9..e62fb30d11 100644 --- a/Makefile +++ b/Makefile @@ -79,9 +79,18 @@ subdir-dirs = include diff --git a/meta/recipes-core/glibc/glibc/0012-eglibc-Resolve-__fpscr_values-on-SH4.patch b/meta/recipes-core/glibc/glibc/0012-eglibc-Resolve-__fpscr_values-on-SH4.patch index 780aff1e7d..92c1821dbf 100644 --- a/meta/recipes-core/glibc/glibc/0012-eglibc-Resolve-__fpscr_values-on-SH4.patch +++ b/meta/recipes-core/glibc/glibc/0012-eglibc-Resolve-__fpscr_values-on-SH4.patch @@ -1,4 +1,4 @@ -From 46937c30c52cf186609bee1ec927464d395afb30 Mon Sep 17 00:00:00 2001 +From 41d83a92776e77bf82461d0219ad9720702b20c4 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 00:55:53 +0000 Subject: [PATCH] eglibc: Resolve __fpscr_values on SH4 diff --git a/meta/recipes-core/glibc/glibc/0013-eglibc-Forward-port-cross-locale-generation-support.patch b/meta/recipes-core/glibc/glibc/0013-eglibc-Forward-port-cross-locale-generation-support.patch index 8f9bbb6cf3..0bad6d7ba8 100644 --- a/meta/recipes-core/glibc/glibc/0013-eglibc-Forward-port-cross-locale-generation-support.patch +++ b/meta/recipes-core/glibc/glibc/0013-eglibc-Forward-port-cross-locale-generation-support.patch @@ -1,4 +1,4 @@ -From 68dcae2527a64a4448334fdfe27c7b6014589aae Mon Sep 17 00:00:00 2001 +From ac8410f1f87a9b93107a0d6a46707fbe4532d154 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 01:33:49 +0000 Subject: [PATCH] eglibc: Forward port cross locale generation support @@ -87,10 +87,10 @@ index 0000000000..538f3f5edb + [LC_ALL] = sizeof ("LC_ALL") - 1 + }; diff --git a/locale/localeinfo.h b/locale/localeinfo.h -index 92aef8d58e..ae23b2f7fe 100644 +index c71be7f4d9..7e3cf2b920 100644 --- a/locale/localeinfo.h +++ b/locale/localeinfo.h -@@ -246,7 +246,7 @@ __libc_tsd_define (extern, locale_t, LOCALE) +@@ -245,7 +245,7 @@ extern __thread locale_t __libc_tsd_LOCALE unused. We can manage this playing some tricks with weak references. But with thread-local locale settings, it becomes quite ungainly unless we can use __thread variables. So only in that case do we attempt this. */ diff --git a/meta/recipes-core/glibc/glibc/0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch b/meta/recipes-core/glibc/glibc/0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch index 9448f360ef..62f7ca74c5 100644 --- a/meta/recipes-core/glibc/glibc/0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch +++ b/meta/recipes-core/glibc/glibc/0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch @@ -1,4 +1,4 @@ -From 194e83794369783287956fb12c7f8469e6b7d110 Mon Sep 17 00:00:00 2001 +From 1985a7225e52d8d56e2e48a5ecab83bba8178f21 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Fri, 3 Aug 2018 09:42:06 -0700 Subject: [PATCH] localedef --add-to-archive uses a hard-coded locale path @@ -18,7 +18,7 @@ Signed-off-by: Khem Raj 1 file changed, 25 insertions(+), 10 deletions(-) diff --git a/locale/programs/locarchive.c b/locale/programs/locarchive.c -index 2c19f4fd29..b8495848c3 100644 +index ad025a819b..0ca7465bcc 100644 --- a/locale/programs/locarchive.c +++ b/locale/programs/locarchive.c @@ -339,12 +339,24 @@ enlarge_archive (struct locarhandle *ah, const struct locarhead *head) diff --git a/meta/recipes-core/glibc/glibc/0015-powerpc-Do-not-ask-compiler-for-finding-arch.patch b/meta/recipes-core/glibc/glibc/0015-powerpc-Do-not-ask-compiler-for-finding-arch.patch index 0e00c04659..a8a0c17774 100644 --- a/meta/recipes-core/glibc/glibc/0015-powerpc-Do-not-ask-compiler-for-finding-arch.patch +++ b/meta/recipes-core/glibc/glibc/0015-powerpc-Do-not-ask-compiler-for-finding-arch.patch @@ -1,4 +1,4 @@ -From 7d7f6fcd4f4b6664bff75addc92bc7b8a86dc22d Mon Sep 17 00:00:00 2001 +From 947d62bf6a6d341aaba3143df4a644126d2c34f1 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Fri, 7 Aug 2020 14:31:16 -0700 Subject: [PATCH] powerpc: Do not ask compiler for finding arch diff --git a/meta/recipes-core/glibc/glibc/0016-wordsize.h-Unify-the-header-between-arm-and-aarch64.patch b/meta/recipes-core/glibc/glibc/0016-wordsize.h-Unify-the-header-between-arm-and-aarch64.patch index f40a8eff07..52ba027c13 100644 --- a/meta/recipes-core/glibc/glibc/0016-wordsize.h-Unify-the-header-between-arm-and-aarch64.patch +++ b/meta/recipes-core/glibc/glibc/0016-wordsize.h-Unify-the-header-between-arm-and-aarch64.patch @@ -1,4 +1,4 @@ -From 2bd0ea2c8f9595414741ed523c6ca07630a4fc96 Mon Sep 17 00:00:00 2001 +From 14a3c302c1394781b19ff7fdb5c6f3c06aca5d51 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Fri, 15 May 2020 17:05:45 -0700 Subject: [PATCH] wordsize.h: Unify the header between arm and aarch64 @@ -11,36 +11,32 @@ Upstream-Status: Inappropriate [ OE-Specific ] Signed-off-by: Khem Raj --- - sysdeps/aarch64/bits/wordsize.h | 11 +++++++++-- + sysdeps/aarch64/bits/wordsize.h | 14 ++++++++++++-- sysdeps/arm/bits/wordsize.h | 22 +--------------------- - 2 files changed, 10 insertions(+), 23 deletions(-) + 2 files changed, 13 insertions(+), 23 deletions(-) mode change 100644 => 120000 sysdeps/arm/bits/wordsize.h diff --git a/sysdeps/aarch64/bits/wordsize.h b/sysdeps/aarch64/bits/wordsize.h -index f56260c2de..391d79d5a8 100644 +index 33d0e20566..57bbda568e 100644 --- a/sysdeps/aarch64/bits/wordsize.h +++ b/sysdeps/aarch64/bits/wordsize.h -@@ -17,12 +17,19 @@ +@@ -17,5 +17,15 @@ License along with the GNU C Library; if not, see . */ --#ifdef __LP64__ +-#define __WORDSIZE 64 +-#define __WORDSIZE_TIME64_COMPAT32 0 +#if defined (__aarch64__) && defined (__LP64__) - # define __WORDSIZE 64 --#else -+#elif defined (__aarch64__) - # define __WORDSIZE 32 - # define __WORDSIZE32_SIZE_ULONG 1 - # define __WORDSIZE32_PTRDIFF_LONG 1 ++# define __WORDSIZE 64 +#else +# define __WORDSIZE 32 +# define __WORDSIZE_TIME64_COMPAT32 1 +# define __WORDSIZE32_SIZE_ULONG 0 +# define __WORDSIZE32_PTRDIFF_LONG 0 - #endif - ++#endif ++ +#ifdef __aarch64__ - #define __WORDSIZE_TIME64_COMPAT32 0 ++# define __WORDSIZE_TIME64_COMPAT32 0 +#endif diff --git a/sysdeps/arm/bits/wordsize.h b/sysdeps/arm/bits/wordsize.h deleted file mode 100644 diff --git a/meta/recipes-core/glibc/glibc/0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch b/meta/recipes-core/glibc/glibc/0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch index 2af39799be..f0dead3005 100644 --- a/meta/recipes-core/glibc/glibc/0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch +++ b/meta/recipes-core/glibc/glibc/0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch @@ -1,4 +1,4 @@ -From 7ef9358bbb184026914fb4d9ff479361b82bf6c9 Mon Sep 17 00:00:00 2001 +From 806d6d37765d3a1454720c194758304768171f95 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Thu, 31 Dec 2015 14:33:02 -0800 Subject: [PATCH] Replace echo with printf builtin in nscd init script diff --git a/meta/recipes-core/glibc/glibc/0018-sysdeps-gnu-configure.ac-Set-libc_cv_rootsbindir-onl.patch b/meta/recipes-core/glibc/glibc/0018-sysdeps-gnu-configure.ac-Set-libc_cv_rootsbindir-onl.patch index ca30edd91c..b0e4d587b8 100644 --- a/meta/recipes-core/glibc/glibc/0018-sysdeps-gnu-configure.ac-Set-libc_cv_rootsbindir-onl.patch +++ b/meta/recipes-core/glibc/glibc/0018-sysdeps-gnu-configure.ac-Set-libc_cv_rootsbindir-onl.patch @@ -1,4 +1,4 @@ -From c43c1758baddaff1fb82afc118f7dba23af12540 Mon Sep 17 00:00:00 2001 +From 6fca57088d013e22f9204570f72ac398b59b6689 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 18 Mar 2015 00:27:10 +0000 Subject: [PATCH] sysdeps/gnu/configure.ac: Set libc_cv_rootsbindir only if its diff --git a/meta/recipes-core/glibc/glibc/0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch b/meta/recipes-core/glibc/glibc/0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch index 2e4c6ced9e..b95c2eb6d8 100644 --- a/meta/recipes-core/glibc/glibc/0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch +++ b/meta/recipes-core/glibc/glibc/0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch @@ -1,4 +1,4 @@ -From a2179a1a5e0f6ded889d2c88cabb23c92b5a4b1e Mon Sep 17 00:00:00 2001 +From 7bab0da0d299f7c1cf4111b0da2510fe0bc83a01 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Thu, 9 Dec 2021 15:14:42 -0800 Subject: [PATCH] timezone: Make shell interpreter overridable in tzselect.ksh @@ -14,7 +14,7 @@ Signed-off-by: Khem Raj 2 files changed, 10 insertions(+) diff --git a/Makeconfig b/Makeconfig -index d0108d2caa..75887b1334 100644 +index 7102d922b2..38a0b4a569 100644 --- a/Makeconfig +++ b/Makeconfig @@ -309,6 +309,15 @@ ifndef sysincludedir diff --git a/meta/recipes-core/glibc/glibc/0020-tzselect.ksh-Use-bin-sh-default-shell-interpreter.patch b/meta/recipes-core/glibc/glibc/0020-tzselect.ksh-Use-bin-sh-default-shell-interpreter.patch index e68e37b125..ea4c0afb09 100644 --- a/meta/recipes-core/glibc/glibc/0020-tzselect.ksh-Use-bin-sh-default-shell-interpreter.patch +++ b/meta/recipes-core/glibc/glibc/0020-tzselect.ksh-Use-bin-sh-default-shell-interpreter.patch @@ -1,4 +1,4 @@ -From c86de3e8b739f20fd7211b66dc3c69b61d28d611 Mon Sep 17 00:00:00 2001 +From 38dc3d019fbfa6c4b15f242b46c95ad35f427594 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Wed, 15 Dec 2021 21:47:53 -0800 Subject: [PATCH] tzselect.ksh: Use /bin/sh default shell interpreter diff --git a/meta/recipes-core/glibc/glibc/0021-fix-create-thread-failed-in-unprivileged-process-BZ-.patch b/meta/recipes-core/glibc/glibc/0021-fix-create-thread-failed-in-unprivileged-process-BZ-.patch index f1391a095c..09d5bf745e 100644 --- a/meta/recipes-core/glibc/glibc/0021-fix-create-thread-failed-in-unprivileged-process-BZ-.patch +++ b/meta/recipes-core/glibc/glibc/0021-fix-create-thread-failed-in-unprivileged-process-BZ-.patch @@ -1,4 +1,4 @@ -From 06dd2eec0d57e1e2702069ee4c970c68fc4d3bcb Mon Sep 17 00:00:00 2001 +From 7c5d4f1c2161c0ff4fc0057ff0f1382bd784e06a Mon Sep 17 00:00:00 2001 From: Hongxu Jia Date: Sun, 29 Aug 2021 20:49:16 +0800 Subject: [PATCH] fix create thread failed in unprivileged process [BZ #28287] diff --git a/meta/recipes-core/glibc/glibc/0022-Avoid-hardcoded-build-time-paths-in-the-output-binar.patch b/meta/recipes-core/glibc/glibc/0022-Avoid-hardcoded-build-time-paths-in-the-output-binar.patch index a90814c63a..9fa5d471ad 100644 --- a/meta/recipes-core/glibc/glibc/0022-Avoid-hardcoded-build-time-paths-in-the-output-binar.patch +++ b/meta/recipes-core/glibc/glibc/0022-Avoid-hardcoded-build-time-paths-in-the-output-binar.patch @@ -1,4 +1,4 @@ -From cd66a5301c4d84e3dbc4e30fdb9e32b341e66b3d Mon Sep 17 00:00:00 2001 +From 662d544fbed823b9bf917058762ddb54bcee5f07 Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sun, 24 Jul 2022 07:07:29 -0700 Subject: [PATCH] Avoid hardcoded build time paths in the output binaries @@ -14,7 +14,7 @@ Signed-off-by: Khem Raj 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/support/Makefile b/support/Makefile -index 59a9974539..c3f7302bcb 100644 +index d41278eeab..657769418e 100644 --- a/support/Makefile +++ b/support/Makefile @@ -238,9 +238,9 @@ libsupport-inhibit-o += .o diff --git a/meta/recipes-core/glibc/glibc/0023-tests-Skip-2-qemu-tests-that-can-hang-in-oe-selftest.patch b/meta/recipes-core/glibc/glibc/0023-tests-Skip-2-qemu-tests-that-can-hang-in-oe-selftest.patch index 50d80ed577..1dc2d694ef 100644 --- a/meta/recipes-core/glibc/glibc/0023-tests-Skip-2-qemu-tests-that-can-hang-in-oe-selftest.patch +++ b/meta/recipes-core/glibc/glibc/0023-tests-Skip-2-qemu-tests-that-can-hang-in-oe-selftest.patch @@ -1,4 +1,4 @@ -From 5395ccff4478d42fab7f2bd6ba7f7188bec09ddf Mon Sep 17 00:00:00 2001 +From 2630f675276f3be0d045f5ca7fd21b1e422a03f6 Mon Sep 17 00:00:00 2001 From: Yash Shinde Date: Fri, 5 Apr 2024 08:24:36 -0700 Subject: [PATCH] tests: Skip 2 qemu tests that can hang in oe-selftest @@ -20,18 +20,18 @@ Signed-off-by: Khem Raj 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sysdeps/unix/sysv/linux/Makefile b/sysdeps/unix/sysv/linux/Makefile -index 8a755293b3..22dafcaad1 100644 +index c47cbdf428..1c4f3509ac 100644 --- a/sysdeps/unix/sysv/linux/Makefile +++ b/sysdeps/unix/sysv/linux/Makefile -@@ -228,7 +228,6 @@ tests += \ - tst-rlimit-infinity \ +@@ -220,7 +220,6 @@ tests += \ tst-sched-affinity-inheritance \ tst-sched_setattr \ + tst-sched_setattr-thread \ - tst-scm_rights \ tst-sigtimedwait \ tst-sync_file_range \ tst-syscall-restart \ -@@ -240,6 +239,8 @@ tests += \ +@@ -232,6 +231,8 @@ tests += \ tst-timerfd \ tst-ttyname-direct \ tst-ttyname-namespace \ @@ -40,7 +40,7 @@ index 8a755293b3..22dafcaad1 100644 # tests # process_madvise requires CAP_SYS_ADMIN. -@@ -282,9 +283,10 @@ tests-time64 += \ +@@ -274,9 +275,10 @@ tests-time64 += \ tst-ntp_gettimex-time64 \ tst-ppoll-time64 \ tst-prctl-time64 \ diff --git a/meta/recipes-core/glibc/glibc/0024-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch b/meta/recipes-core/glibc/glibc/0024-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch new file mode 100644 index 0000000000..81e580fc72 --- /dev/null +++ b/meta/recipes-core/glibc/glibc/0024-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch @@ -0,0 +1,28 @@ +From 111cb0b1f7410eea49ed8869c74352a11cdcbf0f Mon Sep 17 00:00:00 2001 +From: Khem Raj +Date: Wed, 16 Apr 2025 19:51:01 -0700 +Subject: [PATCH] Propagate -ffile-prefix-map from CFLAGS to ASFLAGS. + +-ffile-prefix-map also implies -fdebug-prefix-map +and some systems may use --ffile-prefix-map for building +reprodubile systems + +Upstream-Status: Submitted [https://patchwork.sourceware.org/project/glibc/patch/20250429064632.2048954-1-raj.khem@gmail.com/] +Signed-off-by: Khem Raj +--- + Makeconfig | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makeconfig b/Makeconfig +index 38a0b4a569..21a6ee94c1 100644 +--- a/Makeconfig ++++ b/Makeconfig +@@ -1191,7 +1191,7 @@ endif + + # The assembler can generate debug information too. + ifndef ASFLAGS +-ASFLAGS := $(filter -g% -fdebug-prefix-map=%,$(CFLAGS)) ++ASFLAGS := $(filter -g% -fdebug-prefix-map=% -ffile-prefix-map=%,$(CFLAGS)) + endif + override ASFLAGS += -Werror=undef $(ASFLAGS-config) $(asflags-cpu) $(as-sframe) + diff --git a/meta/recipes-core/glibc/glibc_2.41.bb b/meta/recipes-core/glibc/glibc_2.41.bb deleted file mode 100644 index 042abb7e45..0000000000 --- a/meta/recipes-core/glibc/glibc_2.41.bb +++ /dev/null @@ -1,142 +0,0 @@ -require glibc.inc -require glibc-version.inc - -# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010022 -# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010023 -# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010024 -CVE_STATUS_GROUPS = "CVE_STATUS_RECIPE" -CVE_STATUS_RECIPE = "CVE-2019-1010022 CVE-2019-1010023 CVE-2019-1010024" -CVE_STATUS_RECIPE[status] = "disputed: \ -Upstream glibc maintainers dispute there is any issue and have no plans to address it further. \ -this is being treated as a non-security bug and no real threat." - -# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010025 -# Potential patch at https://sourceware.org/bugzilla/show_bug.cgi?id=22853 -CVE_STATUS[CVE-2019-1010025] = "disputed: \ -Allows for ASLR bypass so can bypass some hardening, not an exploit in itself, may allow \ -easier access for another. 'ASLR bypass itself is not a vulnerability.'" - -CVE_STATUS_GROUPS += "CVE_STATUS_STABLE_BACKPORTS" -CVE_STATUS_STABLE_BACKPORTS = "" -CVE_STATUS_STABLE_BACKPORTS[status] = "cpe-stable-backport: fix available in used git hash" - -DEPENDS += "gperf-native bison-native" - -NATIVESDKFIXES ?= "" -NATIVESDKFIXES:class-nativesdk = "\ - file://0003-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch \ - file://0004-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch \ - file://0005-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch \ - file://0006-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch \ - file://0007-nativesdk-glibc-Make-relocatable-install-for-locales.patch \ - file://0008-nativesdk-glibc-Fall-back-to-faccessat-on-faccess2-r.patch \ -" - -SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \ - file://etc/ld.so.conf \ - file://generate-supported.mk \ - file://makedbs.sh \ - \ - ${NATIVESDKFIXES} \ - file://0009-yes-within-the-path-sets-wrong-config-variables.patch \ - file://0010-eglibc-Cross-building-and-testing-instructions.patch \ - file://0011-eglibc-Help-bootstrap-cross-toolchain.patch \ - file://0012-eglibc-Resolve-__fpscr_values-on-SH4.patch \ - file://0013-eglibc-Forward-port-cross-locale-generation-support.patch \ - file://0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch \ - file://0015-powerpc-Do-not-ask-compiler-for-finding-arch.patch \ - file://0016-wordsize.h-Unify-the-header-between-arm-and-aarch64.patch \ - file://0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch \ - file://0018-sysdeps-gnu-configure.ac-Set-libc_cv_rootsbindir-onl.patch \ - file://0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch \ - file://0020-tzselect.ksh-Use-bin-sh-default-shell-interpreter.patch \ - file://0021-fix-create-thread-failed-in-unprivileged-process-BZ-.patch \ - file://0022-Avoid-hardcoded-build-time-paths-in-the-output-binar.patch \ - file://0023-tests-Skip-2-qemu-tests-that-can-hang-in-oe-selftest.patch \ - file://0001-stdlib-Add-single-threaded-fast-path-to-rand.patch \ - file://0001-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch \ -" -B = "${WORKDIR}/build-${TARGET_SYS}" - -PACKAGES_DYNAMIC = "" - -# the -isystem in bitbake.conf screws up glibc do_stage -BUILD_CPPFLAGS = "-I${STAGING_INCDIR_NATIVE}" -TARGET_CPPFLAGS = "-I${STAGING_DIR_TARGET}${includedir}" - -GLIBC_BROKEN_LOCALES = "" - -GLIBCPIE ??= "" - -EXTRA_OECONF = "--enable-kernel=${OLDEST_KERNEL} \ - --disable-profile \ - --disable-debug --without-gd \ - --enable-clocale=gnu \ - --with-headers=${STAGING_INCDIR} \ - --without-selinux \ - --enable-bind-now \ - --enable-stack-protector=strong \ - --disable-crypt \ - --with-default-link \ - --disable-werror \ - --enable-fortify-source \ - ${GLIBCPIE} \ - ${GLIBC_EXTRA_OECONF}" - -EXTRA_OECONF += "${@get_libc_fpu_setting(bb, d)}" - -EXTRA_OECONF:append:x86-64 = " --enable-cet" - -PACKAGECONFIG ??= "nscd memory-tagging" - -PACKAGECONFIG[nscd] = "--enable-nscd,--disable-nscd" -PACKAGECONFIG[memory-tagging] = "--enable-memory-tagging,--disable-memory-tagging" - -do_patch:append() { - bb.build.exec_func('do_fix_readlib_c', d) -} - -do_fix_readlib_c () { - sed -i -e 's#OECORE_KNOWN_INTERPRETER_NAMES#${EGLIBC_KNOWN_INTERPRETER_NAMES}#' ${S}/elf/readlib.c -} - -do_configure () { -# override this function to avoid the autoconf/automake/aclocal/autoheader -# calls for now -# don't pass CPPFLAGS into configure, since it upsets the kernel-headers -# version check and doesn't really help with anything - (cd ${S} && gnu-configize) || die "failure in running gnu-configize" - find ${S} -name "configure" | xargs touch - CPPFLAGS="" LD="${HOST_PREFIX}ld.bfd ${TOOLCHAIN_OPTIONS}" oe_runconf -} - -LDFLAGS += "-fuse-ld=bfd" -CFLAGS += "-fuse-ld=bfd" - -do_compile () { - base_do_compile - echo "Adjust ldd script" - if [ -n "${RTLDLIST}" ] - then - prevrtld=`cat ${B}/elf/ldd | grep "^RTLDLIST=" | sed 's#^RTLDLIST="\?\([^"]*\)"\?$#\1#'` - # remove duplicate entries - newrtld=`echo $(printf '%s\n' ${prevrtld} ${RTLDLIST} | LC_ALL=C sort -u)` - echo "ldd \"${prevrtld} ${RTLDLIST}\" -> \"${newrtld}\"" - sed -i ${B}/elf/ldd -e "s#^RTLDLIST=.*\$#RTLDLIST=\"${newrtld}\"#" - fi -} - -require glibc-package.inc - -# When upgrading glibc it's important to know if there are any new symbols -# that pseudo needs to wrap. In the future a generalised ABI comparison tool -# would be good, but to solve the immediate need we can simply list the -# exported symbols to files in WORKDIR. -do_symlist() { - for LIB in ${D}${base_libdir}/lib*.so.*; do - ${NM} --dynamic $LIB | awk --source '$2 == "T" { print $3 }' | sort > ${WORKDIR}/$(basename $LIB)-${PV}.symbols - done -} -addtask symlist after do_install - -BBCLASSEXTEND = "nativesdk" diff --git a/meta/recipes-core/glibc/glibc_2.42.bb b/meta/recipes-core/glibc/glibc_2.42.bb new file mode 100644 index 0000000000..f9c1cdc2f1 --- /dev/null +++ b/meta/recipes-core/glibc/glibc_2.42.bb @@ -0,0 +1,141 @@ +require glibc.inc +require glibc-version.inc + +# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010022 +# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010023 +# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010024 +CVE_STATUS_GROUPS = "CVE_STATUS_RECIPE" +CVE_STATUS_RECIPE = "CVE-2019-1010022 CVE-2019-1010023 CVE-2019-1010024" +CVE_STATUS_RECIPE[status] = "disputed: \ +Upstream glibc maintainers dispute there is any issue and have no plans to address it further. \ +this is being treated as a non-security bug and no real threat." + +# glibc https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2019-1010025 +# Potential patch at https://sourceware.org/bugzilla/show_bug.cgi?id=22853 +CVE_STATUS[CVE-2019-1010025] = "disputed: \ +Allows for ASLR bypass so can bypass some hardening, not an exploit in itself, may allow \ +easier access for another. 'ASLR bypass itself is not a vulnerability.'" + +CVE_STATUS_GROUPS += "CVE_STATUS_STABLE_BACKPORTS" +CVE_STATUS_STABLE_BACKPORTS = "" +CVE_STATUS_STABLE_BACKPORTS[status] = "cpe-stable-backport: fix available in used git hash" + +DEPENDS += "gperf-native bison-native" + +NATIVESDKFIXES ?= "" +NATIVESDKFIXES:class-nativesdk = "\ + file://0003-nativesdk-glibc-Look-for-host-system-ld.so.cache-as-.patch \ + file://0004-nativesdk-glibc-Fix-buffer-overrun-with-a-relocated-.patch \ + file://0005-nativesdk-glibc-Raise-the-size-of-arrays-containing-.patch \ + file://0006-nativesdk-glibc-Allow-64-bit-atomics-for-x86.patch \ + file://0007-nativesdk-glibc-Make-relocatable-install-for-locales.patch \ + file://0008-nativesdk-glibc-Fall-back-to-faccessat-on-faccess2-r.patch \ +" + +SRC_URI = "${GLIBC_GIT_URI};branch=${SRCBRANCH};name=glibc \ + file://etc/ld.so.conf \ + file://generate-supported.mk \ + file://makedbs.sh \ + \ + ${NATIVESDKFIXES} \ + file://0009-yes-within-the-path-sets-wrong-config-variables.patch \ + file://0010-eglibc-Cross-building-and-testing-instructions.patch \ + file://0011-eglibc-Help-bootstrap-cross-toolchain.patch \ + file://0012-eglibc-Resolve-__fpscr_values-on-SH4.patch \ + file://0013-eglibc-Forward-port-cross-locale-generation-support.patch \ + file://0014-localedef-add-to-archive-uses-a-hard-coded-locale-pa.patch \ + file://0015-powerpc-Do-not-ask-compiler-for-finding-arch.patch \ + file://0016-wordsize.h-Unify-the-header-between-arm-and-aarch64.patch \ + file://0017-Replace-echo-with-printf-builtin-in-nscd-init-script.patch \ + file://0018-sysdeps-gnu-configure.ac-Set-libc_cv_rootsbindir-onl.patch \ + file://0019-timezone-Make-shell-interpreter-overridable-in-tzsel.patch \ + file://0020-tzselect.ksh-Use-bin-sh-default-shell-interpreter.patch \ + file://0021-fix-create-thread-failed-in-unprivileged-process-BZ-.patch \ + file://0022-Avoid-hardcoded-build-time-paths-in-the-output-binar.patch \ + file://0023-tests-Skip-2-qemu-tests-that-can-hang-in-oe-selftest.patch \ + file://0024-Propagate-ffile-prefix-map-from-CFLAGS-to-ASFLAGS.patch \ +" +B = "${WORKDIR}/build-${TARGET_SYS}" + +PACKAGES_DYNAMIC = "" + +# the -isystem in bitbake.conf screws up glibc do_stage +BUILD_CPPFLAGS = "-I${STAGING_INCDIR_NATIVE}" +TARGET_CPPFLAGS = "-I${STAGING_DIR_TARGET}${includedir}" + +GLIBC_BROKEN_LOCALES = "" + +GLIBCPIE ??= "" + +EXTRA_OECONF = "--enable-kernel=${OLDEST_KERNEL} \ + --disable-profile \ + --disable-debug --without-gd \ + --enable-clocale=gnu \ + --with-headers=${STAGING_INCDIR} \ + --without-selinux \ + --enable-bind-now \ + --enable-stack-protector=strong \ + --disable-crypt \ + --with-default-link \ + --disable-werror \ + --enable-fortify-source \ + ${GLIBCPIE} \ + ${GLIBC_EXTRA_OECONF}" + +EXTRA_OECONF += "${@get_libc_fpu_setting(bb, d)}" + +EXTRA_OECONF:append:x86-64 = " --enable-cet" + +PACKAGECONFIG ??= "nscd memory-tagging" + +PACKAGECONFIG[nscd] = "--enable-nscd,--disable-nscd" +PACKAGECONFIG[memory-tagging] = "--enable-memory-tagging,--disable-memory-tagging" + +do_patch:append() { + bb.build.exec_func('do_fix_readlib_c', d) +} + +do_fix_readlib_c () { + sed -i -e 's#OECORE_KNOWN_INTERPRETER_NAMES#${EGLIBC_KNOWN_INTERPRETER_NAMES}#' ${S}/elf/readlib.c +} + +do_configure () { +# override this function to avoid the autoconf/automake/aclocal/autoheader +# calls for now +# don't pass CPPFLAGS into configure, since it upsets the kernel-headers +# version check and doesn't really help with anything + (cd ${S} && gnu-configize) || die "failure in running gnu-configize" + find ${S} -name "configure" | xargs touch + CPPFLAGS="" LD="${HOST_PREFIX}ld.bfd ${TOOLCHAIN_OPTIONS}" oe_runconf +} + +LDFLAGS += "-fuse-ld=bfd" +CFLAGS += "-fuse-ld=bfd" + +do_compile () { + base_do_compile + echo "Adjust ldd script" + if [ -n "${RTLDLIST}" ] + then + prevrtld=`cat ${B}/elf/ldd | grep "^RTLDLIST=" | sed 's#^RTLDLIST="\?\([^"]*\)"\?$#\1#'` + # remove duplicate entries + newrtld=`echo $(printf '%s\n' ${prevrtld} ${RTLDLIST} | LC_ALL=C sort -u)` + echo "ldd \"${prevrtld} ${RTLDLIST}\" -> \"${newrtld}\"" + sed -i ${B}/elf/ldd -e "s#^RTLDLIST=.*\$#RTLDLIST=\"${newrtld}\"#" + fi +} + +require glibc-package.inc + +# When upgrading glibc it's important to know if there are any new symbols +# that pseudo needs to wrap. In the future a generalised ABI comparison tool +# would be good, but to solve the immediate need we can simply list the +# exported symbols to files in WORKDIR. +do_symlist() { + for LIB in ${D}${base_libdir}/lib*.so.*; do + ${NM} --dynamic $LIB | awk --source '$2 == "T" { print $3 }' | sort > ${WORKDIR}/$(basename $LIB)-${PV}.symbols + done +} +addtask symlist after do_install + +BBCLASSEXTEND = "nativesdk" -- cgit v1.2.3-54-g00ecf