mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-29 14:00:29 +00:00
Undiamond Python headers
This change gets the Python codebase into a state where it conforms to the conventions of this codebase. It's now possible to include headers from Python, without worrying about ordering. Python has traditionally solved that problem by "diamonding" everything in Python.h, but that's problematic since it means any change to any Python header invalidates all the build artifacts. Lastly it makes tooling not work. Since it is hard to explain to Emacs when I press C-c C-h to add an import line it shouldn't add the header that actually defines the symbol, and instead do follow the nonstandard Python convention. Progress has been made on letting Python load source code from the zip executable structure via the standard C library APIs. System calss now recognizes zip!FILENAME alternative URIs as equivalent to zip:FILENAME since Python uses colon as its delimiter. Some progress has been made on embedding the notice license terms into the Python object code. This is easier said than done since Python has an extremely complicated ownership story. - Some termios APIs have been added - Implement rewinddir() dirstream API - GetCpuCount() API added to Cosmopolitan Libc - More bugs in Cosmopolitan Libc have been fixed - zipobj.com now has flags for mangling the path - Fixed bug a priori with sendfile() on certain BSDs - Polyfill F_DUPFD and F_DUPFD_CLOEXEC across platforms - FIOCLEX / FIONCLEX now polyfilled for fast O_CLOEXEC changes - APE now supports a hybrid solution to no-self-modify for builds - Many BSD-only magnums added, e.g. O_SEARCH, O_SHLOCK, SF_NODISKIO
This commit is contained in:
parent
20bb8db9f8
commit
b420ed8248
762 changed files with 18410 additions and 53772 deletions
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B0,0,0,0,0,0,0
|
||||
.syscon baud,B0,0,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B1000000,0x1008,0,0,0,0,0
|
||||
.syscon baud,B1000000,0x1008,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B110,3,110,110,110,110,0
|
||||
.syscon baud,B110,3,110,110,110,110,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B115200,0x1002,0x01c200,0x01c200,0x01c200,0x01c200,0
|
||||
.syscon baud,B115200,0x1002,0x01c200,0x01c200,0x01c200,0x01c200,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B1152000,0x1009,0,0,0,0,0
|
||||
.syscon baud,B1152000,0x1009,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B1200,9,0x04b0,0x04b0,0x04b0,0x04b0,0
|
||||
.syscon baud,B1200,9,0x04b0,0x04b0,0x04b0,0x04b0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B134,4,134,134,134,134,0
|
||||
.syscon baud,B134,4,134,134,134,134,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B150,5,150,150,150,150,0
|
||||
.syscon baud,B150,5,150,150,150,150,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B1500000,0x100a,0,0,0,0,0
|
||||
.syscon baud,B1500000,0x100a,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B1800,10,0x0708,0x0708,0x0708,0x0708,0
|
||||
.syscon baud,B1800,10,0x0708,0x0708,0x0708,0x0708,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B19200,14,0x4b00,0x4b00,0x4b00,0x4b00,0
|
||||
.syscon baud,B19200,14,0x4b00,0x4b00,0x4b00,0x4b00,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B200,6,200,200,200,200,0
|
||||
.syscon baud,B200,6,200,200,200,200,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B2000000,0x100b,0,0,0,0,0
|
||||
.syscon baud,B2000000,0x100b,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B230400,0x1003,0x038400,0x038400,0x038400,0x038400,0
|
||||
.syscon baud,B230400,0x1003,0x038400,0x038400,0x038400,0x038400,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B2400,11,0x0960,0x0960,0x0960,0x0960,0
|
||||
.syscon baud,B2400,11,0x0960,0x0960,0x0960,0x0960,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B2500000,0x100c,0,0,0,0,0
|
||||
.syscon baud,B2500000,0x100c,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B300,7,300,300,300,300,0
|
||||
.syscon baud,B300,7,300,300,300,300,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B3000000,0x100d,0,0,0,0,0
|
||||
.syscon baud,B3000000,0x100d,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B3500000,0x100e,0,0,0,0,0
|
||||
.syscon baud,B3500000,0x100e,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B38400,15,0x9600,0x9600,0x9600,0x9600,0
|
||||
.syscon baud,B38400,15,0x9600,0x9600,0x9600,0x9600,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B4000000,0x100f,0,0,0,0,0
|
||||
.syscon baud,B4000000,0x100f,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B4800,12,0x12c0,0x12c0,0x12c0,0x12c0,0
|
||||
.syscon baud,B4800,12,0x12c0,0x12c0,0x12c0,0x12c0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B50,1,50,50,50,50,0
|
||||
.syscon baud,B50,1,50,50,50,50,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B500000,0x1005,0,0,0,0,0
|
||||
.syscon baud,B500000,0x1005,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B57600,0x1001,0xe100,0xe100,0xe100,0xe100,0
|
||||
.syscon baud,B57600,0x1001,0xe100,0xe100,0xe100,0xe100,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B576000,0x1006,0,0,0,0,0
|
||||
.syscon baud,B576000,0x1006,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B600,8,600,600,600,600,0
|
||||
.syscon baud,B600,8,600,600,600,600,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B75,2,75,75,75,75,0
|
||||
.syscon baud,B75,2,75,75,75,75,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,B9600,13,0x2580,0x2580,0x2580,0x2580,0
|
||||
.syscon baud,B9600,13,0x2580,0x2580,0x2580,0x2580,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,CREAD,0x80,0x0800,0x0800,0x0800,0x0800,0
|
||||
.syscon termios,CREAD,0x80,0x0800,0x0800,0x0800,0x0800,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,CS5,0,0,0,0,0,0
|
||||
.syscon termios,CS5,0,0,0,0,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,CSTART,17,17,17,17,17,0
|
||||
.syscon termios,CSTART,17,17,17,17,17,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,CSTOP,19,19,19,19,19,0
|
||||
.syscon termios,CSTOP,19,19,19,19,19,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,CSTOPB,0x40,0x0400,0x0400,0x0400,0x0400,0
|
||||
.syscon termios,CSTOPB,0x40,0x0400,0x0400,0x0400,0x0400,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,CSUSP,26,26,26,26,26,0
|
||||
.syscon termios,CSUSP,26,26,26,26,26,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,CWERASE,23,23,23,23,23,0
|
||||
.syscon termios,CWERASE,23,23,23,23,23,0
|
||||
|
|
2
libc/sysv/consts/FIOCLEX.S
Normal file
2
libc/sysv/consts/FIOCLEX.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon ioctl,FIOCLEX,0x5451,0x20006601,0x20006601,0x20006601,0x20006601,0x5451
|
2
libc/sysv/consts/FIONCLEX.S
Normal file
2
libc/sysv/consts/FIONCLEX.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon ioctl,FIONCLEX,0x5450,0x20006602,0x20006602,0x20006602,0x20006602,0x5450
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon fcntl,F_DUPFD_CLOEXEC,0x0406,67,17,10,12,0
|
||||
.syscon fcntl,F_DUPFD_CLOEXEC,0x0406,67,17,10,12,0x0406
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon misc,HUPCL,0x0400,0x4000,0x4000,0x4000,0x4000,0
|
||||
.syscon termios,HUPCL,0x0400,0x4000,0x4000,0x4000,0x4000,0
|
||||
|
|
2
libc/sysv/consts/O_EXLOCK.S
Normal file
2
libc/sysv/consts/O_EXLOCK.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon open,O_EXLOCK,0,0x00000020,0x00000020,0x00000020,0x00000020,0
|
2
libc/sysv/consts/O_SEARCH.S
Normal file
2
libc/sysv/consts/O_SEARCH.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon open,O_SEARCH,0,0,0x00040000,0,0x00800000,0
|
2
libc/sysv/consts/O_SHLOCK.S
Normal file
2
libc/sysv/consts/O_SHLOCK.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon open,O_SHLOCK,0,0x00000010,0x00000010,0x00000010,0x00000010,0
|
2
libc/sysv/consts/RLIMIT_NPTS.S
Normal file
2
libc/sysv/consts/RLIMIT_NPTS.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon rlimit,RLIMIT_NPTS,127,127,11,127,127,127
|
2
libc/sysv/consts/RLIMIT_RTTIME.S
Normal file
2
libc/sysv/consts/RLIMIT_RTTIME.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon rlimit,RLIMIT_RTTIME,15,127,127,127,127,127
|
2
libc/sysv/consts/RLIMIT_SBSIZE.S
Normal file
2
libc/sysv/consts/RLIMIT_SBSIZE.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon rlimit,RLIMIT_SBSIZE,127,127,9,127,127,127
|
2
libc/sysv/consts/RLIMIT_SWAP.S
Normal file
2
libc/sysv/consts/RLIMIT_SWAP.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon rlimit,RLIMIT_SWAP,127,127,12,127,127,127
|
2
libc/sysv/consts/RUSAGE_BOTH.S
Normal file
2
libc/sysv/consts/RUSAGE_BOTH.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon rusage,RUSAGE_BOTH,-2,99,99,99,99,99
|
2
libc/sysv/consts/SF_MNOWAIT.S
Normal file
2
libc/sysv/consts/SF_MNOWAIT.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon sf,SF_MNOWAIT,0,0,2,0,0,0
|
2
libc/sysv/consts/SF_NODISKIO.S
Normal file
2
libc/sysv/consts/SF_NODISKIO.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon sf,SF_NODISKIO,0,0,1,0,0,0
|
2
libc/sysv/consts/SF_SYNC.S
Normal file
2
libc/sysv/consts/SF_SYNC.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon sf,SF_SYNC,0,0,4,0,0,0
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon statvfs,ST_NOATIME,0x0400,0,0,0,0,0
|
||||
.syscon statvfs,ST_NOATIME,0x0400,0,0,0x04000000,0,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon statvfs,ST_NODEV,4,0,0,0,0,0
|
||||
.syscon statvfs,ST_NODEV,4,0,0,0,0x00000010,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon statvfs,ST_NOEXEC,8,0,0,0,0,0
|
||||
.syscon statvfs,ST_NOEXEC,8,0,0,0,4,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon statvfs,ST_RELATIME,0x1000,0,0,0,0,0
|
||||
.syscon statvfs,ST_RELATIME,0x1000,0,0,0,0x00020000,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon statvfs,ST_SYNCHRONOUS,0x10,0,0,0,0,0
|
||||
.syscon statvfs,ST_SYNCHRONOUS,0x10,0,0,0,2,0
|
||||
|
|
2
libc/sysv/consts/TCSBRK.S
Normal file
2
libc/sysv/consts/TCSBRK.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon termios,TCSBRK,0x5409,0x2000745e,0x2000745e,0x2000745e,0x2000745e,0
|
2
libc/sysv/consts/TCXONC.S
Normal file
2
libc/sysv/consts/TCXONC.S
Normal file
|
@ -0,0 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon termios,TCXONC,0x540A,0,0,0,0,0
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon termios,TIOCDRAIN,0,0x2000745e,0x2000745e,0x2000745e,0x2000745e,0
|
||||
.syscon termios,TIOCDRAIN,0x5409,0x2000745e,0x2000745e,0x2000745e,0x2000745e,0
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
#include "libc/sysv/consts/syscon.internal.h"
|
||||
.syscon termios,TIOCGSID,0x5429,0,0x40047463,0x40047463,0x40047463,0
|
||||
.syscon termios,TIOCGSID,0x5429,0x40047463,0x40047463,0x40047463,0x40047463,0
|
||||
|
|
70
libc/sysv/consts/baud.h
Normal file
70
libc/sysv/consts/baud.h
Normal file
|
@ -0,0 +1,70 @@
|
|||
#ifndef COSMOPOLITAN_LIBC_SYSV_CONSTS_BAUD_H_
|
||||
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_BAUD_H_
|
||||
#include "libc/runtime/symbolic.h"
|
||||
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
extern const long B0;
|
||||
extern const long B50;
|
||||
extern const long B75;
|
||||
extern const long B110;
|
||||
extern const long B134;
|
||||
extern const long B150;
|
||||
extern const long B200;
|
||||
extern const long B300;
|
||||
extern const long B600;
|
||||
extern const long B1200;
|
||||
extern const long B1800;
|
||||
extern const long B2400;
|
||||
extern const long B4800;
|
||||
extern const long B9600;
|
||||
extern const long B19200;
|
||||
extern const long B38400;
|
||||
extern const long B57600;
|
||||
extern const long B115200;
|
||||
extern const long B230400;
|
||||
extern const long B500000;
|
||||
extern const long B576000;
|
||||
extern const long B1000000;
|
||||
extern const long B1152000;
|
||||
extern const long B1500000;
|
||||
extern const long B2000000;
|
||||
extern const long B2500000;
|
||||
extern const long B3000000;
|
||||
extern const long B3500000;
|
||||
extern const long B4000000;
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
|
||||
#define B0 LITERALLY(0)
|
||||
#define B50 SYMBOLIC(B50)
|
||||
#define B75 SYMBOLIC(B75)
|
||||
#define B110 SYMBOLIC(B110)
|
||||
#define B134 SYMBOLIC(B134)
|
||||
#define B150 SYMBOLIC(B150)
|
||||
#define B200 SYMBOLIC(B200)
|
||||
#define B300 SYMBOLIC(B300)
|
||||
#define B600 SYMBOLIC(B600)
|
||||
#define B1200 SYMBOLIC(B1200)
|
||||
#define B1800 SYMBOLIC(B1800)
|
||||
#define B2400 SYMBOLIC(B2400)
|
||||
#define B4800 SYMBOLIC(B4800)
|
||||
#define B9600 SYMBOLIC(B9600)
|
||||
#define B19200 SYMBOLIC(B19200)
|
||||
#define B38400 SYMBOLIC(B38400)
|
||||
#define B57600 SYMBOLIC(B57600)
|
||||
#define B115200 SYMBOLIC(B115200)
|
||||
#define B230400 SYMBOLIC(B230400)
|
||||
#define B500000 SYMBOLIC(B500000)
|
||||
#define B576000 SYMBOLIC(B576000)
|
||||
#define B1000000 SYMBOLIC(B1000000)
|
||||
#define B1152000 SYMBOLIC(B1152000)
|
||||
#define B1500000 SYMBOLIC(B1500000)
|
||||
#define B2000000 SYMBOLIC(B2000000)
|
||||
#define B2500000 SYMBOLIC(B2500000)
|
||||
#define B3000000 SYMBOLIC(B3000000)
|
||||
#define B3500000 SYMBOLIC(B3500000)
|
||||
#define B4000000 SYMBOLIC(B4000000)
|
||||
|
||||
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_BAUD_H_ */
|
|
@ -4,15 +4,19 @@
|
|||
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
extern const long FIONBIO;
|
||||
extern const long FIONREAD;
|
||||
extern const long FIOASYNC;
|
||||
extern const long FIOCLEX;
|
||||
extern const long FIONBIO;
|
||||
extern const long FIONCLEX;
|
||||
extern const long FIONREAD;
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
|
||||
#define FIONBIO SYMBOLIC(FIONBIO)
|
||||
#define FIONREAD SYMBOLIC(FIONREAD)
|
||||
#define FIOASYNC SYMBOLIC(FIOASYNC)
|
||||
#define FIOCLEX SYMBOLIC(FIOCLEX)
|
||||
#define FIONBIO SYMBOLIC(FIONBIO)
|
||||
#define FIONCLEX SYMBOLIC(FIONCLEX)
|
||||
#define FIONREAD SYMBOLIC(FIONREAD)
|
||||
|
||||
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_FIO_H_ */
|
||||
|
|
|
@ -14,6 +14,7 @@ extern const long O_DIRECTORY;
|
|||
extern const long O_DSYNC;
|
||||
extern const long O_EXCL;
|
||||
extern const long O_EXEC;
|
||||
extern const long O_EXLOCK;
|
||||
extern const long O_LARGEFILE;
|
||||
extern const long O_NDELAY;
|
||||
extern const long O_NOATIME;
|
||||
|
@ -24,6 +25,8 @@ extern const long O_PATH;
|
|||
extern const long O_RDONLY;
|
||||
extern const long O_RDWR;
|
||||
extern const long O_RSYNC;
|
||||
extern const long O_SEARCH;
|
||||
extern const long O_SHLOCK;
|
||||
extern const long O_SPARSE;
|
||||
extern const long O_SYNC;
|
||||
extern const long O_TMPFILE;
|
||||
|
@ -34,31 +37,34 @@ extern const long O_WRONLY;
|
|||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
|
||||
#define O_ACCMODE SYMBOLIC(O_ACCMODE)
|
||||
#define O_APPEND SYMBOLIC(O_APPEND)
|
||||
#define O_ASYNC SYMBOLIC(O_ASYNC)
|
||||
#define O_CLOEXEC SYMBOLIC(O_CLOEXEC)
|
||||
#define O_CREAT SYMBOLIC(O_CREAT)
|
||||
#define O_DIRECT SYMBOLIC(O_DIRECT)
|
||||
#define O_ACCMODE SYMBOLIC(O_ACCMODE)
|
||||
#define O_APPEND SYMBOLIC(O_APPEND)
|
||||
#define O_ASYNC SYMBOLIC(O_ASYNC)
|
||||
#define O_CLOEXEC SYMBOLIC(O_CLOEXEC)
|
||||
#define O_CREAT SYMBOLIC(O_CREAT)
|
||||
#define O_DIRECT SYMBOLIC(O_DIRECT)
|
||||
#define O_DIRECTORY SYMBOLIC(O_DIRECTORY)
|
||||
#define O_DSYNC SYMBOLIC(O_DSYNC)
|
||||
#define O_EXCL SYMBOLIC(O_EXCL)
|
||||
#define O_EXEC SYMBOLIC(O_EXEC)
|
||||
#define O_DSYNC SYMBOLIC(O_DSYNC)
|
||||
#define O_EXCL SYMBOLIC(O_EXCL)
|
||||
#define O_EXEC SYMBOLIC(O_EXEC)
|
||||
#define O_EXLOCK SYMBOLIC(O_EXLOCK)
|
||||
#define O_LARGEFILE SYMBOLIC(O_LARGEFILE)
|
||||
#define O_NDELAY SYMBOLIC(O_NDELAY)
|
||||
#define O_NOATIME SYMBOLIC(O_NOATIME)
|
||||
#define O_NOCTTY SYMBOLIC(O_NOCTTY)
|
||||
#define O_NOFOLLOW SYMBOLIC(O_NOFOLLOW)
|
||||
#define O_NONBLOCK SYMBOLIC(O_NONBLOCK)
|
||||
#define O_PATH SYMBOLIC(O_PATH)
|
||||
#define O_RDONLY SYMBOLIC(O_RDONLY)
|
||||
#define O_RDWR SYMBOLIC(O_RDWR)
|
||||
#define O_RSYNC SYMBOLIC(O_RSYNC)
|
||||
#define O_SPARSE SYMBOLIC(O_SPARSE)
|
||||
#define O_SYNC SYMBOLIC(O_SYNC)
|
||||
#define O_TMPFILE SYMBOLIC(O_TMPFILE)
|
||||
#define O_TRUNC SYMBOLIC(O_TRUNC)
|
||||
#define O_TTY_INIT SYMBOLIC(O_TTY_INIT)
|
||||
#define O_WRONLY SYMBOLIC(O_WRONLY)
|
||||
#define O_NDELAY SYMBOLIC(O_NDELAY)
|
||||
#define O_NOATIME SYMBOLIC(O_NOATIME)
|
||||
#define O_NOCTTY SYMBOLIC(O_NOCTTY)
|
||||
#define O_NOFOLLOW SYMBOLIC(O_NOFOLLOW)
|
||||
#define O_NONBLOCK SYMBOLIC(O_NONBLOCK)
|
||||
#define O_PATH SYMBOLIC(O_PATH)
|
||||
#define O_RDONLY SYMBOLIC(O_RDONLY)
|
||||
#define O_RDWR SYMBOLIC(O_RDWR)
|
||||
#define O_RSYNC SYMBOLIC(O_RSYNC)
|
||||
#define O_SEARCH SYMBOLIC(O_SEARCH)
|
||||
#define O_SHLOCK SYMBOLIC(O_SHLOCK)
|
||||
#define O_SPARSE SYMBOLIC(O_SPARSE)
|
||||
#define O_SYNC SYMBOLIC(O_SYNC)
|
||||
#define O_TMPFILE SYMBOLIC(O_TMPFILE)
|
||||
#define O_TRUNC SYMBOLIC(O_TRUNC)
|
||||
#define O_TTY_INIT SYMBOLIC(O_TTY_INIT)
|
||||
#define O_WRONLY SYMBOLIC(O_WRONLY)
|
||||
|
||||
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_O_H_ */
|
||||
|
|
|
@ -13,10 +13,14 @@
|
|||
#define RLIMIT_NICE SYMBOLIC(RLIMIT_NICE)
|
||||
#define RLIMIT_NOFILE SYMBOLIC(RLIMIT_NOFILE)
|
||||
#define RLIMIT_NPROC SYMBOLIC(RLIMIT_NPROC)
|
||||
#define RLIMIT_NPTS SYMBOLIC(RLIMIT_NPTS)
|
||||
#define RLIMIT_RSS SYMBOLIC(RLIMIT_RSS)
|
||||
#define RLIMIT_RTPRIO SYMBOLIC(RLIMIT_RTPRIO)
|
||||
#define RLIMIT_RTTIME SYMBOLIC(RLIMIT_RTTIME)
|
||||
#define RLIMIT_SBSIZE SYMBOLIC(RLIMIT_SBSIZE)
|
||||
#define RLIMIT_SIGPENDING SYMBOLIC(RLIMIT_SIGPENDING)
|
||||
#define RLIMIT_STACK SYMBOLIC(RLIMIT_STACK)
|
||||
#define RLIMIT_SWAP SYMBOLIC(RLIMIT_SWAP)
|
||||
#define RLIMIT_VMEM SYMBOLIC(RLIMIT_VMEM)
|
||||
|
||||
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
||||
|
@ -33,10 +37,14 @@ extern const long RLIMIT_MSGQUEUE;
|
|||
extern const long RLIMIT_NICE;
|
||||
extern const long RLIMIT_NOFILE;
|
||||
extern const long RLIMIT_NPROC;
|
||||
extern const long RLIMIT_NPTS;
|
||||
extern const long RLIMIT_RSS;
|
||||
extern const long RLIMIT_RTPRIO;
|
||||
extern const long RLIMIT_RTTIME;
|
||||
extern const long RLIMIT_SBSIZE;
|
||||
extern const long RLIMIT_SIGPENDING;
|
||||
extern const long RLIMIT_STACK;
|
||||
extern const long RLIMIT_SWAP;
|
||||
extern const long RLIMIT_VMEM;
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
extern const long RUSAGE_BOTH;
|
||||
extern const long RUSAGE_CHILDREN;
|
||||
extern const long RUSAGE_SELF;
|
||||
extern const long RUSAGE_THREAD;
|
||||
|
@ -11,8 +12,9 @@ extern const long RUSAGE_THREAD;
|
|||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
|
||||
#define RUSAGE_SELF LITERALLY(0)
|
||||
#define RUSAGE_BOTH SYMBOLIC(RUSAGE_BOTH)
|
||||
#define RUSAGE_CHILDREN SYMBOLIC(RUSAGE_CHILDREN)
|
||||
#define RUSAGE_THREAD SYMBOLIC(RUSAGE_THREAD)
|
||||
#define RUSAGE_SELF LITERALLY(0)
|
||||
#define RUSAGE_THREAD SYMBOLIC(RUSAGE_THREAD)
|
||||
|
||||
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_RUSAGE_H_ */
|
||||
|
|
25
libc/sysv/consts/sf.h
Normal file
25
libc/sysv/consts/sf.h
Normal file
|
@ -0,0 +1,25 @@
|
|||
#ifndef COSMOPOLITAN_LIBC_SYSV_CONSTS_SF_H_
|
||||
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_SF_H_
|
||||
#include "libc/runtime/symbolic.h"
|
||||
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
struct sf_hdtr {
|
||||
struct iovec *headers;
|
||||
int hdr_cnt;
|
||||
struct iovec *trailers;
|
||||
int trl_cnt;
|
||||
};
|
||||
|
||||
extern const long SF_MNOWAIT;
|
||||
extern const long SF_NODISKIO;
|
||||
extern const long SF_SYNC;
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
|
||||
#define SF_MNOWAIT SYMBOLIC(SF_MNOWAIT)
|
||||
#define SF_NODISKIO SYMBOLIC(SF_NODISKIO)
|
||||
#define SF_SYNC SYMBOLIC(SF_SYNC)
|
||||
|
||||
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_SF_H_ */
|
|
@ -5,6 +5,8 @@
|
|||
COSMOPOLITAN_C_START_
|
||||
|
||||
extern const long BRKINT;
|
||||
extern const long BS1;
|
||||
extern const long BS2;
|
||||
extern const long BSDLY;
|
||||
extern const long BUSY;
|
||||
extern const long CANBSIZ;
|
||||
|
@ -15,11 +17,19 @@ extern const long CEOL;
|
|||
extern const long CIBAUD;
|
||||
extern const long CLOCAL;
|
||||
extern const long CMSPAR;
|
||||
extern const long CR1;
|
||||
extern const long CR2;
|
||||
extern const long CR3;
|
||||
extern const long CRDLY;
|
||||
extern const long CREAD;
|
||||
extern const long CS5;
|
||||
extern const long CS6;
|
||||
extern const long CS7;
|
||||
extern const long CS8;
|
||||
extern const long CSIZE;
|
||||
extern const long CSTOPB;
|
||||
extern const long CSUSP;
|
||||
extern const long CWERASE;
|
||||
extern const long ECHO;
|
||||
extern const long ECHOCTL;
|
||||
extern const long ECHOE;
|
||||
|
@ -29,9 +39,12 @@ extern const long ECHONL;
|
|||
extern const long ECHOPRT;
|
||||
extern const long ENDRUNDISC;
|
||||
extern const long EXTPROC;
|
||||
extern const long FF1;
|
||||
extern const long FF2;
|
||||
extern const long FFDLY;
|
||||
extern const long FLUSHO;
|
||||
extern const long H4DISC;
|
||||
extern const long HUPCL;
|
||||
extern const long ICANON;
|
||||
extern const long ICRNL;
|
||||
extern const long IEXTEN;
|
||||
|
@ -50,6 +63,9 @@ extern const long IXOFF;
|
|||
extern const long IXON;
|
||||
extern const long NCCS;
|
||||
extern const long NETGRAPHDISC;
|
||||
extern const long NL1;
|
||||
extern const long NL2;
|
||||
extern const long NL3;
|
||||
extern const long NLDLY;
|
||||
extern const long NMEADISC;
|
||||
extern const long NOFLSH;
|
||||
|
@ -68,15 +84,28 @@ extern const long PENDIN;
|
|||
extern const long PPPDISC;
|
||||
extern const long SLIPDISC;
|
||||
extern const long STRIPDISC;
|
||||
extern const long TAB1;
|
||||
extern const long TAB2;
|
||||
extern const long TAB3;
|
||||
extern const long TABDLY;
|
||||
extern const long TABLDISC;
|
||||
extern const long TCFLSH;
|
||||
extern const long TCGETS;
|
||||
extern const long TCIFLUSH;
|
||||
extern const long TCIOFF;
|
||||
extern const long TCIOFLUSH;
|
||||
extern const long TCION;
|
||||
extern const long TCOFLUSH;
|
||||
extern const long TCOOFF;
|
||||
extern const long TCOON;
|
||||
extern const long TCSADRAIN;
|
||||
extern const long TCSAFLUSH;
|
||||
extern const long TCSANOW;
|
||||
extern const long TCSBRK;
|
||||
extern const long TCSETS;
|
||||
extern const long TCSETSF;
|
||||
extern const long TCSETSW;
|
||||
extern const long TCXONC;
|
||||
extern const long TIOCCBRK;
|
||||
extern const long TIOCCDTR;
|
||||
extern const long TIOCCHKVERAUTH;
|
||||
|
@ -125,8 +154,8 @@ extern const long TOSTOP;
|
|||
extern const long TTYDISC;
|
||||
extern const long VDISCARD;
|
||||
extern const long VEOF;
|
||||
extern const long VEOL;
|
||||
extern const long VEOL2;
|
||||
extern const long VEOL;
|
||||
extern const long VERASE;
|
||||
extern const long VERIFY;
|
||||
extern const long VINTR;
|
||||
|
@ -139,10 +168,13 @@ extern const long VSTART;
|
|||
extern const long VSTOP;
|
||||
extern const long VSUSP;
|
||||
extern const long VSWTC;
|
||||
extern const long VT1;
|
||||
extern const long VT2;
|
||||
extern const long VTDLY;
|
||||
extern const long VTIME;
|
||||
extern const long VWERASE;
|
||||
extern const long XCASE;
|
||||
extern const long XTABS;
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
|
@ -198,10 +230,15 @@ COSMOPOLITAN_C_END_
|
|||
#define CIBAUD SYMBOLIC(CIBAUD)
|
||||
#define CLOCAL SYMBOLIC(CLOCAL)
|
||||
#define CMSPAR SYMBOLIC(CMSPAR)
|
||||
#define CREAD SYMBOLIC(CREAD)
|
||||
#define CS5 SYMBOLIC(CS5)
|
||||
#define CS6 SYMBOLIC(CS6)
|
||||
#define CS7 SYMBOLIC(CS7)
|
||||
#define CS8 SYMBOLIC(CS8)
|
||||
#define CSIZE SYMBOLIC(CSIZE)
|
||||
#define CSTOPB SYMBOLIC(CSTOPB)
|
||||
#define CSUSP SYMBOLIC(CSUSP)
|
||||
#define CWERASE SYMBOLIC(CWERASE)
|
||||
#define ECHO LITERALLY(8)
|
||||
#define ECHOCTL SYMBOLIC(ECHOCTL)
|
||||
#define ECHOE SYMBOLIC(ECHOE)
|
||||
|
@ -213,6 +250,7 @@ COSMOPOLITAN_C_END_
|
|||
#define EXTPROC SYMBOLIC(EXTPROC)
|
||||
#define FLUSHO SYMBOLIC(FLUSHO)
|
||||
#define H4DISC SYMBOLIC(H4DISC)
|
||||
#define HUPCL SYMBOLIC(HUPCL)
|
||||
#define ICANON SYMBOLIC(ICANON)
|
||||
#define IEXTEN SYMBOLIC(IEXTEN)
|
||||
#define ISIG SYMBOLIC(ISIG)
|
||||
|
@ -238,13 +276,24 @@ COSMOPOLITAN_C_END_
|
|||
#define SLIPDISC SYMBOLIC(SLIPDISC)
|
||||
#define STRIPDISC SYMBOLIC(STRIPDISC)
|
||||
#define TABLDISC SYMBOLIC(TABLDISC)
|
||||
#define TCFLSH SYMBOLIC(TCFLSH)
|
||||
#define TCFLSH SYMBOLIC(TCFLSH)
|
||||
#define TCGETS SYMBOLIC(TCGETS)
|
||||
#define TCSANOW LITERALLY(0)
|
||||
#define TCIFLUSH SYMBOLIC(TCIFLUSH)
|
||||
#define TCIOFF SYMBOLIC(TCIOFF)
|
||||
#define TCIOFLUSH SYMBOLIC(TCIOFLUSH)
|
||||
#define TCION SYMBOLIC(TCION)
|
||||
#define TCOFLUSH SYMBOLIC(TCOFLUSH)
|
||||
#define TCOOFF SYMBOLIC(TCOOFF)
|
||||
#define TCOON SYMBOLIC(TCOON)
|
||||
#define TCSADRAIN LITERALLY(1)
|
||||
#define TCSAFLUSH LITERALLY(2)
|
||||
#define TCSANOW LITERALLY(0)
|
||||
#define TCSBRK SYMBOLIC(TCSBRK)
|
||||
#define TCSETS SYMBOLIC(TCSETS)
|
||||
#define TCSETSF SYMBOLIC(TCSETSF)
|
||||
#define TCSETSW SYMBOLIC(TCSETSW)
|
||||
#define TCXONC SYMBOLIC(TCXONC)
|
||||
#define TIOCCBRK SYMBOLIC(TIOCCBRK)
|
||||
#define TIOCCDTR SYMBOLIC(TIOCCDTR)
|
||||
#define TIOCCHKVERAUTH SYMBOLIC(TIOCCHKVERAUTH)
|
||||
|
|
18
libc/sysv/consts/waitid.h
Normal file
18
libc/sysv/consts/waitid.h
Normal file
|
@ -0,0 +1,18 @@
|
|||
#ifndef COSMOPOLITAN_LIBC_SYSV_CONSTS_WAITID_H_
|
||||
#define COSMOPOLITAN_LIBC_SYSV_CONSTS_WAITID_H_
|
||||
#include "libc/runtime/symbolic.h"
|
||||
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
extern const long WEXITED;
|
||||
extern const long WSTOPPED;
|
||||
extern const long WNOWAIT;
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
|
||||
#define WEXITED SYMBOLIC(WEXITED)
|
||||
#define WSTOPPED SYMBOLIC(WSTOPPED)
|
||||
#define WNOWAIT SYMBOLIC(WNOWAIT)
|
||||
|
||||
#endif /* COSMOPOLITAN_LIBC_SYSV_CONSTS_WAITID_H_ */
|
Loading…
Add table
Add a link
Reference in a new issue