Perform build and magnum tuning

Building o//third_party/python now takes 5 seconds on my PC

This change works towards modifying Python to use runtime dispatching
when appropriate. For example, when loading the magnums in the socket
module, it's a good idea to check if the magnum is zero, because that
means the local system platform doesn't support it.
This commit is contained in:
Justine Tunney 2021-08-10 10:26:13 -07:00
parent ee7e296339
commit d26d7ae0e4
1028 changed files with 6576 additions and 172777 deletions

29
libc/sock/alg.h Normal file
View file

@ -0,0 +1,29 @@
#ifndef COSMOPOLITAN_LIBC_SOCK_ALG_H_
#define COSMOPOLITAN_LIBC_SOCK_ALG_H_
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
struct sockaddr_alg {
uint16_t salg_family;
uint8_t salg_type[14];
uint32_t salg_feat;
uint32_t salg_mask;
uint8_t salg_name[64];
};
struct sockaddr_alg_new {
uint16_t salg_family;
uint8_t salg_type[14];
uint32_t salg_feat;
uint32_t salg_mask;
uint8_t salg_name[]; /* Linux v4.12+ */
};
struct af_alg_iv {
uint32_t ivlen;
uint8_t iv[0];
};
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMOPOLITAN_LIBC_SOCK_ALG_H_ */

View file

