Christian Weisgerber <na...@mips.inka.de> writes: > What, you thought the last few would resolve themselves by magic? > Here are the remaining ports that fail to build due to the new > -fno-common compiler default: > > lang/moarvm
I took the patch from upstream. An update would've worked too, but this is lower effort. OK? >From 71a2ee1c3316d5454b3ba60cb2678c4ec5e2642b Mon Sep 17 00:00:00 2001 From: Greg Steuck <g...@lenny.nest.cx> Date: Sat, 6 Mar 2021 07:44:29 -0800 Subject: [PATCH] Mark cmp_tc static to avoid linker errors in lang/moarvm --- lang/moarvm/Makefile | 2 +- .../patches/patch-src_6model_reprs_MVMHash_c | 16 ++++++++++++++++ .../patches/patch-src_6model_serialization_c | 16 ++++++++++++++++ 3 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 lang/moarvm/patches/patch-src_6model_reprs_MVMHash_c create mode 100644 lang/moarvm/patches/patch-src_6model_serialization_c diff --git a/lang/moarvm/Makefile b/lang/moarvm/Makefile index 01bec4c4e9b..b30d5fce17b 100644 --- a/lang/moarvm/Makefile +++ b/lang/moarvm/Makefile @@ -8,7 +8,7 @@ COMMENT = virtual machine for nqp/rakudo V = 2018.12 DISTNAME = MoarVM-$V PKGNAME = moarvm-$V -REVISION = 0 +REVISION = 1 SHARED_LIBS = moar 9.0 diff --git a/lang/moarvm/patches/patch-src_6model_reprs_MVMHash_c b/lang/moarvm/patches/patch-src_6model_reprs_MVMHash_c new file mode 100644 index 00000000000..f552a58ba31 --- /dev/null +++ b/lang/moarvm/patches/patch-src_6model_reprs_MVMHash_c @@ -0,0 +1,16 @@ +$OpenBSD$ + +https://github.com/MoarVM/MoarVM/commit/978480b288971e0a5f635456a29b35249cfc23e3 + +Index: src/6model/reprs/MVMHash.c +--- src/6model/reprs/MVMHash.c.orig ++++ src/6model/reprs/MVMHash.c +@@ -181,7 +181,7 @@ static void deserialize(MVMThreadContext *tc, MVMSTabl + } + + /* Serialize the representation. */ +-MVMThreadContext *cmp_tc; ++static MVMThreadContext *cmp_tc; + static int cmp_strings(const void *s1, const void *s2) { + return MVM_string_compare(cmp_tc, *(MVMString **)s1, *(MVMString **)s2); + } diff --git a/lang/moarvm/patches/patch-src_6model_serialization_c b/lang/moarvm/patches/patch-src_6model_serialization_c new file mode 100644 index 00000000000..cfbabe3b45f --- /dev/null +++ b/lang/moarvm/patches/patch-src_6model_serialization_c @@ -0,0 +1,16 @@ +$OpenBSD$ + +https://github.com/MoarVM/MoarVM/commit/978480b288971e0a5f635456a29b35249cfc23e3 + +Index: src/6model/serialization.c +--- src/6model/serialization.c.orig ++++ src/6model/serialization.c +@@ -507,7 +507,7 @@ static void write_array_str(MVMThreadContext *tc, MVMS + } + + /* Writes a hash where each key is a MVMString and each value a variant reference. */ +-MVMThreadContext *cmp_tc; ++static MVMThreadContext *cmp_tc; + static int cmp_strings(const void *s1, const void *s2) { + return MVM_string_compare(cmp_tc, *(MVMString **)s1, *(MVMString **)s2); + } -- 2.30.1