strace: Fix build with glibc 2.28
PATCH v2 1/1 strace: Fix build with glibc 2.28
---
v2: Backport an upstreamed patch to fix the same instead
...001-tests-fix-build-with-fresh-glibc.patch | 41 +++++++++++++++++++ meta/recipes-devtools/strace/strace_4.23.bb | 1 + 2 files changed, 42 insertions(+) create mode 100644 meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch
meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch new file +41 -0
@@ -0,0 +1,41 @@ +From bba1b0085f2a2c83839647fee48628ee054aceb7 Mon Sep 17 00:00:00 2001 +From: "Dmitry V. Levin" <[email protected]> +Date: Sun, 15 Jul 2018 22:14:29 +0000 +Subject: [PATCH] tests: fix build with fresh glibc + +Workaround additional incompatibility between <sys/stat.h> and +<asm/stat.h> introduced by glibc-2.27.9000-566-gfd70af4. + +* tests/xstatx.c (statx, statx_timestamp): Redefine before the inclusion +of <sys/stat.h> to avoid conflicts between definitions provided by the +linux kernel headers and the GNU libc. +--- +Upstream-Status: Backport [https://gitlab.com/strace/strace/commit/3dbffb7] +Signed-off-by: Khem Raj <[email protected]> + + tests/xstatx.c | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/tests/xstatx.c b/tests/xstatx.c +index 7fb9326..441f4a8 100644 +--- a/tests/xstatx.c ++++ b/tests/xstatx.c +@@ -64,10 +64,14 @@ typedef off_t libc_off_t; + + # define stat libc_stat + # define stat64 libc_stat64 ++# define statx libc_statx ++# define statx_timestamp libc_statx_timestamp + # include <fcntl.h> + # include <sys/stat.h> +-# undef stat ++# undef statx_timestamp ++# undef statx + # undef stat64 ++# undef stat + + # undef st_atime + # undef st_mtime +-- +2.18.0 +
meta/recipes-devtools/strace/strace_4.23.bb +1 -0
@@ -14,6 +14,7 @@ SRC_URI = "https://strace.io/files/${PV}/strace-${PV}.tar.xz \ file://mips-SIGEMT.patch \ file://0001-caps-abbrev.awk-fix-gawk-s-path.patch \ file://0001-tests-sigaction-Check-for-mips-and-alpha-before-usin.patch \ + file://0001-tests-fix-build-with-fresh-glibc.patch \ " SRC_URI[md5sum] = "fad4bba0947553cef34d46a9fd78f039" SRC_URI[sha256sum] = "7860a6965f1dd832747bd8281a04738274398d32c56e9fbd0a68b1bb9ec09aad"
Signature · 1 line
2.18.0
Quoted 6 lines · Khem Raj
+++
b/meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patchmeta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch new file +4
-0@@ -0,0 +1,41 @@ +From bba1b0085f2a2c83839647fee48628ee054aceb7 Mon Sep 17 00:00:00 2001 +From: "Dmitry V. Levin" <[email protected]> +Date: Sun, 15 Jul 2018 22:14:29 +0000 +Subject: [PATCH] tests: fix build with fresh glibc
meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch line 14
Quoted 10 lines
meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch new file +10
-0+ +Workaround additional incompatibility between <sys/stat.h> and +<asm/stat.h> introduced by glibc-2.27.9000-566-gfd70af4. + +* tests/xstatx.c (statx, statx_timestamp): Redefine before the inclusion +of <sys/stat.h> to avoid conflicts between definitions provided by the +linux kernel headers and the GNU libc. +--- +Upstream-Status: Backport [https://gitlab.com/strace/strace/commit/3dbffb7] +Signed-off-by: Khem Raj <[email protected]>
Hopefully these patches don't last long but if you put the SOB/US above the scissors then devtool's refresh won't delete them.
Ross
Quoted 13 lines · Ross
Quoted 11 lines · Khem Raj
+++
b/meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patchmeta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch new file +9
-0@@ -0,0 +1,41 @@ +From bba1b0085f2a2c83839647fee48628ee054aceb7 Mon Sep 17 00:00:00 2001 +From: "Dmitry V. Levin" <[email protected]> +Date: Sun, 15 Jul 2018 22:14:29 +0000 +Subject: [PATCH] tests: fix build with fresh glibc + +Workaround additional incompatibility between <sys/stat.h> and +<asm/stat.h> introduced by glibc-2.27.9000-566-gfd70af4. + +* tests/xstatx.c (statx, statx_timestamp): Redefine before the inclusion
Quoted 9 lines
meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch line 14
Quoted 5 lines
meta/recipes-devtools/strace/strace/0001-tests-fix-build-with-fresh-glibc.patch new file +5
-0+of <sys/stat.h> to avoid conflicts between definitions provided by the +linux kernel headers and the GNU libc. +--- +Upstream-Status: Backport [https://gitlab.com/strace/strace/commit/3dbffb7] +Signed-off-by: Khem Raj <[email protected]>Hopefully these patches don't last long but if you put the SOB/US above the scissors then devtool's refresh won't delete them.
depends on how quickly a new strace release is made available. I have pushed the updated patch meanwhile
Quoted 1 line
Ross