summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--system/musl/APKBUILD4
-rw-r--r--system/musl/ppc64-regs.patch45
2 files changed, 48 insertions, 1 deletions
diff --git a/system/musl/APKBUILD b/system/musl/APKBUILD
index 1ab117c16..d35060fb4 100644
--- a/system/musl/APKBUILD
+++ b/system/musl/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=musl
pkgver=1.1.21
-pkgrel=1
+pkgrel=2
pkgdesc="System library (libc) implementation"
url="http://www.musl-libc.org/"
arch="all"
@@ -27,6 +27,7 @@ source="http://www.musl-libc.org/releases/musl-$pkgver.tar.gz
handle-aux-at_base.patch
fgetspent_r.patch
gettext-preserve-errno.patch
+ ppc64-regs.patch
ldconfig
getent.c
@@ -125,6 +126,7 @@ sha512sums="fa6c4cc012626c5e517e0e10926fc845e3aa5f863ffaceeb38ac5b9ce0af631a37f6
6a7ff16d95b5d1be77e0a0fbb245491817db192176496a57b22ab037637d97a185ea0b0d19da687da66c2a2f5578e4343d230f399d49fe377d8f008410974238 handle-aux-at_base.patch
ded41235148930f8cf781538f7d63ecb0c65ea4e8ce792565f3649ee2523592a76b2a166785f0b145fc79f5852fd1fb1729a7a09110b3b8f85cba3912e790807 fgetspent_r.patch
db180e437b8b7582e4d2baf06b592b88a9f6e5a8f18b7afa81d7a707240a774273778f8fec1c5cbea2a137e00cca49ff08fe762c871be20c70b50104b7e8e1e1 gettext-preserve-errno.patch
+8d90a4bbec151f696bee30ed7275d8eb88b5c5ae7027d1dac963a950b0717b1e5149d6718c441bc9ee103b57899a9835a93f8373448b5887b52a24937bfd0af9 ppc64-regs.patch
cce2f1eeb61e55674469c26871a573cce61d739c3defe9c8f56f2b774f6ba5435849ad542a6714120efddc98c297098e9c98a1a424ac593df2243d4aa479f9a9 ldconfig
378d70e65bcc65bb4e1415354cecfa54b0c1146dfb24474b69e418cdbf7ad730472cd09f6f103e1c99ba6c324c9560bccdf287f5889bbc3ef0bdf0e08da47413 getent.c
9d42d66fb1facce2b85dad919be5be819ee290bd26ca2db00982b2f8e055a0196290a008711cbe2b18ec9eee8d2270e3b3a4692c5a1b807013baa5c2b70a2bbf iconv.c"
diff --git a/system/musl/ppc64-regs.patch b/system/musl/ppc64-regs.patch
new file mode 100644
index 000000000..4deb979ba
--- /dev/null
+++ b/system/musl/ppc64-regs.patch
@@ -0,0 +1,45 @@
+From ea183d9b727ac7e3ccfdcb89242566857d7182c8 Mon Sep 17 00:00:00 2001
+From: "A. Wilcox" <AWilcox@Wilcox-Tech.com>
+Date: Tue, 12 Feb 2019 09:31:34 -0600
+Subject: [PATCH] powerpc64: use a type for mcontext_t regs field
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+GCC Go dereferences `regs` for `nip`. Without this change, compilation
+fails with the following message:
+
+../../../libgo/runtime/go-signal.c: In function ‘getSiginfo’:
+../../../libgo/runtime/go-signal.c:225:56: warning: dereferencing ‘void *’ pointer
+ ret.sigpc = ((ucontext_t*)(context))->uc_mcontext.regs->nip;
+ ^~
+../../../libgo/runtime/go-signal.c:225:56: error: request for member ‘nip’ in something not a structure or union
+---
+ arch/powerpc64/bits/signal.h | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/arch/powerpc64/bits/signal.h b/arch/powerpc64/bits/signal.h
+index 34693a68..6736c69a 100644
+--- a/arch/powerpc64/bits/signal.h
++++ b/arch/powerpc64/bits/signal.h
+@@ -8,6 +8,8 @@
+
+ #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
+
++#include <bits/user.h>
++
+ typedef unsigned long greg_t, gregset_t[48];
+
+ typedef struct {
+@@ -29,7 +31,7 @@ typedef struct sigcontext {
+ int _pad0;
+ unsigned long handler;
+ unsigned long oldmask;
+- void *regs;
++ struct pt_regs *regs;
+ gregset_t gp_regs;
+ fpregset_t fp_regs;
+ vrregset_t *v_regs;
+--
+2.19.2
+