summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2023-04-18 23:08:22 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-04-20 11:56:06 +0100
commit6fedd43f9631c63d6389d9dc7112d6db1877e582 (patch)
treeba41087119a07cfb67e961b4506ea230c926cee8
parentef16919e98108724ede5ad5d79e3cbab1918d6d5 (diff)
downloadpoky-6fedd43f9631c63d6389d9dc7112d6db1877e582.tar.gz
apt-util: Fix ptest on musl
(From OE-Core rev: 45a8bb6e4676899d40525e7d5ad1c1ddefee3185) Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/recipes-support/apr/apr-util/0001-test_transformation-Check-if-transform-is-supported-.patch37
-rw-r--r--meta/recipes-support/apr/apr-util_1.6.3.bb1
2 files changed, 38 insertions, 0 deletions
diff --git a/meta/recipes-support/apr/apr-util/0001-test_transformation-Check-if-transform-is-supported-.patch b/meta/recipes-support/apr/apr-util/0001-test_transformation-Check-if-transform-is-supported-.patch
new file mode 100644
index 0000000000..261b78736f
--- /dev/null
+++ b/meta/recipes-support/apr/apr-util/0001-test_transformation-Check-if-transform-is-supported-.patch
@@ -0,0 +1,37 @@
1From 3a97f58cfb40fc1911bbfd067e8457a472613d75 Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Tue, 18 Apr 2023 22:58:00 -0700
4Subject: [PATCH] test_transformation: Check if transform is supported before
5 using it
6
7This helps in excluding these tests on systems where these are not
8available e.g. musl
9
10Upstream-Status: Submitted [https://bz.apache.org/bugzilla/show_bug.cgi?id=66570]
11Signed-off-by: Khem Raj <raj.khem@gmail.com>
12---
13 test/testxlate.c | 8 ++++++--
14 1 file changed, 6 insertions(+), 2 deletions(-)
15
16diff --git a/test/testxlate.c b/test/testxlate.c
17index 6981eff..de00fa4 100644
18--- a/test/testxlate.c
19+++ b/test/testxlate.c
20@@ -116,8 +116,12 @@ static void test_transformation(abts_case *tc, void *data)
21 }
22
23 /* 4. Transformation using charset aliases */
24- one_test(tc, "UTF-8", "UTF-7", test_utf8, test_utf7, p);
25- one_test(tc, "UTF-7", "UTF-8", test_utf7, test_utf8, p);
26+ if (is_transform_supported(tc, "UTF-8", "UTF-7", p)) {
27+ one_test(tc, "UTF-8", "UTF-7", test_utf8, test_utf7, p);
28+ }
29+ if (is_transform_supported(tc, "UTF-7", "UTF-8", p)) {
30+ one_test(tc, "UTF-7", "UTF-8", test_utf7, test_utf8, p);
31+ }
32 }
33
34 #endif /* APR_HAS_XLATE */
35--
362.40.0
37
diff --git a/meta/recipes-support/apr/apr-util_1.6.3.bb b/meta/recipes-support/apr/apr-util_1.6.3.bb
index 7c6fcc699b..1371e262dd 100644
--- a/meta/recipes-support/apr/apr-util_1.6.3.bb
+++ b/meta/recipes-support/apr/apr-util_1.6.3.bb
@@ -12,6 +12,7 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=158aa0b1efe0c12f23d4b007ddb9a5db \
12SRC_URI = "${APACHE_MIRROR}/apr/${BPN}-${PV}.tar.gz \ 12SRC_URI = "${APACHE_MIRROR}/apr/${BPN}-${PV}.tar.gz \
13 file://configfix.patch \ 13 file://configfix.patch \
14 file://configure_fixes.patch \ 14 file://configure_fixes.patch \
15 file://0001-test_transformation-Check-if-transform-is-supported-.patch \
15 file://run-ptest \ 16 file://run-ptest \
16 " 17 "
17 18