syscall: change solaris files to libc files

AIX and Solaris both requires libc to make any syscalls and their
implementation is really similar.
Therefore, Solaris files reused by AIX have their name changed to *_libc.

exec_libc.go is also adapted to AIX.

Updates: #25893

Change-Id: I50d1d7b964831637013d5e64799187cd9565c42b
Reviewed-on: https://go-review.googlesource.com/c/138719
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
Clément Chigot 2018-09-28 15:24:32 +02:00 committed by Ian Lance Taylor
parent dc2ae2886f
commit 49be65eeba
6 changed files with 89 additions and 20 deletions

View file

@ -83,6 +83,13 @@ func syscall_close(fd int32) int32 {
return int32(sysvicall1(&libc_close, uintptr(fd)))
}
const _F_DUP2FD = 0x9
//go:nosplit
func syscall_dup2(oldfd, newfd uintptr) (val, err uintptr) {
return syscall_fcntl(oldfd, _F_DUP2FD, newfd)
}
//go:nosplit
func syscall_execve(path, argv, envp uintptr) (err uintptr) {
call := libcall{