libgo: handle stat st_atim32 field and SYS_SECCOMP

Patches for musl support, from Sören Tempel.

Fixes PR go/105225

Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/415294
This commit is contained in:
Ian Lance Taylor
2022-06-29 15:32:04 -07:00
parent 4c233cabbe
commit 762fd5e554
2 changed files with 3 additions and 2 deletions

View File

@ -1,4 +1,4 @@
63782f8a318e9eebfdc983f171a920c7a937c759 548720bca6bff21ebc9aba22249d9ce45bbd90c7
The first line of this file holds the git revision number of the last The first line of this file holds the git revision number of the last
merge done from the gofrontend repository. merge done from the gofrontend repository.

View File

@ -127,6 +127,7 @@ fi
# The syscall numbers. We force the names to upper case. # The syscall numbers. We force the names to upper case.
grep '^const _SYS_' gen-sysinfo.go | \ grep '^const _SYS_' gen-sysinfo.go | \
grep -v '^const _SYS_SECCOMP = ' | \
sed -e 's/const _\(SYS_[^= ]*\).*$/\1/' | \ sed -e 's/const _\(SYS_[^= ]*\).*$/\1/' | \
while read sys; do while read sys; do
sup=`echo $sys | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ` sup=`echo $sys | tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ`
@ -506,7 +507,7 @@ fi
# For historical reasons Go uses the suffix "timespec" instead of "tim" for # For historical reasons Go uses the suffix "timespec" instead of "tim" for
# stat_t's time fields on NetBSD. # stat_t's time fields on NetBSD.
st_times='-e s/st_atim/Atim/ -e s/st_mtim/Mtim/ -e s/st_ctim/Ctim/' st_times='-e s/st_atim/Atim/g -e s/st_mtim/Mtim/g -e s/st_ctim/Ctim/g'
if test "${GOOS}" = "netbsd"; then if test "${GOOS}" = "netbsd"; then
st_times='-e s/st_atim/Atimespec/ -e s/st_mtim/Mtimespec/ -e s/st_ctim/Ctimespec/' st_times='-e s/st_atim/Atimespec/ -e s/st_mtim/Mtimespec/ -e s/st_ctim/Ctimespec/'
fi fi