@ -44,7 +44,7 @@ syscon errno EEXIST 17 17 17 17 17 183 # file exists; unix conse
syscon errno EXDEV 18 18 18 18 18 17 # improper link; unix consensus; kNtErrorNotSameDevice; raised by copy_file_range(2), fanotify_mark(2), ioctl_ficlonerange(2), ioctl_fideduperange(2), link(2), openat2(2), rename(2)
syscon errno ENODEV 19 19 19 19 19 1200 # no such device; unix consensus; kNtErrorBadDevice; raised by arch_prctl(2), eventfd(2), fallocate(2), fanotify_mark(2), mmap(2), mount(2), move_pages(2), open(2), pciconfig_read(2), perf_event_open(2), pidfd_open(2), prctl(2), s390_pci_mmio_write(2), signalfd(2), spu_create(2), timerfd_create(2)
syscon errno ENOTDIR 20 20 20 20 20 3 # not a directory; unix consensus; kNtErrorPathNotFound; raised by access(2), acct(2), bind(2), chdir(2), chmod(2), chown(2), chroot(2), execve(2), execveat(2), fanotify_mark(2), fcntl(2), futimesat(2), getdents(2), inotify_add_watch(2), ioctl_fat(2), keyctl(2), link(2), mkdir(2), mknod(2), mount(2), open(2), open_by_handle_at(2), pivot_root(2), readdir(2), readlink(2), rename(2), rmdir(2), spu_create(2), stat(2), statfs(2), statx(2), symlink(2), sysctl(2), truncate(2), unlink(2), utimensat(2)
syscon errno EISDIR 21 21 21 21 21 267 # is a a directory; unix consensus; kNtErrorDirectoryNotSupported; raised by acct(2), copy_file_range(2), execve(2), ioctl_ficlonerange(2), ioctl_fideduperange(2), open(2), read(2), rename(2), truncate(2), unlink(2)
syscon errno EISDIR 21 21 21 21 21 267 # is a a directory; unix consensus; kNtErrorDirectory; raised by acct(2), copy_file_range(2), execve(2), ioctl_ficlonerange(2), ioctl_fideduperange(2), open(2), read(2), rename(2), truncate(2), unlink(2)
syscon errno EINVAL 22 22 22 22 22 87 # invalid argument; unix consensus; kNtErrorInvalidParameter; raised by accept(2), access(2), add_key(2), adjtimex(2), arch_prctl(2), bdflush(2), bind(2), bpf(2), cacheflush(2), capget(2), chmod(2), chown(2), clock_getres(2), clock_nanosleep(2), clone(2), copy_file_range(2), create_module(2), dup(2), epoll_create(2), epoll_ctl(2), epoll_wait(2), eventfd(2), execve(2), execveat(2), fallocate(2), fanotify_init(2), fanotify_mark(2), fcntl(2), flock(2), futex(2), get_mempolicy(2), get_robust_list(2), getdents(2), getdomainname(2), getgroups(2), gethostname(2), getitimer(2), getpeername(2), getpriority(2), getrandom(2), getrlimit(2), getrusage(2), getsockname(2), getsockopt(2), gettimeofday(2), init_module(2), inotify_add_watch(2), inotify_init(2), inotify_rm_watch(2), io_cancel(2), io_destroy(2), io_getevents(2), io_setup(2), io_submit(2), ioctl(2), ioctl_console(2), ioctl_ficlonerange(2), ioctl_fideduperange(2), ioctl_getfsmap(2), ioctl_ns(2), ioctl_tty(2), ioctl_userfaultfd(2), ioperm(2), iopl(2), ioprio_set(2), kcmp(2), kexec_load(2), keyctl(2), kill(2), link(2), llseek(2), lookup_dcookie(2), lseek(2), madvise(2), mbind(2), membarrier(2), memfd_create(2), migrate_pages(2), mincore(2), mkdir(2), mknod(2), mlock(2), mmap(2), mmap2(2), modify_ldt(2), mount(2), move_pages(2), mprotect(2), mremap(2), msgctl(2), msgop(2), msync(2), nanosleep(2), open(2), open_by_handle_at(2), openat2(2), pciconfig_read(2), perf_event_open(2), personality(2), pidfd_getfd(2), pidfd_open(2), pidfd_send_signal(2), pipe(2), pivot_root(2), pkey_alloc(2), poll(2), posix_fadvise(2), prctl(2), process_vm_readv(2), ptrace(2), query_module(2), quotactl(2), read(2), readahead(2), readdir(2), readlink(2), readv(2), reboot(2), recv(2), recvmmsg(2), remap_file_pages(2), rename(2), request_key(2), rmdir(2), rt_sigqueueinfo(2), s390_guarded_storage(2), s390_pci_mmio_write(2), s390_runtime_instr(2), s390_sthyi(2), sched_get_priority_max(2), sched_rr_get_interval(2), sched_setaffinity(2), sched_setattr(2), sched_setparam(2), sched_setscheduler(2), seccomp(2), select(2), semctl(2), semget(2), semop(2), send(2), sendfile(2), set_mempolicy(2), set_thread_area(2), seteuid(2), setfsgid(2), setfsuid(2), setgid(2), setns(2), setpgid(2), setresuid(2), setreuid(2), setuid(2), shmctl(2), shmget(2), shmop(2), shutdown(2), sigaction(2), sigaltstack(2), signal(2), signalfd(2), sigprocmask(2), sigsuspend(2), sigwaitinfo(2), socket(2), splice(2), spu_create(2), spu_run(2), stat(2), statx(2), subpage_prot(2), swapon(2), sync_file_range(2), sysfs(2), syslog(2), tee(2), timer_create(2), timer_delete(2), timer_getoverrun(2), timer_settime(2), timerfd_create(2), tkill(2), truncate(2), umount(2), unlink(2), unshare(2), userfaultfd(2), ustat(2), utimensat(2), vmsplice(2), wait(2), write(2), unix(7), ip(7)
syscon errno ENFILE 23 23 23 23 23 331 # too many open files in system; unix consensus; kNtErrorTooManyDescriptors; raised by accept(2), acct(2), epoll_create(2), eventfd(2), execve(2), futex(2), inotify_init(2), memfd_create(2), mmap(2), open(2), pidfd_getfd(2), pidfd_open(2), pipe(2), shmget(2), signalfd(2), socket(2), socketpair(2), spu_create(2), swapon(2), timerfd_create(2), uselib(2), userfaultfd(2)
syscon errno EMFILE 24 24 24 24 24 336 # too many open files; unix consensus; kNtErrorTooManyOpenFiles; raised by accept(2), dup(2), epoll_create(2), eventfd(2), execve(2), fanotify_init(2), fcntl(2), inotify_init(2), memfd_create(2), mount(2), open(2), perf_event_open(2), pidfd_getfd(2), pidfd_open(2), pipe(2), signalfd(2), socket(2), socketpair(2), spu_create(2), timerfd_create(2)
@ -626,6 +626,7 @@ syscon so SO_REUSEADDR 2 4 4 4 4 0 # bsd consensus (default behav
syscon so SO_KEEPALIVE 9 8 8 8 8 8 # bsd consensus
syscon so SO_DONTROUTE 5 0x10 0x10 0x10 0x10 0x10 # bsd consensus
syscon so SO_BROADCAST 6 0x20 0x20 0x20 0x20 0x20 # bsd consensus
syscon so SO_USELOOPBACK 0 0x40 0x40 0x40 0x40 0x40 # bsd consensus
syscon so SO_LINGER 13 0x80 0x80 0x80 0x80 0x80 # takes struct linger; causes close() return value to actually mean something; bsd consensus
syscon so SO_DEBUG 1 1 1 1 1 1 # consensus
syscon so SO_ACCEPTCONN 30 2 2 2 2 2 # takes int pointer and stores boolean indicating if listen() was called on fd; bsd consensus
@ -640,10 +641,12 @@ syscon so SO_EXCLUSIVEADDRUSE 0 0 0 0 0 0xfffffffb # hoo boy
syscon so SO_SNDLOWAT 19 0x1003 0x1003 0x1003 0x1003 0x1003 # bsd consensus
syscon so SO_TYPE 3 0x1008 0x1008 0x1008 0x1008 0x1008 # bsd consensus
syscon so SO_TIMESTAMP 29 0x0400 0x0400 0x0800 0x2000 0
syscon so SO_DOMAIN 39 0 0x1019 0 0 0
syscon so SO_SETFIB 0 0 0x1014 0 0 0
syscon so SO_DOMAIN 39 0 0x1019 0x1024 0 0
syscon so SO_MAX_PACING_RATE 47 0 0x1018 0 0 0
syscon so SO_PEERCRED 17 0 0 0x1022 0x1022 0
syscon so SO_PROTOCOL 38 0 0x1016 0 0 0
syscon so SO_PEERCRED 17 0 0 0x1022 0 0
syscon so LOCAL_PEERCRED 0 1 1 0 0 0
syscon so SO_PROTOCOL 38 0 0x1016 0x1025 0 0
syscon so SO_ATTACH_BPF 50 0 0 0 0 0
syscon so SO_ATTACH_FILTER 26 0 0 0 0 0
syscon so SO_ATTACH_REUSEPORT_CBPF 51 0 0 0 0 0
@ -707,6 +710,13 @@ syscon sol SOL_RXRPC 272 0 0 0 0 0
syscon sol SOL_TIPC 271 0 0 0 0 0
syscon sol SOL_X25 262 0 0 0 0 0
syscon alg ALG_SET_KEY 1 0 0 0 0 0
syscon alg ALG_SET_IV 2 0 0 0 0 0
syscon alg ALG_SET_OP 3 0 0 0 0 0
syscon alg ALG_SET_AEAD_ASSOCLEN 4 0 0 0 0 0
syscon alg ALG_SET_AEAD_AUTHSIZE 5 0 0 0 0 0
syscon alg ALG_SET_DRBG_ENTROPY 6 0 0 0 0 0
# {set,get}sockopt(fd, level=IPPROTO_TCP, X, ...)
# » most elite of all tuning groups
#
@ -758,15 +768,16 @@ syscon ip IP_MAX_MEMBERSHIPS 20 0x0fff 0x0fff 0x0fff 0x0fff 20 # b
syscon ip IP_OPTIONS 4 1 1 1 1 1 # bsd consensus
syscon ip IP_TOS 1 3 3 3 3 8 # bsd consensus
syscon ip IP_RECVTTL 12 24 65 31 23 21
syscon ip IP_ADD_MEMBERSHIP 35 12 12 12 12 0 # bsd consensus
syscon ip IP_DROP_MEMBERSHIP 36 13 13 13 13 0 # bsd consensus
syscon ip IP_MULTICAST_IF 0x20 9 9 9 9 0 # bsd consensus
syscon ip IP_MULTICAST_LOOP 34 11 11 11 11 0 # bsd consensus
syscon ip IP_MULTICAST_TTL 33 10 10 10 10 0 # bsd consensus
syscon ip IP_ADD_MEMBERSHIP 35 12 12 12 12 5 # bsd consensus
syscon ip IP_DROP_MEMBERSHIP 36 13 13 13 13 6 # bsd consensus
syscon ip IP_MULTICAST_IF 0x20 9 9 9 9 2 # bsd consensus
syscon ip IP_MULTICAST_LOOP 34 11 11 11 11 4 # bsd consensus
syscon ip IP_MULTICAST_TTL 33 10 10 10 10 3 # bsd consensus
syscon ip IP_RECVOPTS 6 5 5 5 5 0 # bsd consensus
syscon ip IP_RECVRETOPTS 7 6 6 6 6 0 # bsd consensus
syscon ip IP_RECVDSTADDR 0 7 7 7 7 0 # bsd consensus
syscon ip IP_RETOPTS 7 8 8 8 8 0 # bsd consensus
syscon ip IP_TTL 2 4 4 4 4 0 # bsd consensus
syscon ip IP_TTL 2 4 4 4 4 7 # bsd consensus
syscon ip IP_ADD_SOURCE_MEMBERSHIP 39 70 70 0 0 15
syscon ip IP_BLOCK_SOURCE 38 72 72 0 0 17
syscon ip IP_DROP_SOURCE_MEMBERSHIP 40 71 71 0 0 0x10
@ -800,6 +811,8 @@ syscon ip IP_TRANSPARENT 19 0 0 0 0 0
syscon ip IP_XFRM_POLICY 17 0 0 0 0 0
syscon ip INET_ADDRSTRLEN 0x10 0x10 0x10 0x10 0x10 22 # unix consensus
syscon ipport IPPORT_USERRESERVED 5000 5000 5000 49151 5000 5000
# ptrace() codes
#
# group name GNU/Systemd XNU's Not UNIX! FreeBSD OpenBSD NetBSD The New Technology Commentary
@ -1052,7 +1065,7 @@ syscon af AF_LOCAL 1 1 1 1 1 1 # consensus
syscon af AF_FILE 1 0 0 0 0 0
syscon af AF_INET 2 2 2 2 2 2 # consensus
syscon af AF_AX25 3 0 0 0 0 0
syscon af AF_IPX 4 23 23 23 23 0 # bsd consensus
syscon af AF_IPX 4 23 23 23 23 6 # bsd consensus
syscon af AF_APPLETALK 5 0x10 0x10 0x10 0x10 0x10 # bsd consensus
syscon af AF_NETROM 6 0 0 0 0 0
syscon af AF_BRIDGE 7 0 0 0 0 0
@ -1062,10 +1075,11 @@ syscon af AF_INET6 10 30 28 24 24 23
syscon af AF_ROSE 11 0 0 0 0 0
syscon af AF_NETBEUI 13 0 0 0 0 0
syscon af AF_SECURITY 14 0 0 0 0 0
syscon af AF_KEY 15 0 0 30 30 0
syscon af AF_KEY 15 0 0 30 0 0
syscon af AF_ROUTE 16 17 17 17 34 0 # bsd consensus
syscon af AF_NETLINK 16 0 0 0 0 0
syscon af AF_PACKET 17 0 0 0 0 0
syscon af AF_LINK 0 18 18 18 18 0
syscon af AF_ASH 18 0 0 0 0 0
syscon af AF_ECONET 19 0 0 0 0 0
syscon af AF_ATMSVC 20 0 0 0 0 0
@ -1113,7 +1127,7 @@ syscon pf PF_ATMSVC 20 0 0 0 0 0
syscon pf PF_AX25 3 0 0 0 0 0
syscon pf PF_BRIDGE 7 0 0 0 0 0
syscon pf PF_CAIF 37 0 0 0 0 0
syscon pf PF_CAN 29 0 0 0 0 0
syscon af PF_CAN 29 0 0 0 35 0
syscon pf PF_ECONET 19 0 0 0 0 0
syscon pf PF_FILE 1 0 0 0 0 0
syscon pf PF_IB 27 0 0 0 0 0
@ -1255,7 +1269,8 @@ syscon msg MSG_WAITFORONE 0x010000 0 0x080000 0 0x2000 0
syscon msg MSG_BATCH 0x040000 0 0 0 0 0
syscon msg MSG_CONFIRM 0x0800 0 0 0 0 0
syscon msg MSG_EXCEPT 0x2000 0 0 0 0 0
syscon msg MSG_FIN 0x0200 0 0 0 0 0
syscon msg MSG_FIN 0x0200 0x0100 0x0100 0 0 0
syscon msg MSG_EOF 0x0200 0x0100 0x0100 0 0 0
syscon msg MSG_INFO 12 0 0 0 0 0
syscon msg MSG_MORE 0x8000 0 0 0 0 0
syscon msg MSG_PARITY_ERROR 9 0 0 0 0 0
@ -1263,6 +1278,9 @@ syscon msg MSG_PROXY 0x10 0 0 0 0 0
syscon msg MSG_RST 0x1000 0 0 0 0 0
syscon msg MSG_STAT 11 0 0 0 0 0
syscon msg MSG_SYN 0x0400 0 0 0 0 0
syscon msg MSG_BCAST 0 0 0 0x100 0x100 0
syscon msg MSG_MCAST 0 0 0 0x200 0x200 0
syscon msg MSG_NOTIFICATION 0x8000 0 0x2000 0 0x4000 0
# getpriority() / setpriority() magnums (a.k.a. nice)
#

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon af,AF_IPX,4,23,23,23,23,0
.syscon af,AF_IPX,4,23,23,23,23,6

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon af,AF_KEY,15,0,0,30,30,0
.syscon af,AF_KEY,15,0,0,30,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon af,AF_LINK,0,18,18,18,18,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon alg,ALG_SET_AEAD_ASSOCLEN,4,0,0,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon alg,ALG_SET_AEAD_AUTHSIZE,5,0,0,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon alg,ALG_SET_DRBG_ENTROPY,6,0,0,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon alg,ALG_SET_IV,2,0,0,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon alg,ALG_SET_KEY,1,0,0,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon alg,ALG_SET_OP,3,0,0,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ipport,IPPORT_USERRESERVED,5000,5000,5000,49151,5000,5000

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ip,IP_ADD_MEMBERSHIP,35,12,12,12,12,0
.syscon ip,IP_ADD_MEMBERSHIP,35,12,12,12,12,5

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ip,IP_DROP_MEMBERSHIP,36,13,13,13,13,0
.syscon ip,IP_DROP_MEMBERSHIP,36,13,13,13,13,6

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ip,IP_MULTICAST_IF,0x20,9,9,9,9,0
.syscon ip,IP_MULTICAST_IF,0x20,9,9,9,9,2

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ip,IP_MULTICAST_LOOP,34,11,11,11,11,0
.syscon ip,IP_MULTICAST_LOOP,34,11,11,11,11,4

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ip,IP_MULTICAST_TTL,33,10,10,10,10,0
.syscon ip,IP_MULTICAST_TTL,33,10,10,10,10,3

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ip,IP_RECVDSTADDR,0,7,7,7,7,0

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon ip,IP_TTL,2,4,4,4,4,0
.syscon ip,IP_TTL,2,4,4,4,4,7

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon so,LOCAL_PEERCRED,0,1,1,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon msg,MSG_BCAST,0,0,0,0x100,0x100,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon msg,MSG_EOF,0x0200,0x0100,0x0100,0,0,0

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon msg,MSG_FIN,0x0200,0,0,0,0,0
.syscon msg,MSG_FIN,0x0200,0x0100,0x0100,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon msg,MSG_MCAST,0,0,0,0x200,0x200,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon msg,MSG_NOTIFICATION,0x8000,0,0x2000,0,0x4000,0

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon pf,PF_CAN,29,0,0,0,0,0
.syscon af,PF_CAN,29,0,0,0,35,0

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon so,SO_DOMAIN,39,0,0x1019,0,0,0
.syscon so,SO_DOMAIN,39,0,0x1019,0x1024,0,0

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon so,SO_PEERCRED,17,0,0,0x1022,0x1022,0
.syscon so,SO_PEERCRED,17,0,0,0x1022,0,0

