shithub: scc

Download patch

ref: 7fd2f3863ae891c34bb5e87679b256c48843c543
parent: 50937b595b6ac19d583f8a4974f081e6c39a0173
author: Hiltjo Posthuma <hiltjo@codemadness.org>
date: Thu May 19 14:36:37 EDT 2022

libc/obsd: Sync syscalls from linux/amd64

--- a/src/libc/arch/amd64/openbsd/.gitignore
+++ b/src/libc/arch/amd64/openbsd/.gitignore
@@ -5,6 +5,7 @@
 _exit.s
 _fork.s
 _getpid.s
+_getrusage.s
 _gettimeofday.s
 _kill.s
 _lseek.s
@@ -12,5 +13,6 @@
 _read.s
 _sigaction.s
 _sys_errlist.c
+_unlink.s
 _wait4.s
 _write.s
--- a/src/libc/arch/amd64/openbsd/Makefile
+++ b/src/libc/arch/amd64/openbsd/Makefile
@@ -12,6 +12,7 @@
 	_exit.$O\
 	_fork.$O\
 	_getpid.$O\
+	_getrusage.$O\
 	_gettimeofday.$O\
 	_kill.$O\
 	_lseek.$O\
@@ -18,6 +19,7 @@
 	_open.$O\
 	_read.$O\
 	_sigaction.$O\
+	_unlink.$O\
 	_write.$O\
 	_wait4.$O\
 
--- a/src/libc/arch/amd64/openbsd/syscall.lst
+++ b/src/libc/arch/amd64/openbsd/syscall.lst
@@ -6,8 +6,10 @@
 4	_write	3
 5	_open	3
 6	_close	1
+10	_unlink	1
 11	_wait4	4
 17	_brk	1
+19	_getrusage	2
 20	_getpid	0
 33	_access	2
 46	_sigaction	3
--- a/src/libc/objs/amd64-openbsd.mk
+++ b/src/libc/objs/amd64-openbsd.mk
@@ -9,6 +9,7 @@
 	arch/amd64/openbsd/_exit.$O\
 	arch/amd64/openbsd/_fork.$O\
 	arch/amd64/openbsd/_getpid.$O\
+	arch/amd64/openbsd/_getrusage.$O\
 	arch/amd64/openbsd/_gettimeofday.$O\
 	arch/amd64/openbsd/_kill.$O\
 	arch/amd64/openbsd/_lseek.$O\
@@ -15,6 +16,7 @@
 	arch/amd64/openbsd/_open.$O\
 	arch/amd64/openbsd/_read.$O\
 	arch/amd64/openbsd/_sigaction.$O\
+	arch/amd64/openbsd/_unlink.$O\
 	arch/amd64/openbsd/_wait4.$O\
 	arch/amd64/openbsd/_write.$O\
 	arch/amd64/openbsd/crt.$O\