[4.7, go] Backport godump.c patch

Rainer Orth ro@CeBiTec.Uni-Bielefeld.DE
Thu Mar 14 16:54:00 GMT 2013


Since Solaris 11.1, libgo compilation was failing with

sysinfo.go:676:267: error: use of undefined type '_ns_postinit_s'

sysinfo.go had

type _netstack struct { netstack_u struct { nu_modules [20+1]*byte; }; netstack_m_state [20+1]uint32; netstack_lock _kmutex_t; netstack_next *_netstack; netstack_stackid int32; netstack_numzones int32; netstack_refcnt int32; netstack_flags int32; netstack_postinit *_ns_postinit_s; }
const _sizeof_netstack = 200
type _netstack_t struct { netstack_u struct { nu_modules [20+1]*byte; }; netstack_m_state [20+1]uint32; netstack_lock _kmutex_t; netstack_next *_netstack; netstack_stackid int32; netstack_numzones int32; netstack_refcnt int32; netstack_flags int32; netstack_postinit *_ns_postinit_s; }

but no definition of _ns_postinit_s.  For a long time, I had a local
patch in my tree to just omit the related _netstack, _netstack_t, and
_netstack_registry types in mksysinfo.sh to avoid this.  When I tried
without this patch on mainline, I noticed that the build worked just
fine, while on the 4.7 branch it still fails.

I found that this patch

2012-12-04  Ian Lance Taylor  <iant@google.com>

	* godump.c (find_dummy_types): Output a dummy type if we couldn't
	output the real type.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: godump.udif
Type: text/x-patch
Size: 846 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20130314/87dca1ca/attachment.bin>
-------------- next part --------------

fixes the problem, so I'd like to backport it.

i386-pc-solaris2.11 bootstrap still running, ok for 4.7 branch if it
passes?

One additional question: the patch updates the copyright date by adding
2012.  How do we hande this for a backport?  Keep it that way or update
for 2013 instead?

Thanks.
        Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University


More information about the Gcc-patches mailing list