View file

@ -1,2 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon so,SO_PROTOCOL,38,0,0x1016,0,0,0
.syscon so,SO_PROTOCOL,38,0,0x1016,0x1025,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon so,SO_SETFIB,0,0,0x1014,0,0,0

View file

@ -0,0 +1,2 @@
#include "libc/sysv/consts/syscon.internal.h"
.syscon so,SO_USELOOPBACK,0,0x40,0x40,0x40,0x40,0x40

View file

@ -26,6 +26,7 @@ extern const long AF_ISDN;
extern const long AF_IUCV;
extern const long AF_KCM;
extern const long AF_KEY;
extern const long AF_LINK;
extern const long AF_LLC;
extern const long AF_LOCAL;
extern const long AF_MAX;
@ -53,50 +54,51 @@ extern const long AF_X25;
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#define AF_ALG SYMBOLIC(AF_ALG)
#define AF_APPLETALK SYMBOLIC(AF_APPLETALK)
#define AF_ASH SYMBOLIC(AF_ASH)
#define AF_ATMPVC SYMBOLIC(AF_ATMPVC)
#define AF_ATMSVC SYMBOLIC(AF_ATMSVC)
#define AF_AX25 SYMBOLIC(AF_AX25)
#define AF_BLUETOOTH SYMBOLIC(AF_BLUETOOTH)
#define AF_BRIDGE SYMBOLIC(AF_BRIDGE)
#define AF_CAIF SYMBOLIC(AF_CAIF)
#define AF_CAN SYMBOLIC(AF_CAN)
#define AF_ECONET SYMBOLIC(AF_ECONET)
#define AF_FILE SYMBOLIC(AF_FILE)
#define AF_IB SYMBOLIC(AF_IB)
#define AF_ALG SYMBOLIC(AF_ALG)
#define AF_LINK SYMBOLIC(AF_LINK)
#define AF_APPLETALK SYMBOLIC(AF_APPLETALK)
#define AF_ASH SYMBOLIC(AF_ASH)
#define AF_ATMPVC SYMBOLIC(AF_ATMPVC)
#define AF_ATMSVC SYMBOLIC(AF_ATMSVC)
#define AF_AX25 SYMBOLIC(AF_AX25)
#define AF_BLUETOOTH SYMBOLIC(AF_BLUETOOTH)
#define AF_BRIDGE SYMBOLIC(AF_BRIDGE)
#define AF_CAIF SYMBOLIC(AF_CAIF)
#define AF_CAN SYMBOLIC(AF_CAN)
#define AF_ECONET SYMBOLIC(AF_ECONET)
#define AF_FILE SYMBOLIC(AF_FILE)
#define AF_IB SYMBOLIC(AF_IB)
#define AF_IEEE802154 SYMBOLIC(AF_IEEE802154)
#define AF_INET LITERALLY(2)
#define AF_INET6 SYMBOLIC(AF_INET6)
#define AF_IPX SYMBOLIC(AF_IPX)
#define AF_IRDA SYMBOLIC(AF_IRDA)
#define AF_ISDN SYMBOLIC(AF_ISDN)
#define AF_IUCV SYMBOLIC(AF_IUCV)
#define AF_KCM SYMBOLIC(AF_KCM)
#define AF_KEY SYMBOLIC(AF_KEY)
#define AF_LLC SYMBOLIC(AF_LLC)
#define AF_LOCAL SYMBOLIC(AF_LOCAL)
#define AF_MAX SYMBOLIC(AF_MAX)
#define AF_MPLS SYMBOLIC(AF_MPLS)
#define AF_NETBEUI SYMBOLIC(AF_NETBEUI)
#define AF_NETLINK SYMBOLIC(AF_NETLINK)
#define AF_NETROM SYMBOLIC(AF_NETROM)
#define AF_NFC SYMBOLIC(AF_NFC)
#define AF_PACKET SYMBOLIC(AF_PACKET)
#define AF_PHONET SYMBOLIC(AF_PHONET)
#define AF_PPPOX SYMBOLIC(AF_PPPOX)
#define AF_RDS SYMBOLIC(AF_RDS)
#define AF_ROSE SYMBOLIC(AF_ROSE)
#define AF_ROUTE SYMBOLIC(AF_ROUTE)
#define AF_RXRPC SYMBOLIC(AF_RXRPC)
#define AF_SECURITY SYMBOLIC(AF_SECURITY)
#define AF_SNA SYMBOLIC(AF_SNA)
#define AF_TIPC SYMBOLIC(AF_TIPC)
#define AF_UNIX LITERALLY(1)
#define AF_UNSPEC LITERALLY(0)
#define AF_VSOCK SYMBOLIC(AF_VSOCK)
#define AF_WANPIPE SYMBOLIC(AF_WANPIPE)
#define AF_X25 SYMBOLIC(AF_X25)
#define AF_INET LITERALLY(2)
#define AF_INET6 SYMBOLIC(AF_INET6)
#define AF_IPX SYMBOLIC(AF_IPX)
#define AF_IRDA SYMBOLIC(AF_IRDA)
#define AF_ISDN SYMBOLIC(AF_ISDN)
#define AF_IUCV SYMBOLIC(AF_IUCV)
#define AF_KCM SYMBOLIC(AF_KCM)
#define AF_KEY SYMBOLIC(AF_KEY)
#define AF_LLC SYMBOLIC(AF_LLC)
#define AF_LOCAL SYMBOLIC(AF_LOCAL)
#define AF_MAX SYMBOLIC(AF_MAX)
#define AF_MPLS SYMBOLIC(AF_MPLS)
#define AF_NETBEUI SYMBOLIC(AF_NETBEUI)
#define AF_NETLINK SYMBOLIC(AF_NETLINK)
#define AF_NETROM SYMBOLIC(AF_NETROM)
#define AF_NFC SYMBOLIC(AF_NFC)
#define AF_PACKET SYMBOLIC(AF_PACKET)
#define AF_PHONET SYMBOLIC(AF_PHONET)
#define AF_PPPOX SYMBOLIC(AF_PPPOX)
#define AF_RDS SYMBOLIC(AF_RDS)
#define AF_ROSE SYMBOLIC(AF_ROSE)
#define AF_ROUTE SYMBOLIC(AF_ROUTE)
#define AF_RXRPC SYMBOLIC(AF_RXRPC)
#define AF_SECURITY SYMBOLIC(AF_SECURITY)
#define AF_SNA SYMBOLIC(AF_SNA)
#define AF_TIPC SYMBOLIC(AF_TIPC)
#define AF_UNIX LITERALLY(1)
#define AF_UNSPEC LITERALLY(0)
#define AF_VSOCK SYMBOLIC(AF_VSOCK)
#define AF_WANPIPE SYMBOLIC(AF_WANPIPE)
#define AF_X25 SYMBOLIC(AF_X25)
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_AF_H_ */

