aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKevin Daudt <kdaudt@alpinelinux.org>2021-01-23 18:03:27 +0000
committerKevin Daudt <kdaudt@alpinelinux.org>2021-01-23 18:03:27 +0000
commit9d9cf279f6a3fa5413fd36fb452b9036eff08b61 (patch)
treec962258345a941f1271399a2d4aa1956023b8c0d
parent64dc19201a9fb7e0512edba612b1691f14b6a23f (diff)
downloadaports-9d9cf279f6a3fa5413fd36fb452b9036eff08b61.tar.gz
aports-9d9cf279f6a3fa5413fd36fb452b9036eff08b61.tar.bz2
aports-9d9cf279f6a3fa5413fd36fb452b9036eff08b61.tar.xz
main/m4: fix realpath test
realpath is not required to normalize `//` into `/`, but the test assumes so. See #12295 See #12348
-rw-r--r--main/m4/APKBUILD6
-rw-r--r--main/m4/musl-realpath.patch23
2 files changed, 27 insertions, 2 deletions
diff --git a/main/m4/APKBUILD b/main/m4/APKBUILD
index 4b9fdf0472..24ff6e11b6 100644
--- a/main/m4/APKBUILD
+++ b/main/m4/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=m4
pkgver=1.4.18
-pkgrel=1
+pkgrel=2
pkgdesc="GNU macro processor"
url="https://www.gnu.org/software/m4"
depends=
@@ -13,6 +13,7 @@ subpackages="m4-doc"
source="https://ftp.gnu.org/gnu/m4/$pkgname-$pkgver.tar.gz
disable-mbrtowc-test.patch
localename-test-fix.patch
+ musl-realpath.patch
"
build() {
@@ -38,4 +39,5 @@ package() {
sha512sums="29254dd4267a093e8d9da3a26df8b02564044cdb4506be539ec1aff4e5d406477bcf32f5e813c840f3aec77293bfe2cdde18f6a21724a7e0bfff646ec88b74ae m4-1.4.18.tar.gz
78bf099c96fcec8c9cebd4e34f0d7c942e99da2ec238baa9464f8443580edb0565e9026c433ee54fb564304ec8e7e90766e19474472e57b48e567fd7b356777e disable-mbrtowc-test.patch
-fac0cb58e698996284a222c4da340f92689d6db98f1fbab6e61e1c5f2d90122660296f8e5c60c94169413e3e2ee632c6264f12b98e5d3a1e1aae145a2d4aac45 localename-test-fix.patch"
+fac0cb58e698996284a222c4da340f92689d6db98f1fbab6e61e1c5f2d90122660296f8e5c60c94169413e3e2ee632c6264f12b98e5d3a1e1aae145a2d4aac45 localename-test-fix.patch
+cc86f883eac255301615278af9ee172e13bbe48ce0ac318ab6c325ab2406000ceb10c5360868111210eb784ea028ef93cdfe12b77e17fa0066786957c347fd71 musl-realpath.patch"
diff --git a/main/m4/musl-realpath.patch b/main/m4/musl-realpath.patch
new file mode 100644
index 0000000000..22f15ff844
--- /dev/null
+++ b/main/m4/musl-realpath.patch
@@ -0,0 +1,23 @@
+https://gitlab.alpinelinux.org/alpine/aports/-/issues/12295
+
+----
+test-canonicalize.c:339: assertion 'strcmp (result1, "/") == 0' failed
+Aborted (core dumped)
+FAIL test-canonicalize (exit status: 134)
+----
+
+diff --git a/tests/test-canonicalize-lgpl.c b/tests/test-canonicalize-lgpl.c
+index ff82981..17842e8 100644
+--- a/tests/test-canonicalize-lgpl.c
++++ b/tests/test-canonicalize-lgpl.c
+@@ -196,8 +196,8 @@ main (void)
+ #ifndef __MVS__
+ if (SAME_INODE (st1, st2))
+ {
+- ASSERT (strcmp (result1, "/") == 0);
+- ASSERT (strcmp (result2, "/") == 0);
++ ASSERT (strcmp (result1, "/") == 0 || strcmp (result1, "//") == 0);
++ ASSERT (strcmp (result2, "/") == 0 || strcmp (result2, "//") == 0);
+ }
+ else
+ #endif