summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
Diffstat (limited to 'meta')
-rw-r--r--meta/recipes-extended/ltp/ltp/0001-nm01-Remove-prefix-zeros-of-the-addresses-output-by-.patch43
-rw-r--r--meta/recipes-extended/ltp/ltp_20190930.bb1
2 files changed, 44 insertions, 0 deletions
diff --git a/meta/recipes-extended/ltp/ltp/0001-nm01-Remove-prefix-zeros-of-the-addresses-output-by-.patch b/meta/recipes-extended/ltp/ltp/0001-nm01-Remove-prefix-zeros-of-the-addresses-output-by-.patch
new file mode 100644
index 0000000000..fe5e7314e0
--- /dev/null
+++ b/meta/recipes-extended/ltp/ltp/0001-nm01-Remove-prefix-zeros-of-the-addresses-output-by-.patch
@@ -0,0 +1,43 @@
1From 59cb0dd9f8e65b2d398fcaf4d163cbc8e1d0ae45 Mon Sep 17 00:00:00 2001
2From: He Zhe <zhe.he@windriver.com>
3Date: Tue, 31 Dec 2019 15:02:48 +0800
4Subject: [PATCH] nm01: Remove prefix zeros of the addresses output by nm
5 before comparing
6
7The latest nm v2.33.1 outputs symbols addresses without prefix zeros
8for "nm -f posix", which causes the following error.
9nm01 5 TFAIL: Got wrong format with -f bsd
10
11Let's remove the prefix zeros before comparing.
12
13Upstream-Status: Backport [59cb0dd9f8e65b2d398fcaf4d163cbc8e1d0ae45]
14
15Signed-off-by: He Zhe <zhe.he@windriver.com>
16Reviewed-by: Li Wang <liwang@redhat.com>
17Reviewed-by: Petr Vorel <pvorel@suse.cz>
18Tested-by: Petr Vorel <pvorel@suse.cz>
19---
20 testcases/commands/nm/nm01.sh | 7 +++++--
21 1 file changed, 5 insertions(+), 2 deletions(-)
22
23diff --git a/testcases/commands/nm/nm01.sh b/testcases/commands/nm/nm01.sh
24index 30c41bd..fd9d3d9 100755
25--- a/testcases/commands/nm/nm01.sh
26+++ b/testcases/commands/nm/nm01.sh
27@@ -84,8 +84,11 @@ test5()
28 EXPECT_PASS $NM -f bsd $TST_DATAROOT/f1 \> nm_bsd.out
29 EXPECT_PASS $NM -f posix $TST_DATAROOT/f1 \> nm_posix.out
30
31- ROD awk '{print $3 $2 $1}' nm_bsd.out \> nm1.out
32- ROD awk '{print $1 $2 $3}' nm_posix.out \> nm2.out
33+ ROD awk '{print gensub(/\y(0+)([0-9a-fA-F]+)\y/, "\\2", "g")}' nm_bsd.out \> trimmed_nm_bsd.out
34+ ROD awk '{print gensub(/\y(0+)([0-9a-fA-F]+)\y/, "\\2", "g")}' nm_posix.out \> trimmed_nm_posix.out
35+
36+ ROD awk '{print $3 $2 $1}' trimmed_nm_bsd.out \> nm1.out
37+ ROD awk '{print $1 $2 $3}' trimmed_nm_posix.out \> nm2.out
38
39 if diff nm1.out nm2.out > /dev/null; then
40 tst_res TPASS "Got BSD format with -f bsd"
41--
422.7.4
43
diff --git a/meta/recipes-extended/ltp/ltp_20190930.bb b/meta/recipes-extended/ltp/ltp_20190930.bb
index e56bb575d2..2853b1c819 100644
--- a/meta/recipes-extended/ltp/ltp_20190930.bb
+++ b/meta/recipes-extended/ltp/ltp_20190930.bb
@@ -41,6 +41,7 @@ SRC_URI = "git://github.com/linux-test-project/ltp.git \
41 file://0001-mkswap01.sh-Add-udevadm-trigger-before-swap-verifica.patch \ 41 file://0001-mkswap01.sh-Add-udevadm-trigger-before-swap-verifica.patch \
42 file://0001-testcases-fix-an-absent-format-string-issue.patch \ 42 file://0001-testcases-fix-an-absent-format-string-issue.patch \
43 file://0001-Add-more-musl-exclusions.patch \ 43 file://0001-Add-more-musl-exclusions.patch \
44 file://0001-nm01-Remove-prefix-zeros-of-the-addresses-output-by-.patch \
44 " 45 "
45 46
46S = "${WORKDIR}/git" 47S = "${WORKDIR}/git"