30
libc/sysv/consts/alg.h Normal file
View file

@ -0,0 +1,30 @@
#ifndef COSMOPOLITAN_LIBC_SYSV_CONSTS_ALG_H_
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_ALG_H_
#include "libc/runtime/symbolic.h"
#define ALG_SET_AEAD_ASSOCLEN SYMBOLIC(ALG_SET_AEAD_ASSOCLEN)
#define ALG_SET_AEAD_AUTHSIZE SYMBOLIC(ALG_SET_AEAD_AUTHSIZE)
#define ALG_SET_DRBG_ENTROPY SYMBOLIC(ALG_SET_DRBG_ENTROPY)
#define ALG_SET_IV SYMBOLIC(ALG_SET_IV)
#define ALG_SET_KEY SYMBOLIC(ALG_SET_KEY)
#define ALG_SET_OP SYMBOLIC(ALG_SET_OP)
#define ALG_OP_DECRYPT SYMBOLIC(ALG_OP_DECRYPT)
#define ALG_OP_ENCRYPT SYMBOLIC(ALG_OP_ENCRYPT)
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
extern const long ALG_SET_AEAD_ASSOCLEN;
extern const long ALG_SET_AEAD_AUTHSIZE;
extern const long ALG_SET_DRBG_ENTROPY;
extern const long ALG_SET_IV;
extern const long ALG_SET_KEY;
extern const long ALG_SET_OP;
extern const long ALG_OP_DECRYPT;
extern const long ALG_OP_ENCRYPT;
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_ALG_H_ */

View file

