diff mbox

[gofrontend-dev,1/4] Gccgo port to s390[x] -- part II

Message ID 20141106153421.GA9829@linux.vnet.ibm.com
State New
Headers show

Commit Message

Dominik Vogt Nov. 6, 2014, 3:34 p.m. UTC
On Thu, Nov 06, 2014 at 03:02:13PM +0100, Rainer Orth wrote:
> Ian Taylor <iant@golang.org> writes:
> > Committed patch 0001 with various formatting fixes, as attached.
> 
> Unfortunately, the mksysinfo.sh part broke Solaris bootstrap: there's no
> type _ucred in gen-sysinfo.go, so the grep in upcase_fields fails.  Due
> to the use of set -e, the whole script aborts.

The attached patch fixes the problem.

> It seems something changed again in godump within the last few days,
> making this patch
> 
> 	https://gcc.gnu.org/ml/gcc-patches/2014-11/msg00080.html
> 
> unnecessary.

Yes.  :-)

Ciao

Dominik ^_^  ^_^

Comments

Ian Lance Taylor Nov. 6, 2014, 4:44 p.m. UTC | #1
On Thu, Nov 6, 2014 at 7:34 AM, Dominik Vogt <vogt@linux.vnet.ibm.com> wrote:
> On Thu, Nov 06, 2014 at 03:02:13PM +0100, Rainer Orth wrote:
>> Ian Taylor <iant@golang.org> writes:
>> > Committed patch 0001 with various formatting fixes, as attached.
>>
>> Unfortunately, the mksysinfo.sh part broke Solaris bootstrap: there's no
>> type _ucred in gen-sysinfo.go, so the grep in upcase_fields fails.  Due
>> to the use of set -e, the whole script aborts.
>
> The attached patch fixes the problem.

Thanks.  Committed.

Ian
diff mbox

Patch

From 064f524f1d24d60a2d70e9b3436d1bf2fef6c9ca Mon Sep 17 00:00:00 2001
From: Dominik Vogt <vogt@linux.vnet.ibm.com>
Date: Thu, 6 Nov 2014 16:31:39 +0100
Subject: [PATCH] libgo: mksysinfo.sh tolerates missing structures.

---
 libgo/mksysinfo.sh | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libgo/mksysinfo.sh b/libgo/mksysinfo.sh
index a174e64..ddfa8bb 100755
--- a/libgo/mksysinfo.sh
+++ b/libgo/mksysinfo.sh
@@ -475,9 +475,9 @@  if test "$regs" == ""; then
   regs=`grep '^type __user_regs_struct struct' gen-sysinfo.go || true`
   if test "$regs" != ""; then
     # Substructures of __user_regs_struct on s390
-    upcase_fields "__user_psw_struct" "PtracePsw" >> ${OUT}
-    upcase_fields "__user_fpregs_struct" "PtraceFpregs" >> ${OUT}
-    upcase_fields "__user_per_struct" "PtracePer" >> ${OUT}
+    upcase_fields "__user_psw_struct" "PtracePsw" >> ${OUT} || true
+    upcase_fields "__user_fpregs_struct" "PtraceFpregs" >> ${OUT} || true
+    upcase_fields "__user_per_struct" "PtracePer" >> ${OUT} || true
   fi
 fi
 if test "$regs" != ""; then
@@ -746,7 +746,7 @@  grep '^const _SCM_' gen-sysinfo.go | \
   sed -e 's/^\(const \)_\(SCM_[^= ]*\)\(.*\)$/\1\2 = _\2/' >> ${OUT}
 
 # The ucred struct.
-upcase_fields "_ucred" "Ucred" >> ${OUT}
+upcase_fields "_ucred" "Ucred" >> ${OUT} || true
 
 # The ip_mreq struct.
 grep '^type _ip_mreq ' gen-sysinfo.go | \
-- 
1.8.4.2