diff options
Diffstat (limited to 'meta/recipes-devtools/pseudo')
-rw-r--r-- | meta/recipes-devtools/pseudo/files/glibc238.patch | 59 | ||||
-rw-r--r-- | meta/recipes-devtools/pseudo/pseudo.inc | 4 | ||||
-rw-r--r-- | meta/recipes-devtools/pseudo/pseudo_git.bb | 14 |
3 files changed, 72 insertions, 5 deletions
diff --git a/meta/recipes-devtools/pseudo/files/glibc238.patch b/meta/recipes-devtools/pseudo/files/glibc238.patch new file mode 100644 index 0000000000..da4b8caee3 --- /dev/null +++ b/meta/recipes-devtools/pseudo/files/glibc238.patch @@ -0,0 +1,59 @@ +glibc 2.38 would include __isoc23_strtol and similar symbols. This is trggerd by +_GNU_SOURCE but we have to set that for other definitions. Therefore play with defines +to turn this off within pseudo_wrappers.c. Elsewhere we can switch to _DEFAULT_SOURCE +rather than _GNU_SOURCE. + +Upstream-Status: Pending + +Index: git/pseudo_wrappers.c +=================================================================== +--- git.orig/pseudo_wrappers.c ++++ git/pseudo_wrappers.c +@@ -6,6 +6,15 @@ + * SPDX-License-Identifier: LGPL-2.1-only + * + */ ++/* glibc 2.38 would include __isoc23_strtol and similar symbols. This is trggerd by ++ * _GNU_SOURCE but we have to set that for other definitions. Therefore play with defines ++ * to turn this off. ++ */ ++#include <features.h> ++#undef __GLIBC_USE_ISOC2X ++#undef __GLIBC_USE_C2X_STRTOL ++#define __GLIBC_USE_C2X_STRTOL 0 ++ + #include <assert.h> + #include <stdlib.h> + #include <limits.h> +Index: git/pseudo_util.c +=================================================================== +--- git.orig/pseudo_util.c ++++ git/pseudo_util.c +@@ -8,6 +8,14 @@ + */ + /* we need access to RTLD_NEXT for a horrible workaround */ + #define _GNU_SOURCE ++/* glibc 2.38 would include __isoc23_strtol and similar symbols. This is trggerd by ++ * _GNU_SOURCE but we have to set that for other definitions. Therefore play with defines ++ * to turn this off. ++ */ ++#include <features.h> ++#undef __GLIBC_USE_ISOC2X ++#undef __GLIBC_USE_C2X_STRTOL ++#define __GLIBC_USE_C2X_STRTOL 0 + + #include <ctype.h> + #include <errno.h> +Index: git/pseudo_client.c +=================================================================== +--- git.orig/pseudo_client.c ++++ git/pseudo_client.c +@@ -6,7 +6,7 @@ + * SPDX-License-Identifier: LGPL-2.1-only + * + */ +-#define _GNU_SOURCE ++#define _DEFAULT_SOURCE + + #include <stdio.h> + #include <signal.h> diff --git a/meta/recipes-devtools/pseudo/pseudo.inc b/meta/recipes-devtools/pseudo/pseudo.inc index 7e09b6d58c..36283ffa74 100644 --- a/meta/recipes-devtools/pseudo/pseudo.inc +++ b/meta/recipes-devtools/pseudo/pseudo.inc @@ -133,8 +133,8 @@ do_install:append:class-native () { chrpath ${D}${bindir}/pseudo -r `chrpath ${D}${bindir}/pseudo | cut -d = -f 2 | sed s/XORIGIN/\\$ORIGIN/` install -d ${D}${sysconfdir} # The fallback files should never be modified - install -m 444 ${WORKDIR}/fallback-passwd ${D}${sysconfdir}/passwd - install -m 444 ${WORKDIR}/fallback-group ${D}${sysconfdir}/group + install -m 444 ${UNPACKDIR}/fallback-passwd ${D}${sysconfdir}/passwd + install -m 444 ${UNPACKDIR}/fallback-group ${D}${sysconfdir}/group # Two native/nativesdk entries below are the same # If necessary install for the alternative machine arch. This is only diff --git a/meta/recipes-devtools/pseudo/pseudo_git.bb b/meta/recipes-devtools/pseudo/pseudo_git.bb index e7ef6a730c..c70b509233 100644 --- a/meta/recipes-devtools/pseudo/pseudo_git.bb +++ b/meta/recipes-devtools/pseudo/pseudo_git.bb @@ -1,7 +1,8 @@ require pseudo.inc -SRC_URI = "git://git.yoctoproject.org/pseudo;branch=oe-core \ +SRC_URI = "git://git.yoctoproject.org/pseudo;branch=master;protocol=https \ file://0001-configure-Prune-PIE-flags.patch \ + file://glibc238.patch \ file://fallback-passwd \ file://fallback-group \ " @@ -13,9 +14,16 @@ SRC_URI:append:class-nativesdk = " \ file://older-glibc-symbols.patch" SRC_URI[prebuilt.sha256sum] = "ed9f456856e9d86359f169f46a70ad7be4190d6040282b84c8d97b99072485aa" -SRCREV = "2b4b88eb513335b0ece55fe51854693d9b20de35" +SRCREV = "0d292df61aeb886ae8ca33d9edc3b6d0ff5c0f0f" S = "${WORKDIR}/git" -PV = "1.9.0+git${SRCPV}" +PV = "1.9.0+git" + +# largefile and 64bit time_t support adds these macros via compiler flags globally +# remove them for pseudo since pseudo intercepts some of the functions which will be +# aliased due to this e.g. open/open64 and it will complain about duplicate definitions +# pseudo on 32bit systems is not much of use anyway and these features are not of much +# use for it. +TARGET_CC_ARCH:remove = "-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_TIME_BITS=64" # error: use of undeclared identifier '_STAT_VER' COMPATIBLE_HOST:libc-musl = 'null' |