@ -2,54 +2,55 @@
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_IP_H_
#include "libc/runtime/symbolic.h"
#define IP_ADD_MEMBERSHIP SYMBOLIC(IP_ADD_MEMBERSHIP)
#define IP_ADD_SOURCE_MEMBERSHIP SYMBOLIC(IP_ADD_SOURCE_MEMBERSHIP)
#define IP_BIND_ADDRESS_NO_PORT SYMBOLIC(IP_BIND_ADDRESS_NO_PORT)
#define IP_BLOCK_SOURCE SYMBOLIC(IP_BLOCK_SOURCE)
#define IP_CHECKSUM SYMBOLIC(IP_CHECKSUM)
#define IP_ADD_MEMBERSHIP SYMBOLIC(IP_ADD_MEMBERSHIP)
#define IP_ADD_SOURCE_MEMBERSHIP SYMBOLIC(IP_ADD_SOURCE_MEMBERSHIP)
#define IP_BIND_ADDRESS_NO_PORT SYMBOLIC(IP_BIND_ADDRESS_NO_PORT)
#define IP_BLOCK_SOURCE SYMBOLIC(IP_BLOCK_SOURCE)
#define IP_CHECKSUM SYMBOLIC(IP_CHECKSUM)
#define IP_DEFAULT_MULTICAST_LOOP SYMBOLIC(IP_DEFAULT_MULTICAST_LOOP)
#define IP_DEFAULT_MULTICAST_TTL SYMBOLIC(IP_DEFAULT_MULTICAST_TTL)
#define IP_DROP_MEMBERSHIP SYMBOLIC(IP_DROP_MEMBERSHIP)
#define IP_DEFAULT_MULTICAST_TTL SYMBOLIC(IP_DEFAULT_MULTICAST_TTL)
#define IP_DROP_MEMBERSHIP SYMBOLIC(IP_DROP_MEMBERSHIP)
#define IP_DROP_SOURCE_MEMBERSHIP SYMBOLIC(IP_DROP_SOURCE_MEMBERSHIP)
#define IP_FREEBIND SYMBOLIC(IP_FREEBIND)
#define IP_HDRINCL SYMBOLIC(IP_HDRINCL)
#define IP_IPSEC_POLICY SYMBOLIC(IP_IPSEC_POLICY)
#define IP_MAX_MEMBERSHIPS SYMBOLIC(IP_MAX_MEMBERSHIPS)
#define IP_MINTTL SYMBOLIC(IP_MINTTL)
#define IP_MSFILTER SYMBOLIC(IP_MSFILTER)
#define IP_MTU SYMBOLIC(IP_MTU)
#define IP_MTU_DISCOVER SYMBOLIC(IP_MTU_DISCOVER)
#define IP_MULTICAST_ALL SYMBOLIC(IP_MULTICAST_ALL)
#define IP_MULTICAST_IF SYMBOLIC(IP_MULTICAST_IF)
#define IP_MULTICAST_LOOP SYMBOLIC(IP_MULTICAST_LOOP)
#define IP_MULTICAST_TTL SYMBOLIC(IP_MULTICAST_TTL)
#define IP_NODEFRAG SYMBOLIC(IP_NODEFRAG)
#define IP_OPTIONS SYMBOLIC(IP_OPTIONS)
#define IP_ORIGDSTADDR SYMBOLIC(IP_ORIGDSTADDR)
#define IP_PASSSEC SYMBOLIC(IP_PASSSEC)
#define IP_PKTINFO SYMBOLIC(IP_PKTINFO)
#define IP_PKTOPTIONS SYMBOLIC(IP_PKTOPTIONS)
#define IP_PMTUDISC SYMBOLIC(IP_PMTUDISC)
#define IP_PMTUDISC_DO SYMBOLIC(IP_PMTUDISC_DO)
#define IP_PMTUDISC_DONT SYMBOLIC(IP_PMTUDISC_DONT)
#define IP_PMTUDISC_INTERFACE SYMBOLIC(IP_PMTUDISC_INTERFACE)
#define IP_PMTUDISC_OMIT SYMBOLIC(IP_PMTUDISC_OMIT)
#define IP_PMTUDISC_PROBE SYMBOLIC(IP_PMTUDISC_PROBE)
#define IP_PMTUDISC_WANT SYMBOLIC(IP_PMTUDISC_WANT)
#define IP_RECVERR SYMBOLIC(IP_RECVERR)
#define IP_RECVOPTS SYMBOLIC(IP_RECVOPTS)
#define IP_RECVORIGDSTADDR SYMBOLIC(IP_RECVORIGDSTADDR)
#define IP_RECVRETOPTS SYMBOLIC(IP_RECVRETOPTS)
#define IP_RECVTOS SYMBOLIC(IP_RECVTOS)
#define IP_RECVTTL SYMBOLIC(IP_RECVTTL)
#define IP_RETOPTS SYMBOLIC(IP_RETOPTS)
#define IP_ROUTER_ALERT SYMBOLIC(IP_ROUTER_ALERT)
#define IP_TOS SYMBOLIC(IP_TOS)
#define IP_TRANSPARENT SYMBOLIC(IP_TRANSPARENT)
#define IP_TTL SYMBOLIC(IP_TTL)
#define IP_UNBLOCK_SOURCE SYMBOLIC(IP_UNBLOCK_SOURCE)
#define IP_UNICAST_IF SYMBOLIC(IP_UNICAST_IF)
#define IP_XFRM_POLICY SYMBOLIC(IP_XFRM_POLICY)
#define IP_FREEBIND SYMBOLIC(IP_FREEBIND)
#define IP_HDRINCL SYMBOLIC(IP_HDRINCL)
#define IP_IPSEC_POLICY SYMBOLIC(IP_IPSEC_POLICY)
#define IP_MAX_MEMBERSHIPS SYMBOLIC(IP_MAX_MEMBERSHIPS)
#define IP_MINTTL SYMBOLIC(IP_MINTTL)
#define IP_MSFILTER SYMBOLIC(IP_MSFILTER)
#define IP_MTU SYMBOLIC(IP_MTU)
#define IP_MTU_DISCOVER SYMBOLIC(IP_MTU_DISCOVER)
#define IP_MULTICAST_ALL SYMBOLIC(IP_MULTICAST_ALL)
#define IP_MULTICAST_IF SYMBOLIC(IP_MULTICAST_IF)
#define IP_MULTICAST_LOOP SYMBOLIC(IP_MULTICAST_LOOP)
#define IP_MULTICAST_TTL SYMBOLIC(IP_MULTICAST_TTL)
#define IP_NODEFRAG SYMBOLIC(IP_NODEFRAG)
#define IP_OPTIONS SYMBOLIC(IP_OPTIONS)
#define IP_ORIGDSTADDR SYMBOLIC(IP_ORIGDSTADDR)
#define IP_PASSSEC SYMBOLIC(IP_PASSSEC)
#define IP_PKTINFO SYMBOLIC(IP_PKTINFO)
#define IP_PKTOPTIONS SYMBOLIC(IP_PKTOPTIONS)
#define IP_PMTUDISC SYMBOLIC(IP_PMTUDISC)
#define IP_PMTUDISC_DO SYMBOLIC(IP_PMTUDISC_DO)
#define IP_PMTUDISC_DONT SYMBOLIC(IP_PMTUDISC_DONT)
#define IP_PMTUDISC_INTERFACE SYMBOLIC(IP_PMTUDISC_INTERFACE)
#define IP_PMTUDISC_OMIT SYMBOLIC(IP_PMTUDISC_OMIT)
#define IP_PMTUDISC_PROBE SYMBOLIC(IP_PMTUDISC_PROBE)
#define IP_PMTUDISC_WANT SYMBOLIC(IP_PMTUDISC_WANT)
#define IP_RECVDSTADDR SYMBOLIC(IP_RECVDSTADDR)
#define IP_RECVERR SYMBOLIC(IP_RECVERR)
#define IP_RECVOPTS SYMBOLIC(IP_RECVOPTS)
#define IP_RECVORIGDSTADDR SYMBOLIC(IP_RECVORIGDSTADDR)
#define IP_RECVRETOPTS SYMBOLIC(IP_RECVRETOPTS)
#define IP_RECVTOS SYMBOLIC(IP_RECVTOS)
#define IP_RECVTTL SYMBOLIC(IP_RECVTTL)
#define IP_RETOPTS SYMBOLIC(IP_RETOPTS)
#define IP_ROUTER_ALERT SYMBOLIC(IP_ROUTER_ALERT)
#define IP_TOS SYMBOLIC(IP_TOS)
#define IP_TRANSPARENT SYMBOLIC(IP_TRANSPARENT)
#define IP_TTL SYMBOLIC(IP_TTL)
#define IP_UNBLOCK_SOURCE SYMBOLIC(IP_UNBLOCK_SOURCE)
#define IP_UNICAST_IF SYMBOLIC(IP_UNICAST_IF)
#define IP_XFRM_POLICY SYMBOLIC(IP_XFRM_POLICY)
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
@ -88,6 +89,7 @@ extern const long IP_PMTUDISC_INTERFACE;
extern const long IP_PMTUDISC_OMIT;
extern const long IP_PMTUDISC_PROBE;
extern const long IP_PMTUDISC_WANT;
extern const long IP_RECVDSTADDR;
extern const long IP_RECVERR;
extern const long IP_RECVOPTS;
extern const long IP_RECVORIGDSTADDR;

