Restore package os/signal, with new API:
Notify replaces Incoming, allowing clients
to ask for certain signals only. Also, signals
go to everyone who asks, not just one client.
This could plausibly move into package os now
that there are no magic side effects as a result
of the import.
Update runtime for new API: move common Unix
signal handling code into signal_unix.c.
(It's so easy to do this now that we don't have
to edit Makefiles!)
Tested on darwin,linux 386,amd64.
Fixes#1266.
R=r, dsymonds, bradfitz, iant, borman
CC=golang-dev
https://golang.org/cl/3749041
make syscall.ProcAttr.Files be []uintptr
all.bash passes on Linux.
things seem to compile on GOOS={darwin,windows}
R=golang-dev, mattn.jp, alex.brainman, rsc
CC=golang-dev
https://golang.org/cl/5653055
Delete O_NDELAY, O_NONBLOCK, O_NOCTTY, O_ASYNC.
Clean up some docs.
Rename ShellExpand -> ExpandEnv.
Make NewFile take a uintptr; change File.Fd to return one.
(for API compatibility between Unix and Windows)
Fixes#2947
R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5655045
They're not portable, and pkg os is supposed to be portable.
Fixes#2562
R=golang-dev, mikioh.mikioh, r, n13m3y3r, rsc
CC=golang-dev
https://golang.org/cl/5574078
Add NetBSD to mksignals.sh and generate files.
While we're here, also add netbsd to the +build list where appropriate.
R=golang-dev, jsing
CC=golang-dev
https://golang.org/cl/5492064
- syscall (not os) now defines the Errno type.
- the low-level assembly functions Syscall, Syscall6, and so on
return Errno, not uintptr
- syscall wrappers all return error, not uintptr.
R=golang-dev, mikioh.mikioh, r, alex.brainman
CC=golang-dev
https://golang.org/cl/5372080
The go/build package already recognizes
system-specific file names like
mycode_darwin.go
mycode_darwin_386.go
mycode_386.s
However, it is also common to write files that
apply to multiple architectures, so a recent CL added
to go/build the ability to process comments
listing a set of conditions for building. For example:
// +build darwin freebsd openbsd/386
says that this file should be compiled only on
OS X, FreeBSD, or 32-bit x86 OpenBSD systems.
These conventions are not yet documented
(hence this long CL description).
This CL adds build comments to the multi-system
files in the core library, a step toward making it
possible to use go/build to build them.
With this change go/build can handle crypto/rand,
exec, net, path/filepath, os/user, and time.
os and syscall need additional adjustments.
R=golang-dev, r, gri, r, gustavo
CC=golang-dev
https://golang.org/cl/5011046
Move the Signal interface from exec_posix.go to exec.go.
Remove some unsused code from file_plan9.go.
R=fshahriar, rsc
CC=golang-dev
https://golang.org/cl/4683044