This patch to libgo's mksysinfo shell script defines the MADV_ constants use by the syscall.Madvise function. Bootstrapped and ran Go testsuite on x86_64-unknown-linux-gnu. Committed to mainline.
Ian
diff -r 2af6279334e7 libgo/mksysinfo.sh --- a/libgo/mksysinfo.sh Thu Mar 01 09:10:52 2012 -0800 +++ b/libgo/mksysinfo.sh Thu Mar 01 09:20:56 2012 -0800 @@ -191,6 +191,8 @@ sed -e 's/^\(const \)_\(PROT_[^= ]*\)\(.*\)$/\1\2 = _\2/' >> ${OUT} grep '^const _MAP_' gen-sysinfo.go | \ sed -e 's/^\(const \)_\(MAP_[^= ]*\)\(.*\)$/\1\2 = _\2/' >> ${OUT} +grep '^const _MADV_' gen-sysinfo.go | \ + sed -e 's/^\(const \)_\(MADV_[^= ]*\)\(.*\)$/\1\2 = _\2/' >> ${OUT} # Process status constants. grep '^const _W' gen-sysinfo.go |