View file

@ -1,61 +1,69 @@
#ifndef COSMOPOLITAN_LIBC_SYSV_CONSTS_IPPORT_H_
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_IPPORT_H_
#include "libc/runtime/symbolic.h"
/**
* ARPA network ports.
*/
#define IPPORT_ECHO 7
#define IPPORT_DISCARD 9
#define IPPORT_SYSTAT 11
#define IPPORT_DAYTIME 13
#define IPPORT_NETSTAT 15
#define IPPORT_FTP 21
#define IPPORT_TELNET 23
#define IPPORT_SMTP 25
#define IPPORT_TIMESERVER 37
#define IPPORT_NAMESERVER 42
#define IPPORT_WHOIS 43
#define IPPORT_MTP 57
#define IPPORT_TFTP 69
#define IPPORT_RJE 77
#define IPPORT_FINGER 79
#define IPPORT_TTYLINK 87
#define IPPORT_SUPDUP 95
#define IPPORT_EXECSERVER 512
#define IPPORT_LOGINSERVER 513
#define IPPORT_CMDSERVER 514
#define IPPORT_EFSSERVER 520
#define IPPORT_BIFFUDP 512
#define IPPORT_WHOSERVER 513
#define IPPORT_ROUTESERVER 520
#define IPPORT_RESERVED 1024
#define IPPORT_USERRESERVED 5000
#define IPPORT_ECHO 7
#define IPPORT_DISCARD 9
#define IPPORT_SYSTAT 11
#define IPPORT_DAYTIME 13
#define IPPORT_NETSTAT 15
#define IPPORT_FTP 21
#define IPPORT_TELNET 23
#define IPPORT_SMTP 25
#define IPPORT_TIMESERVER 37
#define IPPORT_NAMESERVER 42
#define IPPORT_WHOIS 43
#define IPPORT_MTP 57
#define IPPORT_TFTP 69
#define IPPORT_RJE 77
#define IPPORT_FINGER 79
#define IPPORT_TTYLINK 87
#define IPPORT_SUPDUP 95
#define IPPORT_EXECSERVER 512
#define IPPORT_LOGINSERVER 513
#define IPPORT_CMDSERVER 514
#define IPPORT_EFSSERVER 520
#define IPPORT_BIFFUDP 512
#define IPPORT_WHOSERVER 513
#define IPPORT_ROUTESERVER 520
#define IPPORT_RESERVED 1024
#define IPPORT_USERRESERVED SYMBOLIC(IPPORT_USERRESERVED)
/**
* Modern network ports.
*/
#define IPPORT_SSH 22
#define IPPORT_DOMAIN 53
#define IPPORT_HTTP 80
#define IPPORT_POP3 110
#define IPPORT_SFTP 115
#define IPPORT_NTP 123
#define IPPORT_IMAP2 143
#define IPPORT_NETBIOS_NS 137
#define IPPORT_SSH 22
#define IPPORT_DOMAIN 53
#define IPPORT_HTTP 80
#define IPPORT_POP3 110
#define IPPORT_SFTP 115
#define IPPORT_NTP 123
#define IPPORT_IMAP2 143
#define IPPORT_NETBIOS_NS 137
#define IPPORT_NETBIOS_DGM 138
#define IPPORT_NETBIOS_SSN 139
#define IPPORT_BGP 179
#define IPPORT_IRC 194
#define IPPORT_HTTPS 443
#define IPPORT_PRINTER 515
#define IPPORT_NFS 2049
#define IPPORT_DISTCC 3632
#define IPPORT_SIP 5060
#define IPPORT_POSTGRESQL 5432
#define IPPORT_X11 6000
#define IPPORT_GIT 9418
#define IPPORT_IRCD 6667
#define IPPORT_IMAPS 993
#define IPPORT_POP3S 995
#define IPPORT_BGP 179
#define IPPORT_IRC 194
#define IPPORT_HTTPS 443
#define IPPORT_PRINTER 515
#define IPPORT_NFS 2049
#define IPPORT_DISTCC 3632
#define IPPORT_SIP 5060
#define IPPORT_POSTGRESQL 5432
#define IPPORT_X11 6000
#define IPPORT_GIT 9418
#define IPPORT_IRCD 6667
#define IPPORT_IMAPS 993
#define IPPORT_POP3S 995
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
extern const long IPPORT_USERRESERVED;
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_IPPORT_H_ */

View file

