summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/strace/strace
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/strace/strace')
-rw-r--r--meta/recipes-devtools/strace/strace/0001-caps-abbrev.awk-fix-gawk-s-path.patch47
-rw-r--r--meta/recipes-devtools/strace/strace/0001-configure-Use-autoconf-macro-to-detect-largefile-sup.patch27
-rw-r--r--meta/recipes-devtools/strace/strace/0001-landlock-update-expected-string.patch67
-rw-r--r--meta/recipes-devtools/strace/strace/0002-tests-Replace-off64_t-with-off_t.patch52
-rw-r--r--meta/recipes-devtools/strace/strace/ptest-spacesave.patch2
-rwxr-xr-xmeta/recipes-devtools/strace/strace/run-ptest2
-rw-r--r--meta/recipes-devtools/strace/strace/skip-load.patch40
-rw-r--r--meta/recipes-devtools/strace/strace/update-gawk-paths.patch30
8 files changed, 128 insertions, 139 deletions
diff --git a/meta/recipes-devtools/strace/strace/0001-caps-abbrev.awk-fix-gawk-s-path.patch b/meta/recipes-devtools/strace/strace/0001-caps-abbrev.awk-fix-gawk-s-path.patch
deleted file mode 100644
index 235e803641..0000000000
--- a/meta/recipes-devtools/strace/strace/0001-caps-abbrev.awk-fix-gawk-s-path.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From 597cc206d982e7237eb93fdc33e8c4bb6bb2d796 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Thu, 9 Feb 2017 01:27:49 -0800
-Subject: [PATCH] caps-abbrev.awk: fix gawk's path
-
-It should be /usr/bin/gawk as other scripts use in this package.
-
-Upstream-Status: Pending
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
-
----
- tests-m32/caps-abbrev.awk | 2 +-
- tests-mx32/caps-abbrev.awk | 2 +-
- tests/caps-abbrev.awk | 2 +-
- 3 files changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/tests-m32/caps-abbrev.awk b/tests-m32/caps-abbrev.awk
-index c00023b..a56cd56 100644
---- a/tests-m32/caps-abbrev.awk
-+++ b/tests-m32/caps-abbrev.awk
-@@ -1,4 +1,4 @@
--#!/bin/gawk
-+#!/usr/bin/gawk
- #
- # This file is part of caps strace test.
- #
-diff --git a/tests-mx32/caps-abbrev.awk b/tests-mx32/caps-abbrev.awk
-index c00023b..a56cd56 100644
---- a/tests-mx32/caps-abbrev.awk
-+++ b/tests-mx32/caps-abbrev.awk
-@@ -1,4 +1,4 @@
--#!/bin/gawk
-+#!/usr/bin/gawk
- #
- # This file is part of caps strace test.
- #
-diff --git a/tests/caps-abbrev.awk b/tests/caps-abbrev.awk
-index c00023b..a56cd56 100644
---- a/tests/caps-abbrev.awk
-+++ b/tests/caps-abbrev.awk
-@@ -1,4 +1,4 @@
--#!/bin/gawk
-+#!/usr/bin/gawk
- #
- # This file is part of caps strace test.
- #
diff --git a/meta/recipes-devtools/strace/strace/0001-configure-Use-autoconf-macro-to-detect-largefile-sup.patch b/meta/recipes-devtools/strace/strace/0001-configure-Use-autoconf-macro-to-detect-largefile-sup.patch
new file mode 100644
index 0000000000..76ca7a76a8
--- /dev/null
+++ b/meta/recipes-devtools/strace/strace/0001-configure-Use-autoconf-macro-to-detect-largefile-sup.patch
@@ -0,0 +1,27 @@
+From 470399f3636c412b74f9daf6ae430b13c3126f02 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 15 Dec 2022 15:54:27 -0800
+Subject: [PATCH] configure: Use autoconf macro to detect largefile support
+
+Adds --enable-largefile/--disable-largefile configure knobs
+where default is to detect the support
+
+Upstream-Status: Submitted [https://github.com/strace/strace/pull/230]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ configure.ac | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/configure.ac b/configure.ac
+index 4797b42dd..7d57fb254 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -43,6 +43,8 @@ AC_PROG_INSTALL
+ AC_PROG_RANLIB
+ AC_PROG_LN_S
+
++AC_SYS_LARGEFILE
++
+ AC_USE_SYSTEM_EXTENSIONS
+ AX_CODE_COVERAGE
+
diff --git a/meta/recipes-devtools/strace/strace/0001-landlock-update-expected-string.patch b/meta/recipes-devtools/strace/strace/0001-landlock-update-expected-string.patch
deleted file mode 100644
index 9d67d68331..0000000000
--- a/meta/recipes-devtools/strace/strace/0001-landlock-update-expected-string.patch
+++ /dev/null
@@ -1,67 +0,0 @@
-From d0dae2fb30b907bc9bf70382f37c9e00207ae036 Mon Sep 17 00:00:00 2001
-From: Bruce Ashfield <bruce.ashfield@gmail.com>
-Date: Sat, 30 Apr 2022 01:09:42 -0400
-Subject: [PATCH] landlock: update expected string
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Kernel commit:
-
- commit 3d4b396a616d0d67bf95d6823ad1197f6247292e
- Author: Christian Brauner <christian.brauner@ubuntu.com>
- Date: Mon Oct 11 15:37:04 2021 +0200
-
- landlock: Use square brackets around "landlock-ruleset"
-
- commit aea0b9f2486da8497f35c7114b764bf55e17c7ea upstream.
-
- Make the name of the anon inode fd "[landlock-ruleset]" instead of
- "landlock-ruleset". This is minor but most anon inode fds already
- carry square brackets around their name:
-
- [eventfd]
- [eventpoll]
- [fanotify]
- [fscontext]
- [io_uring]
- [pidfd]
- [signalfd]
- [timerfd]
- [userfaultfd]
-
- For the sake of consistency lets do the same for the landlock-ruleset anon
- inode fd that comes with landlock. We did the same in
- 1cdc415f1083 ("uapi, fsopen: use square brackets around "fscontext" [ver #2]")
- for the new mount api.
-
- Cc: linux-security-module@vger.kernel.org
- Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
- Link: https://lore.kernel.org/r/20211011133704.1704369-1-brauner@kernel.org
- Cc: stable@vger.kernel.org
- Signed-off-by: Mickaël Salaün <mic@linux.microsoft.com>
- Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-
-Changed the format of the landlock tracing. We need to update the strace
-expected string to match.
-
-Upstream-Status: Submitted [https://lists.strace.io/pipermail/strace-devel/2022-April/011064.html]
-
-Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
----
- tests/landlock_create_ruleset-y.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/tests/landlock_create_ruleset-y.c b/tests/landlock_create_ruleset-y.c
-index a30966b..50e19c2 100644
---- a/tests/landlock_create_ruleset-y.c
-+++ b/tests/landlock_create_ruleset-y.c
-@@ -1,4 +1,4 @@
--#define FD_PATH "<anon_inode:landlock-ruleset>"
-+#define FD_PATH "<anon_inode:[landlock-ruleset]>"
- #define SKIP_IF_PROC_IS_UNAVAILABLE skip_if_unavailable("/proc/self/fd/")
-
- #include "landlock_create_ruleset.c"
---
-2.19.1
-
diff --git a/meta/recipes-devtools/strace/strace/0002-tests-Replace-off64_t-with-off_t.patch b/meta/recipes-devtools/strace/strace/0002-tests-Replace-off64_t-with-off_t.patch
new file mode 100644
index 0000000000..0cabdfe99f
--- /dev/null
+++ b/meta/recipes-devtools/strace/strace/0002-tests-Replace-off64_t-with-off_t.patch
@@ -0,0 +1,52 @@
+From 579b2ebe52d4b97f954e6188df2d07e137820075 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 15 Dec 2022 15:56:13 -0800
+Subject: [PATCH] tests: Replace off64_t with off_t
+
+when _FILE_OFFSET_BITS=64 then off_t is 64bit wide, this also fixes
+build on musl where off64_t is not available without _LARGEFILE64_SOURCE
+
+Upstream-Status: Submitted [https://github.com/strace/strace/pull/230]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ tests/readahead.c | 2 +-
+ tests/sync_file_range2.c | 4 ++--
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+--- a/tests/readahead.c
++++ b/tests/readahead.c
+@@ -42,7 +42,7 @@ static const int fds[] = {
+ 0x7fffffff,
+ };
+
+-static const off64_t offsets[] = {
++static const off_t offsets[] = {
+ -0x8000000000000000LL,
+ -0x5060708090a0b0c0LL,
+ -1LL,
+--- a/tests/sync_file_range2.c
++++ b/tests/sync_file_range2.c
+@@ -20,8 +20,8 @@ int
+ main(void)
+ {
+ const int fd = -1;
+- const off64_t offset = 0xdeadbeefbadc0ded;
+- const off64_t nbytes = 0xfacefeedcafef00d;
++ const off_t offset = 0xdeadbeefbadc0ded;
++ const off_t nbytes = 0xfacefeedcafef00d;
+ const unsigned int flags = -1;
+
+ int rc = sync_file_range(fd, offset, nbytes, flags);
+--- a/tests/sync_file_range.c
++++ b/tests/sync_file_range.c
+@@ -20,8 +20,8 @@ int
+ main(void)
+ {
+ const int fd = -1;
+- const off64_t offset = 0xdeadbeefbadc0dedULL;
+- const off64_t nbytes = 0xfacefeedcafef00dULL;
++ const off_t offset = 0xdeadbeefbadc0dedULL;
++ const off_t nbytes = 0xfacefeedcafef00dULL;
+ const unsigned int flags = -1;
+
+ int rc = sync_file_range(fd, offset, nbytes, flags);
diff --git a/meta/recipes-devtools/strace/strace/ptest-spacesave.patch b/meta/recipes-devtools/strace/strace/ptest-spacesave.patch
index c5d8ff9207..4e86ccadc5 100644
--- a/meta/recipes-devtools/strace/strace/ptest-spacesave.patch
+++ b/meta/recipes-devtools/strace/strace/ptest-spacesave.patch
@@ -22,7 +22,7 @@ index 3540204..5e1e7c9 100755
$hdr
. "\${srcdir=.}/init.sh"
run_strace_match_diff $arg0 $args
-+ rm -rf log exp
++ rm -rf log exp out
EOF
;;
diff --git a/meta/recipes-devtools/strace/strace/run-ptest b/meta/recipes-devtools/strace/strace/run-ptest
index 86daed9220..1224229e8f 100755
--- a/meta/recipes-devtools/strace/strace/run-ptest
+++ b/meta/recipes-devtools/strace/strace/run-ptest
@@ -3,7 +3,7 @@
set -u
export TIMEOUT_DURATION=240
-make -B -C tests -k test-suite.log
+make -j4 -B -C tests -k test-suite.log
res=$?
if [ $res -ne 0 ]; then
cat tests/test-suite.log
diff --git a/meta/recipes-devtools/strace/strace/skip-load.patch b/meta/recipes-devtools/strace/strace/skip-load.patch
index fa3ddb8ddc..b1acfda5d8 100644
--- a/meta/recipes-devtools/strace/strace/skip-load.patch
+++ b/meta/recipes-devtools/strace/strace/skip-load.patch
@@ -4,6 +4,12 @@ care about timing.
Upstream-Status: Inappropriate
Signed-off-by: Ross Burton <ross.burton@arm.com>
+---
+ tests/clock_nanosleep.gen.test | 1 +
+ tests/delay.test | 1 +
+ tests/strace-r.test | 1 +
+ 3 files changed, 3 insertions(+)
+
diff --git a/tests/clock_nanosleep.gen.test b/tests/clock_nanosleep.gen.test
index 7a6025b..f0e6dbb 100755
--- a/tests/clock_nanosleep.gen.test
@@ -15,41 +21,29 @@ index 7a6025b..f0e6dbb 100755
+skip_ "Test not reliable under load"
run_strace_match_diff -e trace=clock_nanosleep,clock_gettime
diff --git a/tests/delay.test b/tests/delay.test
-index f74e27f..328087e 100755
+index f74e27f..6172c04 100755
--- a/tests/delay.test
+++ b/tests/delay.test
-@@ -9,6 +9,8 @@
+@@ -8,6 +8,7 @@
+ # SPDX-License-Identifier: GPL-2.0-or-later
. "${srcdir=.}/init.sh"
-
+skip_ "Test not reliable under load"
-+
+
while read -r denter dexit denter_us dexit_us; do
[ -n "$denter" ] || continue
-
-diff --git a/tests/strace-T.test b/tests/strace-T.test
-index adca3e8..d4acfe9 100755
---- a/tests/strace-T.test
-+++ b/tests/strace-T.test
-@@ -9,6 +9,8 @@
-
- . "${srcdir=.}/init.sh"
-
-+skip_ "Test not reliable under load"
-+
- T_opt="${1:--T}"
-
- run_prog ../sleep 0
diff --git a/tests/strace-r.test b/tests/strace-r.test
-index 8299737..c360344 100755
+index 8299737..d89c7df 100755
--- a/tests/strace-r.test
+++ b/tests/strace-r.test
-@@ -9,6 +9,8 @@
+@@ -8,6 +8,7 @@
+ # SPDX-License-Identifier: GPL-2.0-or-later
. "${srcdir=.}/init.sh"
-
+skip_ "Test not reliable under load"
-+
+
r_opt="${1:--r}"
- run_prog ../sleep 0
+--
+2.25.1
+
diff --git a/meta/recipes-devtools/strace/strace/update-gawk-paths.patch b/meta/recipes-devtools/strace/strace/update-gawk-paths.patch
index 0c683496ae..a16ede95c2 100644
--- a/meta/recipes-devtools/strace/strace/update-gawk-paths.patch
+++ b/meta/recipes-devtools/strace/strace/update-gawk-paths.patch
@@ -125,3 +125,33 @@ index dce78f5..573d9ea 100644
#
# Copyright (c) 2014-2015 Dmitry V. Levin <ldv@strace.io>
# Copyright (c) 2016 Elvira Khabirova <lineprinter0@gmail.com>
+diff --git a/tests-m32/caps-abbrev.awk b/tests-m32/caps-abbrev.awk
+index c00023b..a56cd56 100644
+--- a/tests-m32/caps-abbrev.awk
++++ b/tests-m32/caps-abbrev.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # This file is part of caps strace test.
+ #
+diff --git a/tests-mx32/caps-abbrev.awk b/tests-mx32/caps-abbrev.awk
+index c00023b..a56cd56 100644
+--- a/tests-mx32/caps-abbrev.awk
++++ b/tests-mx32/caps-abbrev.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # This file is part of caps strace test.
+ #
+diff --git a/tests/caps-abbrev.awk b/tests/caps-abbrev.awk
+index c00023b..a56cd56 100644
+--- a/tests/caps-abbrev.awk
++++ b/tests/caps-abbrev.awk
+@@ -1,4 +1,4 @@
+-#!/bin/gawk
++#!/usr/bin/gawk
+ #
+ # This file is part of caps strace test.
+ #