Improve system call support

This commit is contained in:
Justine Tunney 2021-08-25 21:35:58 -07:00
parent 63b867bd2f
commit 3085ac7837
65 changed files with 900 additions and 544 deletions

View file

@ -5,6 +5,14 @@
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
#define METASTAT(x, field) \
(IsLinux() || IsMetal() ? x.linux.field \
: IsXnu() ? x.xnu.field \
: IsFreebsd() ? x.freebsd.field \
: IsOpenbsd() ? x.openbsd.field \
: IsNetbsd() ? x.netbsd.field \
: 0)
struct stat_xnu {
int32_t st_dev;
uint16_t st_mode, st_nlink;