Patchwork libgo patch committed: Update to weekly.2011-12-22

login
register
mail settings
Submitter Ian Taylor
Date Jan. 13, 2012, 11:03 p.m.
Message ID <mcrzkdrmci8.fsf@dhcp-172-18-216-180.mtv.corp.google.com>
Download mbox | patch
Permalink /patch/136035/
State New
Headers show

Comments

Ian Taylor - Jan. 13, 2012, 11:03 p.m.
Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:

> Ian Lance Taylor <iant@google.com> writes:
>
>> I have committed a patch to libgo to update it to the weekly.2011-12-22
>> release.  As usual I am not including all the changes here, only the
>> ones to files which are specific to gccgo.  Bootstrapped and ran Go
>> testsuite on x86_64-unknown-linux-gnu.  Committed to mainline.
>
> This also broke bootstrap on x86_64-unknown-linux-gnu (CentOS 5.5):
>
> /vol/gcc/src/hg/trunk/local/libgo/go/net/fd_linux.go:40:46: error: reference to undefined identifier 'syscall.EPOLL_CLOEXEC'

Thanks.  Fixed like so.  Bootstrapped on x86_64-unknown-linux-gnu.
Committed to mainline.

Ian
Rainer Orth - Jan. 18, 2012, 4:54 p.m.
Ian Lance Taylor <iant@google.com> writes:

>> This also broke bootstrap on x86_64-unknown-linux-gnu (CentOS 5.5):
>>
>> /vol/gcc/src/hg/trunk/local/libgo/go/net/fd_linux.go:40:46: error: reference to undefined identifier 'syscall.EPOLL_CLOEXEC'
>
> Thanks.  Fixed like so.  Bootstrapped on x86_64-unknown-linux-gnu.
> Committed to mainline.

Thanks.  Unfortunately, this is not enough: while the build finishes
now, all tests fail with

/var/gcc/regression/trunk/2.6.18-gcc-gas-gld/build/x86_64-unknown-linux-gnu/./libgo/.libs/libgo.so: undefined reference to `epoll_create1'
collect2: error: ld returned 1 exit status

	Rainer

Patch

diff -r 5623a1911326 libgo/mksysinfo.sh
--- a/libgo/mksysinfo.sh	Thu Jan 12 21:00:14 2012 -0800
+++ b/libgo/mksysinfo.sh	Fri Jan 13 15:01:55 2012 -0800
@@ -193,10 +193,13 @@ 
 # epoll constants.
 grep '^const _EPOLL' gen-sysinfo.go |
   sed -e 's/^\(const \)_\(EPOLL[^= ]*\)\(.*\)$/\1\2 = _\2/' >> ${OUT}
-# Make sure EPOLLRDHUP is defined.
+# Make sure EPOLLRDHUP and EPOLL_CLOEXEC are defined.
 if ! grep '^const EPOLLRDHUP' ${OUT} >/dev/null 2>&1; then
   echo "const EPOLLRDHUP = 0x2000" >> ${OUT}
 fi
+if ! grep '^const EPOLL_CLOEXEC' ${OUT} >/dev/null 2>&1; then
+  echo "const EPOLL_CLOEXEC = 02000000" >> ${OUT}
+fi
 
 # Ptrace constants.
 grep '^const _PTRACE' gen-sysinfo.go |