From f30d20915d19b459d7b0f328860cc84601f11294 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Fri, 14 Jul 2017 22:25:26 +0000 Subject: [PATCH] libgo: don't copy semt into runtime.inc https://gcc.gnu.org/PR81449 reports a problem with the definition semt in runtime.inc on some systems. Since the C code in libgo/runtime doesn't need semt, just don't copy it into runtime.inc. Reviewed-on: https://go-review.googlesource.com/48593 From-SVN: r250217 --- gcc/go/gofrontend/MERGE | 2 +- libgo/Makefile.am | 4 +++- libgo/Makefile.in | 4 +++- libgo/configure | 2 +- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE index 5c5602188da..524aca72fd7 100644 --- a/gcc/go/gofrontend/MERGE +++ b/gcc/go/gofrontend/MERGE @@ -1,4 +1,4 @@ -a77b1091fa83cfaf200e6dad26e92e42483bae43 +2ae6bf76f97f7d4c63a1f0ad0683b9ba62baaf06 The first line of this file holds the git revision number of the last merge done from the gofrontend repository. diff --git a/libgo/Makefile.am b/libgo/Makefile.am index 0f9881ffaa4..b94ac0c526c 100644 --- a/libgo/Makefile.am +++ b/libgo/Makefile.am @@ -543,6 +543,8 @@ s-sigtab: $(srcdir)/mksigtab.sh gen-sysinfo.go # _Complex_lock and _Reader_lock are Go translations of some AIX system # types and should not be exported back to C +# semt is a Go translation of the C type sem_t; it fails to convert on +# some systems and need not be exported back to C. # sigset conflicts with system type sigset on AIX, so we need to rename it runtime.inc: s-runtime-inc; @true s-runtime-inc: runtime.lo Makefile @@ -551,7 +553,7 @@ s-runtime-inc: runtime.lo Makefile for pattern in '_[GP][a-z]' _Max _Lock _Sig _Trace _MHeap _Num; do \ grep "#define $$pattern" runtime.inc.tmp >> runtime.inc.tmp2; \ done - for TYPE in _Complex_lock _Reader_lock; do \ + for TYPE in _Complex_lock _Reader_lock semt; do \ sed -e '/struct '$${TYPE}' {/,/^}/s/^.*$$//' runtime.inc.tmp2 > runtime.inc.tmp3; \ mv runtime.inc.tmp3 runtime.inc.tmp2; \ done diff --git a/libgo/Makefile.in b/libgo/Makefile.in index 2452f967252..ba0a923c40e 100644 --- a/libgo/Makefile.in +++ b/libgo/Makefile.in @@ -3093,6 +3093,8 @@ s-sigtab: $(srcdir)/mksigtab.sh gen-sysinfo.go # _Complex_lock and _Reader_lock are Go translations of some AIX system # types and should not be exported back to C +# semt is a Go translation of the C type sem_t; it fails to convert on +# some systems and need not be exported back to C. # sigset conflicts with system type sigset on AIX, so we need to rename it runtime.inc: s-runtime-inc; @true s-runtime-inc: runtime.lo Makefile @@ -3101,7 +3103,7 @@ s-runtime-inc: runtime.lo Makefile for pattern in '_[GP][a-z]' _Max _Lock _Sig _Trace _MHeap _Num; do \ grep "#define $$pattern" runtime.inc.tmp >> runtime.inc.tmp2; \ done - for TYPE in _Complex_lock _Reader_lock; do \ + for TYPE in _Complex_lock _Reader_lock semt; do \ sed -e '/struct '$${TYPE}' {/,/^}/s/^.*$$//' runtime.inc.tmp2 > runtime.inc.tmp3; \ mv runtime.inc.tmp3 runtime.inc.tmp2; \ done diff --git a/libgo/configure b/libgo/configure index 48feebdb10d..cfdcd7409c5 100755 --- a/libgo/configure +++ b/libgo/configure @@ -13773,7 +13773,7 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext esac case "${host}" in mips*el-*-*) - GOARCH="${GOARCH}le" + GOARCH="${GOARCH}le" ;; *) GOARCH_BIGENDIAN=1 -- 2.30.2