Skip to content

update musl from v1.2.3 to v1.2.4 #16098

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jun 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/aio.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ int aio_fsync(int, struct aiocb *);

int lio_listio(int, struct aiocb *__restrict const *__restrict, int, struct sigevent *__restrict);

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define aiocb64 aiocb
#define aio_read64 aio_read
#define aio_write64 aio_write
Expand Down
71 changes: 71 additions & 0 deletions lib/libc/include/generic-musl/arpa/nameser.h
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,36 @@ typedef enum __ns_type {
ns_t_sink = 40,
ns_t_opt = 41,
ns_t_apl = 42,
ns_t_ds = 43,
ns_t_sshfp = 44,
ns_t_ipseckey = 45,
ns_t_rrsig = 46,
ns_t_nsec = 47,
ns_t_dnskey = 48,
ns_t_dhcid = 49,
ns_t_nsec3 = 50,
ns_t_nsec3param = 51,
ns_t_tlsa = 52,
ns_t_smimea = 53,
ns_t_hip = 55,
ns_t_ninfo = 56,
ns_t_rkey = 57,
ns_t_talink = 58,
ns_t_cds = 59,
ns_t_cdnskey = 60,
ns_t_openpgpkey = 61,
ns_t_csync = 62,
ns_t_spf = 99,
ns_t_uinfo = 100,
ns_t_uid = 101,
ns_t_gid = 102,
ns_t_unspec = 103,
ns_t_nid = 104,
ns_t_l32 = 105,
ns_t_l64 = 106,
ns_t_lp = 107,
ns_t_eui48 = 108,
ns_t_eui64 = 109,
ns_t_tkey = 249,
ns_t_tsig = 250,
ns_t_ixfr = 251,
Expand All @@ -196,6 +226,11 @@ typedef enum __ns_type {
ns_t_maila = 254,
ns_t_any = 255,
ns_t_zxfr = 256,
ns_t_uri = 256,
ns_t_caa = 257,
ns_t_avc = 258,
ns_t_ta = 32768,
ns_t_dlv = 32769,
ns_t_max = 65536
} ns_type;

Expand Down Expand Up @@ -430,12 +465,48 @@ typedef struct {
#define T_NAPTR ns_t_naptr
#define T_A6 ns_t_a6
#define T_DNAME ns_t_dname
#define T_DS ns_t_ds
#define T_SSHFP ns_t_sshfp
#define T_IPSECKEY ns_t_ipseckey
#define T_RRSIG ns_t_rrsig
#define T_NSEC ns_t_nsec
#define T_DNSKEY ns_t_dnskey
#define T_DHCID ns_t_dhcid
#define T_NSEC3 ns_t_nsec3
#define T_NSEC3PARAM ns_t_nsec3param
#define T_TLSA ns_t_tlsa
#define T_SMIMEA ns_t_smimea
#define T_HIP ns_t_hip
#define T_NINFO ns_t_ninfo
#define T_RKEY ns_t_rkey
#define T_TALINK ns_t_talink
#define T_CDS ns_t_cds
#define T_CDNSKEY ns_t_cdnskey
#define T_OPENPGPKEY ns_t_openpgpkey
#define T_CSYNC ns_t_csync
#define T_SPF ns_t_spf
#define T_UINFO ns_t_uinfo
#define T_UID ns_t_uid
#define T_GID ns_t_gid
#define T_UNSPEC ns_t_unspec
#define T_NID ns_t_nid
#define T_L32 ns_t_l32
#define T_L64 ns_t_l64
#define T_LP ns_t_lp
#define T_EUI48 ns_t_eui48
#define T_EUI64 ns_t_eui64
#define T_TKEY ns_t_tkey
#define T_TSIG ns_t_tsig
#define T_IXFR ns_t_ixfr
#define T_AXFR ns_t_axfr
#define T_MAILB ns_t_mailb
#define T_MAILA ns_t_maila
#define T_ANY ns_t_any
#define T_URI ns_t_uri
#define T_CAA ns_t_caa
#define T_AVC ns_t_avc
#define T_TA ns_t_ta
#define T_DLV ns_t_dlv

#define C_IN ns_c_in
#define C_CHAOS ns_c_chaos
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/dirent.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ int getdents(int, struct dirent *, size_t);
int versionsort(const struct dirent **, const struct dirent **);
#endif

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define dirent64 dirent
#define readdir64 readdir
#define readdir64_r readdir_r
Expand Down
9 changes: 7 additions & 2 deletions lib/libc/include/generic-musl/elf.h
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,8 @@ typedef struct {
#define SHT_PREINIT_ARRAY 16
#define SHT_GROUP 17
#define SHT_SYMTAB_SHNDX 18
#define SHT_NUM 19
#define SHT_RELR 19
#define SHT_NUM 20
#define SHT_LOOS 0x60000000
#define SHT_GNU_ATTRIBUTES 0x6ffffff5
#define SHT_GNU_HASH 0x6ffffff6
Expand Down Expand Up @@ -436,6 +437,7 @@ typedef struct {
} Elf64_Chdr;

#define ELFCOMPRESS_ZLIB 1
#define ELFCOMPRESS_ZSTD 2
#define ELFCOMPRESS_LOOS 0x60000000
#define ELFCOMPRESS_HIOS 0x6fffffff
#define ELFCOMPRESS_LOPROC 0x70000000
Expand Down Expand Up @@ -754,7 +756,10 @@ typedef struct {
#define DT_PREINIT_ARRAY 32
#define DT_PREINIT_ARRAYSZ 33
#define DT_SYMTAB_SHNDX 34
#define DT_NUM 35
#define DT_RELRSZ 35
#define DT_RELR 36
#define DT_RELRENT 37
#define DT_NUM 38
#define DT_LOOS 0x6000000d
#define DT_HIOS 0x6ffff000
#define DT_LOPROC 0x70000000
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/fcntl.h
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ ssize_t tee(int, int, size_t, unsigned);
#define loff_t off_t
#endif

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define F_GETLK64 F_GETLK
#define F_SETLK64 F_SETLK
#define F_SETLKW64 F_SETLKW
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/ftw.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ struct FTW {
int ftw(const char *, int (*)(const char *, const struct stat *, int), int);
int nftw(const char *, int (*)(const char *, const struct stat *, int, struct FTW *), int, int);

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define ftw64 ftw
#define nftw64 nftw
#endif
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/glob.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ void globfree(glob_t *);
#define GLOB_NOMATCH 3
#define GLOB_NOSYS 4

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define glob64 glob
#define globfree64 globfree
#define glob64_t glob_t
Expand Down
1 change: 1 addition & 0 deletions lib/libc/include/generic-musl/netdb.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ struct addrinfo {
#define EAI_NONAME -2
#define EAI_AGAIN -3
#define EAI_FAIL -4
#define EAI_NODATA -5
#define EAI_FAMILY -6
#define EAI_SOCKTYPE -7
#define EAI_SERVICE -8
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sched.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ __CPU_op_func_S(XOR, ^)
#define CPU_ALLOC(n) ((cpu_set_t *)calloc(1,CPU_ALLOC_SIZE(n)))
#define CPU_FREE(set) free(set)

#define CPU_SETSIZE 128
#define CPU_SETSIZE 1024

#define CPU_SET(i, set) CPU_SET_S(i,sizeof(cpu_set_t),set)
#define CPU_CLR(i, set) CPU_CLR_S(i,sizeof(cpu_set_t),set)
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/stdio.h
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ typedef struct _IO_cookie_io_functions_t {
FILE *fopencookie(void *, const char *, cookie_io_functions_t);
#endif

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define tmpfile64 tmpfile
#define fopen64 fopen
#define freopen64 freopen
Expand Down
4 changes: 2 additions & 2 deletions lib/libc/include/generic-musl/stdlib.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ size_t __ctype_get_mb_cur_max(void);
#define WTERMSIG(s) ((s) & 0x7f)
#define WSTOPSIG(s) WEXITSTATUS(s)
#define WIFEXITED(s) (!WTERMSIG(s))
#define WIFSTOPPED(s) ((short)((((s)&0xffff)*0x10001)>>8) > 0x7f00)
#define WIFSTOPPED(s) ((short)((((s)&0xffff)*0x10001U)>>8) > 0x7f00)
#define WIFSIGNALED(s) (((s)&0xffff)-1U < 0xffu)

int posix_memalign (void **, size_t, size_t);
Expand Down Expand Up @@ -163,7 +163,7 @@ double strtod_l(const char *__restrict, char **__restrict, struct __locale_struc
long double strtold_l(const char *__restrict, char **__restrict, struct __locale_struct *);
#endif

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define mkstemp64 mkstemp
#define mkostemp64 mkostemp
#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/string.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ char *strsignal(int);
char *strerror_l (int, locale_t);
int strcoll_l (const char *, const char *, locale_t);
size_t strxfrm_l (char *__restrict, const char *__restrict, size_t, locale_t);
void *memmem(const void *, size_t, const void *, size_t);
#endif

#if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) \
Expand All @@ -92,7 +93,6 @@ void explicit_bzero (void *, size_t);
int strverscmp (const char *, const char *);
char *strchrnul(const char *, int);
char *strcasestr(const char *, const char *);
void *memmem(const void *, size_t, const void *, size_t);
void *memrchr(const void *, int, size_t);
void *mempcpy(void *, const void *, size_t);
#ifndef __cplusplus
Expand Down
1 change: 1 addition & 0 deletions lib/libc/include/generic-musl/strings.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
extern "C" {
#endif

#include <features.h>

#define __NEED_size_t
#define __NEED_locale_t
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/mman.h
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ int mincore (void *, size_t, unsigned char *);
int shm_open (const char *, int, mode_t);
int shm_unlink (const char *);

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define mmap64 mmap
#define off64_t off_t
#endif
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/resource.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ int prlimit(pid_t, int, const struct rlimit *, struct rlimit *);

#define RLIM_NLIMITS RLIMIT_NLIMITS

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define RLIM64_INFINITY RLIM_INFINITY
#define RLIM64_SAVED_CUR RLIM_SAVED_CUR
#define RLIM64_SAVED_MAX RLIM_SAVED_MAX
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/sendfile.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ extern "C" {

ssize_t sendfile(int, int, off_t *, size_t);

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define sendfile64 sendfile
#define off64_t off_t
#endif
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/stat.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ int lchmod(const char *, mode_t);
#define S_IEXEC S_IXUSR
#endif

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define stat64 stat
#define fstat64 fstat
#define lstat64 lstat
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/statfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ typedef struct __fsid_t {
int statfs (const char *, struct statfs *);
int fstatfs (int, struct statfs *);

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define statfs64 statfs
#define fstatfs64 fstatfs
#define fsblkcnt64_t fsblkcnt_t
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/statvfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ int fstatvfs (int, struct statvfs *);
#define ST_NODIRATIME 2048
#define ST_RELATIME 4096

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define statvfs64 statvfs
#define fstatvfs64 fstatvfs
#define fsblkcnt64_t fsblkcnt_t
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ typedef unsigned long long u_quad_t;
#include <sys/select.h>
#endif

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define blkcnt64_t blkcnt_t
#define fsblkcnt64_t fsblkcnt_t
#define fsfilcnt64_t fsfilcnt_t
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/uio.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ ssize_t writev (int, const struct iovec *, int);
#if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
ssize_t preadv (int, const struct iovec *, int, off_t);
ssize_t pwritev (int, const struct iovec *, int, off_t);
#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define preadv64 preadv
#define pwritev64 pwritev
#define off64_t off_t
Expand Down
2 changes: 1 addition & 1 deletion lib/libc/include/generic-musl/sys/wait.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ pid_t wait4 (pid_t, int *, int, struct rusage *);
#define WSTOPSIG(s) WEXITSTATUS(s)
#define WCOREDUMP(s) ((s) & 0x80)
#define WIFEXITED(s) (!WTERMSIG(s))
#define WIFSTOPPED(s) ((short)((((s)&0xffff)*0x10001)>>8) > 0x7f00)
#define WIFSTOPPED(s) ((short)((((s)&0xffff)*0x10001U)>>8) > 0x7f00)
#define WIFSIGNALED(s) (((s)&0xffff)-1U < 0xffu)
#define WIFCONTINUED(s) ((s) == 0xffff)

Expand Down
6 changes: 5 additions & 1 deletion lib/libc/include/generic-musl/unistd.h
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ ssize_t copy_file_range(int, off_t *, int, off_t *, size_t, unsigned);
pid_t gettid(void);
#endif

#if defined(_LARGEFILE64_SOURCE) || defined(_GNU_SOURCE)
#if defined(_LARGEFILE64_SOURCE)
#define lseek64 lseek
#define pread64 pread
#define pwrite64 pwrite
Expand Down Expand Up @@ -425,6 +425,8 @@ pid_t gettid(void);
#define _SC_XOPEN_STREAMS 246
#define _SC_THREAD_ROBUST_PRIO_INHERIT 247
#define _SC_THREAD_ROBUST_PRIO_PROTECT 248
#define _SC_MINSIGSTKSZ 249
#define _SC_SIGSTKSZ 250

#define _CS_PATH 0
#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1
Expand Down Expand Up @@ -467,6 +469,8 @@ pid_t gettid(void);
#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147
#define _CS_V6_ENV 1148
#define _CS_V7_ENV 1149
#define _CS_POSIX_V7_THREADS_CFLAGS 1150
#define _CS_POSIX_V7_THREADS_LDFLAGS 1151

#ifdef __cplusplus
}
Expand Down
1 change: 0 additions & 1 deletion lib/libc/include/mips-linux-musl/bits/signal.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ typedef struct __ucontext {
#define SA_RESTART 0x10000000
#define SA_NODEFER 0x40000000
#define SA_RESETHAND 0x80000000
#define SA_RESTORER 0x04000000

#undef SIG_BLOCK
#undef SIG_UNBLOCK
Expand Down
1 change: 0 additions & 1 deletion lib/libc/include/mips64-linux-musl/bits/signal.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ typedef struct __ucontext {
#define SA_RESTART 0x10000000
#define SA_NODEFER 0x40000000
#define SA_RESETHAND 0x80000000
#define SA_RESTORER 0x04000000

#undef SIG_BLOCK
#undef SIG_UNBLOCK
Expand Down
1 change: 0 additions & 1 deletion lib/libc/include/riscv64-linux-musl/bits/signal.h
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ typedef struct __ucontext
#define SA_RESTART 0x10000000
#define SA_NODEFER 0x40000000
#define SA_RESETHAND 0x80000000
#define SA_RESTORER 0x04000000

#endif

Expand Down
7 changes: 7 additions & 0 deletions lib/libc/musl/arch/arm/syscall_arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -101,3 +101,10 @@ static inline long __syscall6(long n, long a, long b, long c, long d, long e, lo
#define SYSCALL_FADVISE_6_ARG

#define SYSCALL_IPC_BROKEN_MODE

#define VDSO_USEFUL
#define VDSO_CGT32_SYM "__vdso_clock_gettime"
#define VDSO_CGT32_VER "LINUX_2.6"
#define VDSO_CGT_SYM "__vdso_clock_gettime64"
#define VDSO_CGT_VER "LINUX_2.6"
#define VDSO_CGT_WORKAROUND 1
1 change: 0 additions & 1 deletion lib/libc/musl/arch/i386/arch.mak

This file was deleted.

1 change: 0 additions & 1 deletion lib/libc/musl/arch/m68k/arch.mak

This file was deleted.

1 change: 0 additions & 1 deletion lib/libc/musl/arch/mips/arch.mak

This file was deleted.

1 change: 0 additions & 1 deletion lib/libc/musl/arch/mips/bits/signal.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ typedef struct __ucontext {
#define SA_RESTART 0x10000000
#define SA_NODEFER 0x40000000
#define SA_RESETHAND 0x80000000
#define SA_RESTORER 0x04000000

#undef SIG_BLOCK
#undef SIG_UNBLOCK
Expand Down
Loading