cosmopolitan/libc/sysv/consts/nr.h
Justine Tunney 23e235b7a5
Fix bugs in cosmocc toolchain
This change integrates e58abc1110b335a3341e8ad5821ad8e3880d9bb2 from
https://github.com/ahgamut/musl-cross-make/ which fixes the issues we
were having with our C language extension for symbolic constants. This
change also performs some code cleanup and bug fixes to getaddrinfo().
It's now possible to compile projects like ncurses, readline and python
without needing to patch anything upstream, except maybe a line or two.
Pretty soon it should be possible to build a Linux distro on Cosmo.
2023-06-08 23:44:03 -07:00

343 lines
11 KiB
C

#ifndef COSMOPOLITAN_LIBC_SYSV_CONSTS_NR_H_
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_NR_H_
#ifdef COSMO
#if !(__ASSEMBLER__ + __LINKER__ + 0)
COSMOPOLITAN_C_START_
extern const int __NR_exit;
extern const int __NR_exit_group;
extern const int __NR_read;
extern const int __NR_write;
extern const int __NR_open;
extern const int __NR_close;
extern const int __NR_stat;
extern const int __NR_fstat;
extern const int __NR_lstat;
extern const int __NR_poll;
extern const int __NR_ppoll;
extern const int __NR_lseek;
extern const int __NR_mmap;
extern const int __NR_msync;
extern const int __NR_mprotect;
extern const int __NR_munmap;
extern const int __NR_sigaction;
extern const int __NR_sigprocmask;
extern const int __NR_ioctl;
extern const int __NR_pread;
extern const int __NR_pwrite;
extern const int __NR_readv;
extern const int __NR_writev;
extern const int __NR_access;
extern const int __NR_pipe;
extern const int __NR_select;
extern const int __NR_pselect;
extern const int __NR_pselect6;
extern const int __NR_sched_yield;
extern const int __NR_mremap;
extern const int __NR_mincore;
extern const int __NR_madvise;
extern const int __NR_shmget;
extern const int __NR_shmat;
extern const int __NR_shmctl;
extern const int __NR_dup;
extern const int __NR_dup2;
extern const int __NR_pause;
extern const int __NR_nanosleep;
extern const int __NR_getitimer;
extern const int __NR_setitimer;
extern const int __NR_alarm;
extern const int __NR_getpid;
extern const int __NR_sendfile;
extern const int __NR_socket;
extern const int __NR_connect;
extern const int __NR_accept;
extern const int __NR_sendto;
extern const int __NR_recvfrom;
extern const int __NR_sendmsg;
extern const int __NR_recvmsg;
extern const int __NR_shutdown;
extern const int __NR_bind;
extern const int __NR_listen;
extern const int __NR_getsockname;
extern const int __NR_getpeername;
extern const int __NR_socketpair;
extern const int __NR_setsockopt;
extern const int __NR_getsockopt;
extern const int __NR_fork;
extern const int __NR_vfork;
extern const int __NR_posix_spawn;
extern const int __NR_execve;
extern const int __NR_wait4;
extern const int __NR_kill;
extern const int __NR_killpg;
extern const int __NR_clone;
extern const int __NR_tkill;
extern const int __NR_futex;
extern const int __NR_set_robust_list;
extern const int __NR_get_robust_list;
extern const int __NR_uname;
extern const int __NR_semget;
extern const int __NR_semop;
extern const int __NR_semctl;
extern const int __NR_shmdt;
extern const int __NR_msgget;
extern const int __NR_msgsnd;
extern const int __NR_msgrcv;
extern const int __NR_msgctl;
extern const int __NR_fcntl;
extern const int __NR_flock;
extern const int __NR_fsync;
extern const int __NR_fdatasync;
extern const int __NR_truncate;
extern const int __NR_ftruncate;
extern const int __NR_getcwd;
extern const int __NR_chdir;
extern const int __NR_fchdir;
extern const int __NR_rename;
extern const int __NR_mkdir;
extern const int __NR_rmdir;
extern const int __NR_creat;
extern const int __NR_link;
extern const int __NR_unlink;
extern const int __NR_symlink;
extern const int __NR_readlink;
extern const int __NR_chmod;
extern const int __NR_fchmod;
extern const int __NR_chown;
extern const int __NR_fchown;
extern const int __NR_lchown;
extern const int __NR_umask;
extern const int __NR_gettimeofday;
extern const int __NR_getrlimit;
extern const int __NR_getrusage;
extern const int __NR_sysinfo;
extern const int __NR_times;
extern const int __NR_ptrace;
extern const int __NR_syslog;
extern const int __NR_getuid;
extern const int __NR_getgid;
extern const int __NR_getppid;
extern const int __NR_getpgrp;
extern const int __NR_setsid;
extern const int __NR_getsid;
extern const int __NR_getpgid;
extern const int __NR_setpgid;
extern const int __NR_geteuid;
extern const int __NR_getegid;
extern const int __NR_getgroups;
extern const int __NR_setgroups;
extern const int __NR_setreuid;
extern const int __NR_setregid;
extern const int __NR_setuid;
extern const int __NR_setgid;
extern const int __NR_setresuid;
extern const int __NR_setresgid;
extern const int __NR_getresuid;
extern const int __NR_getresgid;
extern const int __NR_sigpending;
extern const int __NR_sigsuspend;
extern const int __NR_sigaltstack;
extern const int __NR_mknod;
extern const int __NR_mknodat;
extern const int __NR_mkfifo;
extern const int __NR_mkfifoat;
extern const int __NR_statfs;
extern const int __NR_fstatfs;
extern const int __NR_getpriority;
extern const int __NR_setpriority;
extern const int __NR_mlock;
extern const int __NR_munlock;
extern const int __NR_mlockall;
extern const int __NR_munlockall;
extern const int __NR_setrlimit;
extern const int __NR_chroot;
extern const int __NR_sync;
extern const int __NR_acct;
extern const int __NR_settimeofday;
extern const int __NR_mount;
extern const int __NR_reboot;
extern const int __NR_quotactl;
extern const int __NR_setfsuid;
extern const int __NR_setfsgid;
extern const int __NR_capget;
extern const int __NR_capset;
extern const int __NR_sigtimedwait;
extern const int __NR_sigqueueinfo;
extern const int __NR_personality;
extern const int __NR_ustat;
extern const int __NR_sysfs;
extern const int __NR_sched_setparam;
extern const int __NR_sched_getparam;
extern const int __NR_sched_setscheduler;
extern const int __NR_sched_getscheduler;
extern const int __NR_sched_get_priority_max;
extern const int __NR_sched_get_priority_min;
extern const int __NR_sched_rr_get_interval;
extern const int __NR_vhangup;
extern const int __NR_modify_ldt;
extern const int __NR_pivot_root;
extern const int __NR__sysctl;
extern const int __NR_prctl;
extern const int __NR_arch_prctl;
extern const int __NR_adjtimex;
extern const int __NR_umount2;
extern const int __NR_swapon;
extern const int __NR_swapoff;
extern const int __NR_sethostname;
extern const int __NR_setdomainname;
extern const int __NR_iopl;
extern const int __NR_ioperm;
extern const int __NR_init_module;
extern const int __NR_delete_module;
extern const int __NR_gettid;
extern const int __NR_readahead;
extern const int __NR_setxattr;
extern const int __NR_fsetxattr;
extern const int __NR_getxattr;
extern const int __NR_fgetxattr;
extern const int __NR_listxattr;
extern const int __NR_flistxattr;
extern const int __NR_removexattr;
extern const int __NR_fremovexattr;
extern const int __NR_lsetxattr;
extern const int __NR_lgetxattr;
extern const int __NR_llistxattr;
extern const int __NR_lremovexattr;
extern const int __NR_sched_setaffinity;
extern const int __NR_sched_getaffinity;
extern const int __NR_cpuset_getaffinity;
extern const int __NR_cpuset_setaffinity;
extern const int __NR_io_setup;
extern const int __NR_io_destroy;
extern const int __NR_io_getevents;
extern const int __NR_io_submit;
extern const int __NR_io_cancel;
extern const int __NR_lookup_dcookie;
extern const int __NR_epoll_create;
extern const int __NR_epoll_wait;
extern const int __NR_epoll_ctl;
extern const int __NR_getdents;
extern const int __NR_set_tid_address;
extern const int __NR_restart_syscall;
extern const int __NR_semtimedop;
extern const int __NR_fadvise;
extern const int __NR_timer_create;
extern const int __NR_timer_settime;
extern const int __NR_timer_gettime;
extern const int __NR_timer_getoverrun;
extern const int __NR_timer_delete;
extern const int __NR_clock_settime;
extern const int __NR_clock_gettime;
extern const int __NR_clock_getres;
extern const int __NR_clock_nanosleep;
extern const int __NR_tgkill;
extern const int __NR_mbind;
extern const int __NR_set_mempolicy;
extern const int __NR_get_mempolicy;
extern const int __NR_mq_open;
extern const int __NR_mq_unlink;
extern const int __NR_mq_timedsend;
extern const int __NR_mq_timedreceive;
extern const int __NR_mq_notify;
extern const int __NR_mq_getsetattr;
extern const int __NR_kexec_load;
extern const int __NR_waitid;
extern const int __NR_add_key;
extern const int __NR_request_key;
extern const int __NR_keyctl;
extern const int __NR_ioprio_set;
extern const int __NR_ioprio_get;
extern const int __NR_inotify_init;
extern const int __NR_inotify_add_watch;
extern const int __NR_inotify_rm_watch;
extern const int __NR_openat;
extern const int __NR_mkdirat;
extern const int __NR_fchownat;
extern const int __NR_utime;
extern const int __NR_utimes;
extern const int __NR_futimesat;
extern const int __NR_futimes;
extern const int __NR_futimens;
extern const int __NR_fstatat;
extern const int __NR_unlinkat;
extern const int __NR_renameat;
extern const int __NR_linkat;
extern const int __NR_symlinkat;
extern const int __NR_readlinkat;
extern const int __NR_fchmodat;
extern const int __NR_faccessat;
extern const int __NR_unshare;
extern const int __NR_splice;
extern const int __NR_tee;
extern const int __NR_sync_file_range;
extern const int __NR_vmsplice;
extern const int __NR_migrate_pages;
extern const int __NR_move_pages;
extern const int __NR_preadv;
extern const int __NR_pwritev;
extern const int __NR_utimensat;
extern const int __NR_fallocate;
extern const int __NR_posix_fallocate;
extern const int __NR_accept4;
extern const int __NR_dup3;
extern const int __NR_pipe2;
extern const int __NR_epoll_pwait;
extern const int __NR_epoll_create1;
extern const int __NR_perf_event_open;
extern const int __NR_inotify_init1;
extern const int __NR_tgsigqueueinfo;
extern const int __NR_signalfd;
extern const int __NR_signalfd4;
extern const int __NR_eventfd;
extern const int __NR_eventfd2;
extern const int __NR_timerfd_create;
extern const int __NR_timerfd_settime;
extern const int __NR_timerfd_gettime;
extern const int __NR_recvmmsg;
extern const int __NR_fanotify_init;
extern const int __NR_fanotify_mark;
extern const int __NR_prlimit;
extern const int __NR_name_to_handle_at;
extern const int __NR_open_by_handle_at;
extern const int __NR_clock_adjtime;
extern const int __NR_syncfs;
extern const int __NR_sendmmsg;
extern const int __NR_setns;
extern const int __NR_getcpu;
extern const int __NR_process_vm_readv;
extern const int __NR_process_vm_writev;
extern const int __NR_kcmp;
extern const int __NR_finit_module;
extern const int __NR_sched_setattr;
extern const int __NR_sched_getattr;
extern const int __NR_renameat2;
extern const int __NR_seccomp;
extern const int __NR_getrandom;
extern const int __NR_memfd_create;
extern const int __NR_kexec_file_load;
extern const int __NR_bpf;
extern const int __NR_execveat;
extern const int __NR_userfaultfd;
extern const int __NR_membarrier;
extern const int __NR_mlock2;
extern const int __NR_copy_file_range;
extern const int __NR_preadv2;
extern const int __NR_pwritev2;
extern const int __NR_pkey_mprotect;
extern const int __NR_pkey_alloc;
extern const int __NR_pkey_free;
extern const int __NR_statx;
extern const int __NR_io_pgetevents;
extern const int __NR_rseq;
extern const int __NR_pidfd_send_signal;
extern const int __NR_io_uring_setup;
extern const int __NR_io_uring_enter;
extern const int __NR_io_uring_register;
extern const int __NR_pledge;
extern const int __NR_msyscall;
extern const int __NR_ktrace;
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
#endif /* COSMO */
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_NR_H_ */