mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-06-27 06:48:31 +00:00
Make some foss compatibility improvements
This commit is contained in:
parent
8111462789
commit
5af19b7eed
34 changed files with 319 additions and 48 deletions
11
libc/isystem/linux/limits.h
Normal file
11
libc/isystem/linux/limits.h
Normal file
|
@ -0,0 +1,11 @@
|
|||
#ifndef COSMOPOLITAN_LIBC_ISYSTEM_LINUX_LIMITS_H_
|
||||
#define COSMOPOLITAN_LIBC_ISYSTEM_LINUX_LIMITS_H_
|
||||
#include "libc/sysv/consts/limits.h"
|
||||
|
||||
#define NR_OPEN 1024
|
||||
#define XATTR_NAME_MAX 255
|
||||
#define XATTR_SIZE_MAX 65536
|
||||
#define XATTR_LIST_MAX 65536
|
||||
#define RTSIG_MAX 32
|
||||
|
||||
#endif /* COSMOPOLITAN_LIBC_ISYSTEM_LINUX_LIMITS_H_ */
|
25
libc/isystem/linux/types.h
Normal file
25
libc/isystem/linux/types.h
Normal file
|
@ -0,0 +1,25 @@
|
|||
#ifndef COSMOPOLITAN_LIBC_ISYSTEM_LINUX_TYPES_H_
|
||||
#define COSMOPOLITAN_LIBC_ISYSTEM_LINUX_TYPES_H_
|
||||
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
||||
COSMOPOLITAN_C_START_
|
||||
|
||||
typedef uint16_t __u16;
|
||||
typedef uint32_t __u32;
|
||||
typedef uint64_t __u64;
|
||||
|
||||
typedef __u16 __le16;
|
||||
typedef __u16 __be16;
|
||||
typedef __u32 __le32;
|
||||
typedef __u32 __be32;
|
||||
typedef __u64 __le64;
|
||||
typedef __u64 __be64;
|
||||
typedef __u16 __sum16;
|
||||
typedef __u32 __wsum;
|
||||
|
||||
#define __aligned_u64 __u64 __attribute__((__aligned__(8)))
|
||||
#define __aligned_be64 __be64 __attribute__((__aligned__(8)))
|
||||
#define __aligned_le64 __le64 __attribute__((__aligned__(8)))
|
||||
|
||||
COSMOPOLITAN_C_END_
|
||||
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
||||
#endif /* COSMOPOLITAN_LIBC_ISYSTEM_LINUX_TYPES_H_ */
|
Loading…
Add table
Add a link
Reference in a new issue