From ed963c908d11fc6ffd17c9e9bc615cc134af6046 Mon Sep 17 00:00:00 2001 From: Mikio Hara Date: Wed, 30 Jul 2014 09:47:39 +0900 Subject: [PATCH] undo CL 102610045 / 7244ce3ae9db MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit preparing for the syscall package freeze. ««« original CL description syscall: regenerate z-files for darwin Updates z-files from 10.7 kernel-based to 10.9 kernel-based. LGTM=iant R=golang-codereviews, bradfitz, iant CC=golang-codereviews https://golang.org/cl/102610045 »»» LGTM=r R=r CC=golang-codereviews https://golang.org/cl/114530044 --- api/except.txt | 24 ---- src/pkg/syscall/mkerrors.sh | 30 ---- src/pkg/syscall/mksysnum_darwin.pl | 28 +--- src/pkg/syscall/types_darwin.go | 9 +- src/pkg/syscall/zerrors_darwin_386.go | 173 +----------------------- src/pkg/syscall/zerrors_darwin_amd64.go | 173 +----------------------- src/pkg/syscall/zsysnum_darwin_386.go | 21 +-- src/pkg/syscall/zsysnum_darwin_amd64.go | 21 +-- 8 files changed, 15 insertions(+), 464 deletions(-) diff --git a/api/except.txt b/api/except.txt index 99f4397742..1a8296635d 100644 --- a/api/except.txt +++ b/api/except.txt @@ -327,27 +327,3 @@ pkg syscall (netbsd-arm), const SizeofIfData = 132 pkg syscall (netbsd-arm), type IfMsghdr struct, Pad_cgo_1 [4]uint8 pkg syscall (netbsd-arm-cgo), const SizeofIfData = 132 pkg syscall (netbsd-arm-cgo), type IfMsghdr struct, Pad_cgo_1 [4]uint8 -pkg syscall (darwin-386), const AF_MAX = 38 -pkg syscall (darwin-386), const ELAST = 105 -pkg syscall (darwin-386), const EVFILT_SYSCOUNT = 12 -pkg syscall (darwin-386), const EVFILT_THREADMARKER = 12 -pkg syscall (darwin-386), const IPV6_FRAGTTL = 120 -pkg syscall (darwin-386), const SYS_MAXSYSCALL = 439 -pkg syscall (darwin-386-cgo), const AF_MAX = 38 -pkg syscall (darwin-386-cgo), const ELAST = 105 -pkg syscall (darwin-386-cgo), const EVFILT_SYSCOUNT = 12 -pkg syscall (darwin-386-cgo), const EVFILT_THREADMARKER = 12 -pkg syscall (darwin-386-cgo), const IPV6_FRAGTTL = 120 -pkg syscall (darwin-386-cgo), const SYS_MAXSYSCALL = 439 -pkg syscall (darwin-amd64), const AF_MAX = 38 -pkg syscall (darwin-amd64), const ELAST = 105 -pkg syscall (darwin-amd64), const EVFILT_SYSCOUNT = 12 -pkg syscall (darwin-amd64), const EVFILT_THREADMARKER = 12 -pkg syscall (darwin-amd64), const IPV6_FRAGTTL = 120 -pkg syscall (darwin-amd64), const SYS_MAXSYSCALL = 439 -pkg syscall (darwin-amd64-cgo), const AF_MAX = 38 -pkg syscall (darwin-amd64-cgo), const ELAST = 105 -pkg syscall (darwin-amd64-cgo), const EVFILT_SYSCOUNT = 12 -pkg syscall (darwin-amd64-cgo), const EVFILT_THREADMARKER = 12 -pkg syscall (darwin-amd64-cgo), const IPV6_FRAGTTL = 120 -pkg syscall (darwin-amd64-cgo), const SYS_MAXSYSCALL = 439 diff --git a/src/pkg/syscall/mkerrors.sh b/src/pkg/syscall/mkerrors.sh index 1515cfded9..e86ec1107a 100755 --- a/src/pkg/syscall/mkerrors.sh +++ b/src/pkg/syscall/mkerrors.sh @@ -35,36 +35,6 @@ includes_Darwin=' #include #include #include - -// We keep some constants not supported in OS X Mavericks and beyond -// for the promise of compatibility. -#ifndef F_MARKDEPENDENCY -#define F_MARKDEPENDENCY 0x3c -#endif -#ifndef F_READBOOTSTRAP -#define F_READBOOTSTRAP 0x2e -#endif -#ifndef F_WRITEBOOTSTRAP -#define F_WRITEBOOTSTRAP 0x2f -#endif -#ifndef NOTE_RESOURCEEND -#define NOTE_RESOURCEEND 0x2000000 -#endif -#ifndef SO_RESTRICTIONS -#define SO_RESTRICTIONS 0x1081 -#endif -#ifndef SO_RESTRICT_DENYIN -#define SO_RESTRICT_DENYIN 0x1 -#endif -#ifndef SO_RESTRICT_DENYOUT -#define SO_RESTRICT_DENYOUT 0x2 -#endif -#ifndef SO_RESTRICT_DENYSET -#define SO_RESTRICT_DENYSET 0x80000000 -#endif -#ifndef TCP_MINMSSOVERLOAD -#define TCP_MINMSSOVERLOAD 0x3e8 -#endif ' includes_DragonFly=' diff --git a/src/pkg/syscall/mksysnum_darwin.pl b/src/pkg/syscall/mksysnum_darwin.pl index 30adae0f4e..e3470435d2 100755 --- a/src/pkg/syscall/mksysnum_darwin.pl +++ b/src/pkg/syscall/mksysnum_darwin.pl @@ -18,41 +18,15 @@ package syscall const ( EOF -my %syscalls; - while(<>){ if(/^#define\s+SYS_(\w+)\s+([0-9]+)/){ my $name = $1; my $num = $2; $name =~ y/a-z/A-Z/; - $syscalls{"SYS_$name"} = "$num"; + print " SYS_$name = $num;" } } -# We keep some constants not supported in OS X Mavericks and beyond -# for the promise of compatibility. -$syscalls{"SYS_PROFIL"} = 44; -$syscalls{"SYS_ADD_PROFIL"} = 176; -$syscalls{"SYS_ATSOCKET"} = 206; -$syscalls{"SYS_ATGETMSG"} = 207; -$syscalls{"SYS_ATPUTMSG"} = 208; -$syscalls{"SYS_ATPSNDREQ"} = 209; -$syscalls{"SYS_ATPSNDRSP"} = 210; -$syscalls{"SYS_ATPGETREQ"} = 211; -$syscalls{"SYS_ATPGETRSP"} = 212; -$syscalls{"SYS_MKCOMPLEX"} = 216; -$syscalls{"SYS_STATV"} = 217; -$syscalls{"SYS_LSTATV"} = 218; -$syscalls{"SYS_FSTATV"} = 219; -$syscalls{"SYS_GETAUDIT"} = 355; -$syscalls{"SYS_SETAUDIT"} = 356; -$syscalls{"SYS_PID_HIBERNATE"} = 435; -$syscalls{"SYS_PID_SHUTDOWN_SOCKETS"} = 436; - -for my $key (sort {$syscalls{$a} <=> $syscalls{$b} || $a cmp $b} keys %syscalls){ - print "$key = $syscalls{$key};\n"; -} - print <