@ -5,20 +5,24 @@
COSMOPOLITAN_C_START_
extern const long MSG_BATCH;
extern const long MSG_BCAST;
extern const long MSG_CMSG_CLOEXEC;
extern const long MSG_CONFIRM;
extern const long MSG_CTRUNC;
extern const long MSG_DONTROUTE;
extern const long MSG_DONTWAIT;
extern const long MSG_EOF;
extern const long MSG_EOR;
extern const long MSG_ERRQUEUE;
extern const long MSG_EXCEPT;
extern const long MSG_FASTOPEN;
extern const long MSG_FIN;
extern const long MSG_INFO;
extern const long MSG_MCAST;
extern const long MSG_MORE;
extern const long MSG_NOERROR;
extern const long MSG_NOSIGNAL;
extern const long MSG_NOTIFICATION;
extern const long MSG_OOB;
extern const long MSG_PARITY_ERROR;
extern const long MSG_PEEK;
@ -33,30 +37,34 @@ extern const long MSG_WAITFORONE;
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#define MSG_BATCH SYMBOLIC(MSG_BATCH)
#define MSG_BATCH SYMBOLIC(MSG_BATCH)
#define MSG_BCAST SYMBOLIC(MSG_BCAST)
#define MSG_CMSG_CLOEXEC SYMBOLIC(MSG_CMSG_CLOEXEC)
#define MSG_CONFIRM SYMBOLIC(MSG_CONFIRM)
#define MSG_CTRUNC SYMBOLIC(MSG_CTRUNC)
#define MSG_DONTROUTE LITERALLY(4)
#define MSG_DONTWAIT SYMBOLIC(MSG_DONTWAIT)
#define MSG_EOR SYMBOLIC(MSG_EOR)
#define MSG_ERRQUEUE SYMBOLIC(MSG_ERRQUEUE)
#define MSG_EXCEPT SYMBOLIC(MSG_EXCEPT)
#define MSG_FASTOPEN SYMBOLIC(MSG_FASTOPEN)
#define MSG_FIN SYMBOLIC(MSG_FIN)
#define MSG_INFO SYMBOLIC(MSG_INFO)
#define MSG_MORE SYMBOLIC(MSG_MORE)
#define MSG_NOERROR SYMBOLIC(MSG_NOERROR)
#define MSG_NOSIGNAL SYMBOLIC(MSG_NOSIGNAL)
#define MSG_OOB LITERALLY(1)
#define MSG_CONFIRM SYMBOLIC(MSG_CONFIRM)
#define MSG_CTRUNC SYMBOLIC(MSG_CTRUNC)
#define MSG_DONTROUTE LITERALLY(4)
#define MSG_DONTWAIT SYMBOLIC(MSG_DONTWAIT)
#define MSG_EOF SYMBOLIC(MSG_EOF)
#define MSG_EOR SYMBOLIC(MSG_EOR)
#define MSG_ERRQUEUE SYMBOLIC(MSG_ERRQUEUE)
#define MSG_EXCEPT SYMBOLIC(MSG_EXCEPT)
#define MSG_FASTOPEN SYMBOLIC(MSG_FASTOPEN)
#define MSG_FIN SYMBOLIC(MSG_FIN)
#define MSG_INFO SYMBOLIC(MSG_INFO)
#define MSG_MCAST SYMBOLIC(MSG_MCAST)
#define MSG_MORE SYMBOLIC(MSG_MORE)
#define MSG_NOERROR SYMBOLIC(MSG_NOERROR)
#define MSG_NOSIGNAL SYMBOLIC(MSG_NOSIGNAL)
#define MSG_NOTIFICATION SYMBOLIC(MSG_NOTIFICATION)
#define MSG_OOB LITERALLY(1)
#define MSG_PARITY_ERROR SYMBOLIC(MSG_PARITY_ERROR)
#define MSG_PEEK LITERALLY(2)
#define MSG_PROXY SYMBOLIC(MSG_PROXY)
#define MSG_RST SYMBOLIC(MSG_RST)
#define MSG_STAT SYMBOLIC(MSG_STAT)
#define MSG_SYN SYMBOLIC(MSG_SYN)
#define MSG_TRUNC SYMBOLIC(MSG_TRUNC)
#define MSG_WAITALL SYMBOLIC(MSG_WAITALL)
#define MSG_WAITFORONE SYMBOLIC(MSG_WAITFORONE)
#define MSG_PEEK LITERALLY(2)
#define MSG_PROXY SYMBOLIC(MSG_PROXY)
#define MSG_RST SYMBOLIC(MSG_RST)
#define MSG_STAT SYMBOLIC(MSG_STAT)
#define MSG_SYN SYMBOLIC(MSG_SYN)
#define MSG_TRUNC SYMBOLIC(MSG_TRUNC)
#define MSG_WAITALL SYMBOLIC(MSG_WAITALL)
#define MSG_WAITFORONE SYMBOLIC(MSG_WAITFORONE)
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_MSG_H_ */

View file

@ -2,66 +2,72 @@
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_SO_H_
#include "libc/runtime/symbolic.h"
#define SO_ACCEPTCONN SYMBOLIC(SO_ACCEPTCONN)
#define SO_ATTACH_BPF SYMBOLIC(SO_ATTACH_BPF)
#define SO_ATTACH_FILTER SYMBOLIC(SO_ATTACH_FILTER)
#define LOCAL_PEERCRED SYMBOLIC(LOCAL_PEERCRED)
#define SO_ACCEPTCONN SYMBOLIC(SO_ACCEPTCONN)
#define SO_ATTACH_BPF SYMBOLIC(SO_ATTACH_BPF)
#define SO_ATTACH_FILTER SYMBOLIC(SO_ATTACH_FILTER)
#define SO_ATTACH_REUSEPORT_CBPF SYMBOLIC(SO_ATTACH_REUSEPORT_CBPF)
#define SO_ATTACH_REUSEPORT_EBPF SYMBOLIC(SO_ATTACH_REUSEPORT_EBPF)
#define SO_BINDTODEVICE SYMBOLIC(SO_BINDTODEVICE)
#define SO_BPF_EXTENSIONS SYMBOLIC(SO_BPF_EXTENSIONS)
#define SO_BROADCAST SYMBOLIC(SO_BROADCAST)
#define SO_BSDCOMPAT SYMBOLIC(SO_BSDCOMPAT)
#define SO_BUSY_POLL SYMBOLIC(SO_BUSY_POLL)
#define SO_CNX_ADVICE SYMBOLIC(SO_CNX_ADVICE)
#define SO_DEBUG SYMBOLIC(SO_DEBUG)
#define SO_DETACH_BPF SYMBOLIC(SO_DETACH_BPF)
#define SO_DETACH_FILTER SYMBOLIC(SO_DETACH_FILTER)
#define SO_DOMAIN SYMBOLIC(SO_DOMAIN)
#define SO_DONTROUTE SYMBOLIC(SO_DONTROUTE)
#define SO_ERROR SYMBOLIC(SO_ERROR)
#define SO_EXCLUSIVEADDRUSE SYMBOLIC(SO_EXCLUSIVEADDRUSE)
#define SO_GET_FILTER SYMBOLIC(SO_GET_FILTER)
#define SO_INCOMING_CPU SYMBOLIC(SO_INCOMING_CPU)
#define SO_KEEPALIVE SYMBOLIC(SO_KEEPALIVE)
#define SO_LINGER SYMBOLIC(SO_LINGER)
#define SO_LOCK_FILTER SYMBOLIC(SO_LOCK_FILTER)
#define SO_MARK SYMBOLIC(SO_MARK)
#define SO_MAX_PACING_RATE SYMBOLIC(SO_MAX_PACING_RATE)
#define SO_NOFCS SYMBOLIC(SO_NOFCS)
#define SO_NO_CHECK SYMBOLIC(SO_NO_CHECK)
#define SO_OOBINLINE SYMBOLIC(SO_OOBINLINE)
#define SO_PASSCRED SYMBOLIC(SO_PASSCRED)
#define SO_PASSSEC SYMBOLIC(SO_PASSSEC)
#define SO_PEEK_OFF SYMBOLIC(SO_PEEK_OFF)
#define SO_PEERCRED SYMBOLIC(SO_PEERCRED)
#define SO_PEERNAME SYMBOLIC(SO_PEERNAME)
#define SO_PEERSEC SYMBOLIC(SO_PEERSEC)
#define SO_PRIORITY SYMBOLIC(SO_PRIORITY)
#define SO_PROTOCOL SYMBOLIC(SO_PROTOCOL)
#define SO_RCVBUF SYMBOLIC(SO_RCVBUF)
#define SO_RCVBUFFORCE SYMBOLIC(SO_RCVBUFFORCE)
#define SO_RCVLOWAT SYMBOLIC(SO_RCVLOWAT)
#define SO_RCVTIMEO SYMBOLIC(SO_RCVTIMEO)
#define SO_REUSEADDR SYMBOLIC(SO_REUSEADDR)
#define SO_REUSEPORT SYMBOLIC(SO_REUSEPORT)
#define SO_RXQ_OVFL SYMBOLIC(SO_RXQ_OVFL)
#define SO_SECURITY_AUTHENTICATION SYMBOLIC(SO_SECURITY_AUTHENTICATION)
#define SO_BINDTODEVICE SYMBOLIC(SO_BINDTODEVICE)
#define SO_BPF_EXTENSIONS SYMBOLIC(SO_BPF_EXTENSIONS)
#define SO_BROADCAST SYMBOLIC(SO_BROADCAST)
#define SO_BSDCOMPAT SYMBOLIC(SO_BSDCOMPAT)
#define SO_BUSY_POLL SYMBOLIC(SO_BUSY_POLL)
#define SO_CNX_ADVICE SYMBOLIC(SO_CNX_ADVICE)
#define SO_DEBUG SYMBOLIC(SO_DEBUG)
#define SO_DETACH_BPF SYMBOLIC(SO_DETACH_BPF)
#define SO_DETACH_FILTER SYMBOLIC(SO_DETACH_FILTER)
#define SO_DOMAIN SYMBOLIC(SO_DOMAIN)
#define SO_DONTROUTE SYMBOLIC(SO_DONTROUTE)
#define SO_ERROR SYMBOLIC(SO_ERROR)
#define SO_EXCLUSIVEADDRUSE SYMBOLIC(SO_EXCLUSIVEADDRUSE)
#define SO_GET_FILTER SYMBOLIC(SO_GET_FILTER)
#define SO_INCOMING_CPU SYMBOLIC(SO_INCOMING_CPU)
#define SO_KEEPALIVE SYMBOLIC(SO_KEEPALIVE)
#define SO_LINGER SYMBOLIC(SO_LINGER)
#define SO_LOCK_FILTER SYMBOLIC(SO_LOCK_FILTER)
#define SO_MARK SYMBOLIC(SO_MARK)
#define SO_MAX_PACING_RATE SYMBOLIC(SO_MAX_PACING_RATE)
#define SO_NOFCS SYMBOLIC(SO_NOFCS)
#define SO_NO_CHECK SYMBOLIC(SO_NO_CHECK)
#define SO_OOBINLINE SYMBOLIC(SO_OOBINLINE)
#define SO_PASSCRED SYMBOLIC(SO_PASSCRED)
#define SO_PASSSEC SYMBOLIC(SO_PASSSEC)
#define SO_PEEK_OFF SYMBOLIC(SO_PEEK_OFF)
#define SO_PEERCRED SYMBOLIC(SO_PEERCRED)
#define SO_PEERNAME SYMBOLIC(SO_PEERNAME)
#define SO_PEERSEC SYMBOLIC(SO_PEERSEC)
#define SO_PRIORITY SYMBOLIC(SO_PRIORITY)
#define SO_PROTOCOL SYMBOLIC(SO_PROTOCOL)
#define SO_RCVBUF SYMBOLIC(SO_RCVBUF)
#define SO_RCVBUFFORCE SYMBOLIC(SO_RCVBUFFORCE)
#define SO_RCVLOWAT SYMBOLIC(SO_RCVLOWAT)
#define SO_RCVTIMEO SYMBOLIC(SO_RCVTIMEO)
#define SO_REUSEADDR SYMBOLIC(SO_REUSEADDR)
#define SO_REUSEPORT SYMBOLIC(SO_REUSEPORT)
#define SO_RXQ_OVFL SYMBOLIC(SO_RXQ_OVFL)
#define SO_SELECT_ERR_QUEUE SYMBOLIC(SO_SELECT_ERR_QUEUE)
#define SO_SETFIB SYMBOLIC(SO_SETFIB)
#define SO_SNDBUF SYMBOLIC(SO_SNDBUF)
#define SO_SNDBUFFORCE SYMBOLIC(SO_SNDBUFFORCE)
#define SO_SNDLOWAT SYMBOLIC(SO_SNDLOWAT)
#define SO_SNDTIMEO SYMBOLIC(SO_SNDTIMEO)
#define SO_TIMESTAMP SYMBOLIC(SO_TIMESTAMP)
#define SO_TIMESTAMPING SYMBOLIC(SO_TIMESTAMPING)
#define SO_TIMESTAMPNS SYMBOLIC(SO_TIMESTAMPNS)
#define SO_TYPE SYMBOLIC(SO_TYPE)
#define SO_USELOOPBACK SYMBOLIC(SO_USELOOPBACK)
#define SO_WIFI_STATUS SYMBOLIC(SO_WIFI_STATUS)
#define SO_SECURITY_AUTHENTICATION SYMBOLIC(SO_SECURITY_AUTHENTICATION)
#define SO_SECURITY_ENCRYPTION_NETWORK SYMBOLIC(SO_SECURITY_ENCRYPTION_NETWORK)
#define SO_SECURITY_ENCRYPTION_TRANSPORT SYMBOLIC(SO_SECURITY_ENCRYPTION_TRANSPORT)
#define SO_SELECT_ERR_QUEUE SYMBOLIC(SO_SELECT_ERR_QUEUE)
#define SO_SNDBUF SYMBOLIC(SO_SNDBUF)
#define SO_SNDBUFFORCE SYMBOLIC(SO_SNDBUFFORCE)
#define SO_SNDLOWAT SYMBOLIC(SO_SNDLOWAT)
#define SO_SNDTIMEO SYMBOLIC(SO_SNDTIMEO)
#define SO_TIMESTAMP SYMBOLIC(SO_TIMESTAMP)
#define SO_TIMESTAMPING SYMBOLIC(SO_TIMESTAMPING)
#define SO_TIMESTAMPNS SYMBOLIC(SO_TIMESTAMPNS)
#define SO_TYPE SYMBOLIC(SO_TYPE)
#define SO_WIFI_STATUS SYMBOLIC(SO_WIFI_STATUS)
#define SO_SECURITY_ENCRYPTION_TRANSPORT \
SYMBOLIC(SO_SECURITY_ENCRYPTION_TRANSPORT)
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
extern const long LOCAL_PEERCRED;
extern const long SO_ACCEPTCONN;
extern const long SO_ATTACH_BPF;
extern const long SO_ATTACH_FILTER;
@ -109,6 +115,7 @@ extern const long SO_SECURITY_AUTHENTICATION;
extern const long SO_SECURITY_ENCRYPTION_NETWORK;
extern const long SO_SECURITY_ENCRYPTION_TRANSPORT;
extern const long SO_SELECT_ERR_QUEUE;
extern const long SO_SETFIB;
extern const long SO_SNDBUF;
extern const long SO_SNDBUFFORCE;
extern const long SO_SNDLOWAT;
@ -117,6 +124,7 @@ extern const long SO_TIMESTAMP;
extern const long SO_TIMESTAMPING;
extern const long SO_TIMESTAMPNS;
extern const long SO_TYPE;
extern const long SO_USELOOPBACK;
extern const long SO_WIFI_STATUS;
COSMOPOLITAN_C_END_