aboutsummaryrefslogtreecommitdiffstats
path: root/main/musl
diff options
context:
space:
mode:
authorWilliam Pitcock <nenolod@dereferenced.org>2017-10-19 22:18:53 +0000
committerWilliam Pitcock <nenolod@dereferenced.org>2017-10-19 22:20:02 +0000
commit55c392b0f8dbb2b9639d975bdf2121f863785980 (patch)
treeed25c491fae597cecf1a16b87c9dda4deb873aa0 /main/musl
parent334dd84114a19a8e3025abcc6fc9afb7cb255f3f (diff)
downloadaports-55c392b0f8dbb2b9639d975bdf2121f863785980.tar.bz2
aports-55c392b0f8dbb2b9639d975bdf2121f863785980.tar.xz
main/musl: upgrade to 1.1.17
Diffstat (limited to 'main/musl')
-rw-r--r--main/musl/0001-add-_NL_LOCALE_NAME-extension-to-nl_langinfo.patch59
-rw-r--r--main/musl/0001-fix-strftime-y-for-negative-years.patch34
-rw-r--r--main/musl/0002-make-globfree-safe-after-failed-glob-from-over-lengt.patch44
-rw-r--r--main/musl/0003-reduce-impact-of-REG_-namespace-pollution-in-x86-_64.patch258
-rw-r--r--main/musl/0004-fix-getopt-_long-clobbering-of-optopt-on-success.patch82
-rw-r--r--main/musl/0005-treat-base-1-as-an-error-in-strtol-family-functions.patch31
-rw-r--r--main/musl/0006-fix-crash-from-corrupted-tls-module-list-after-faile.patch34
-rw-r--r--main/musl/0007-fix-bindtextdomain-logic-error-deactivating-other-do.patch30
-rw-r--r--main/musl/0008-fix-use-of-uninitialized-pointer-in-gettext-core.patch50
-rw-r--r--main/musl/0009-avoid-unbounded-strlen-in-gettext-functions.patch38
-rw-r--r--main/musl/0010-s390x-implement-dlsym.patch26
-rw-r--r--main/musl/0011-fix-build-regression-in-arm-atomics-asm-with-new-bin.patch40
-rw-r--r--main/musl/0012-allow-page-size-to-vary-on-arm.patch31
-rw-r--r--main/musl/0013-fix-lsearch-and-lfind-to-pass-key-as-first-arg-to-th.patch41
-rw-r--r--main/musl/0014-fix-ld-behavior-dependent-crash-in-ppc64-ldso-startu.patch28
-rw-r--r--main/musl/0015-treat-STB_WEAK-and-STB_GNU_UNIQUE-like-STB_GLOBAL-in.patch40
-rw-r--r--main/musl/0016-rework-ldso-handling-of-global-symbol-table-for-cons.patch255
-rw-r--r--main/musl/0017-reorder-addend-handling-before-symbol-lookup-in-relo.patch68
-rw-r--r--main/musl/0018-emulate-lazy-relocation-as-deferrable-relocation.patch172
-rw-r--r--main/musl/0019-fix-free-of-uninitialized-buffer-pointer-on-error-in.patch41
-rw-r--r--main/musl/0020-in-static-dl_iterate_phdr-fix-use-of-possibly-uninit.patch28
-rw-r--r--main/musl/0021-fix-possible-fd-leak-unrestored-cancellation-state-o.patch30
-rw-r--r--main/musl/0022-fix-wide-scanf-s-use-of-a-compound-literal-past-its-.patch30
-rw-r--r--main/musl/0023-fix-one-byte-overflow-in-legacy-getpass-function.patch27
-rw-r--r--main/musl/0024-avoid-loading-of-multiple-libc-versions-via-explicit.patch55
-rw-r--r--main/musl/0025-remove-unused-refcnt-field-for-shared-libraries.patch48
-rw-r--r--main/musl/0026-fix-threshold-constants-in-j0f-y0f-j1f-y1f.patch103
-rw-r--r--main/musl/0027-precalculate-gnu-hash-rather-than-doing-it-lazily-in.patch51
-rw-r--r--main/musl/0028-s390x-fix-fpreg_t-and-remove-unused-per_struct.patch40
-rw-r--r--main/musl/0029-fix-POSIX-format-TZ-dst-transition-times-for-souther.patch47
-rw-r--r--main/musl/0030-fix-dlopen-dlsym-regression-opening-libs-already-loa.patch44
-rw-r--r--main/musl/0031-s390x-provide-a-working-sigcontext-struct-definition.patch43
-rw-r--r--main/musl/0032-fix-support-for-dl_iterate_phdr-in-static-pie-binaries.patch36
-rw-r--r--main/musl/0033-fix-scalbn-when-result-is-in-the-subnormal-range.patch89
-rw-r--r--main/musl/0034-fix-regression-in-support-for-resolv.conf-attempts-o.patch32
-rw-r--r--main/musl/0035-make-ttyname-_r-return-ENODEV-rather-than-ENOENT.patch35
-rw-r--r--main/musl/0036-implement-new-posix_spawn-flag-POSIX_SPAWN_SETSID.patch44
-rw-r--r--main/musl/0037-add-no-op-POSIX_SPAWN_USEVFORK-to-spawn.h.patch27
-rw-r--r--main/musl/0038-have-posix_spawnattr_setflags-check-for-supported-fl.patch44
-rw-r--r--main/musl/0039-fix-iconv-conversions-to-legacy-8bit-encodings.patch71
-rw-r--r--main/musl/0040-fix-fchown-fallback-on-arches-without-chown-2.patch28
-rw-r--r--main/musl/0041-towupper-towlower-fast-path-for-ascii-chars.patch46
-rw-r--r--main/musl/0042-fix-glob-failure-to-match-plain-to-root-directory.patch30
-rw-r--r--main/musl/0043-catopen-set-errno-to-EOPNOTSUPP.patch29
-rw-r--r--main/musl/0044-getdate-correctly-specify-error-number.patch33
-rw-r--r--main/musl/0045-handle-mremap-failure-in-realloc-of-mmap-serviced-al.patch39
-rw-r--r--main/musl/0046-handle-localtime-errors-in-ctime.patch30
-rw-r--r--main/musl/0047-set-errno-when-getpw-_r-getgr-_r-and-getspnam_r-fail.patch74
-rw-r--r--main/musl/0048-handle-errors-from-localtime_r-in-ctime_r.patch31
-rw-r--r--main/musl/0049-fix-iconv-conversions-for-iso88592-iso885916.patch29
-rw-r--r--main/musl/0050-fix-regression-in-getspnam-_r-error-code-for-insuffi.patch28
-rw-r--r--main/musl/0051-fix-arm-run-time-abi-string-functions.patch177
-rw-r--r--main/musl/0052-ldso-avoid-spurious-possible-erroneous-work-for-libs.patch84
-rw-r--r--main/musl/0053-fix-regression-in-dlopen-promotion-from-RTLD_LOCAL-t.patch46
-rw-r--r--main/musl/0054-allow-specifying-argv-0-when-invoking-a-program-via-.patch48
-rw-r--r--main/musl/0055-reapply-va_arg-hacks-removal-to-wprintf.patch89
-rw-r--r--main/musl/0056-fix-undefined-behavior-in-free.patch34
-rw-r--r--main/musl/0057-fix-missing-volatile-qualifier-on-lock-in-__get_loca.patch25
-rw-r--r--main/musl/0058-ppc64-fix-setjmp-longjmp-handling-of-TOC-pointer.patch178
-rw-r--r--main/musl/0059-fix-erroneous-stop-before-input-limit-in-mbsnrtowcs-.patch78
-rw-r--r--main/musl/0060-fix-erroneous-acceptance-of-f4-9x-xx-xx-code-sequenc.patch30
-rw-r--r--main/musl/0061-fix-OOB-reads-in-Xbyte_memmem.patch54
-rw-r--r--main/musl/0062-free-allocations-in-clearenv.patch36
-rw-r--r--main/musl/0063-fix-undefined-behavior-in-memset-due-to-missing-sequ.patch39
-rw-r--r--main/musl/0064-handle-whitespace-before-in-scanf.patch61
-rw-r--r--main/musl/0065-make-syscall.h-consistent-with-linux.patch296
-rw-r--r--main/musl/0066-fix-signal-masking-race-in-pthread_create-with-prior.patch50
-rw-r--r--main/musl/0067-don-t-treat-numeric-port-strings-as-servent-records-.patch73
-rw-r--r--main/musl/0068-fix-glob-descent-into-.-and-.-with-GLOB_PERIOD.patch33
-rw-r--r--main/musl/0069-work-around-incorrect-EPERM-from-mmap-syscall.patch51
-rw-r--r--main/musl/0070-powerpc-64-fix-MAP_NORESERVE-and-MAP_LOCKED-in-mman..patch44
-rw-r--r--main/musl/0071-fix-use-of-memset-without-declaration-in-sched.h-cpu.patch29
-rw-r--r--main/musl/2001-thread-do-not-attempt-to-join-detached-threads-in-pt.patch32
-rw-r--r--main/musl/3001-s390x-add-bits-hwcap.h.patch36
-rw-r--r--main/musl/APKBUILD152
75 files changed, 3 insertions, 4495 deletions
diff --git a/main/musl/0001-add-_NL_LOCALE_NAME-extension-to-nl_langinfo.patch b/main/musl/0001-add-_NL_LOCALE_NAME-extension-to-nl_langinfo.patch
deleted file mode 100644
index 68b941a3aa..0000000000
--- a/main/musl/0001-add-_NL_LOCALE_NAME-extension-to-nl_langinfo.patch
+++ /dev/null
@@ -1,59 +0,0 @@
-From 947d330f68c49680dcc54439f56da2a297228962 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Mon, 31 Jul 2017 23:08:27 -0400
-Subject: [PATCH] add _NL_LOCALE_NAME extension to nl_langinfo
-
-since setlocale(cat, NULL) is required to return the setting for the
-global locale, there is no standard mechanism to obtain the name of
-the currently active thread-local locale set by uselocale. this makes
-it impossible for application/library software to load appropriate
-translations, etc. unless using the gettext implementation provided by
-libc, which has privileged access to libc internals.
-
-to fill this gap, glibc introduced the _NL_LOCALE_NAME macro which can
-be used with nl_langinfo to obtain the name. GNU gettext/gnulib code
-already use this functionality on glibc, and can easily be adapted to
-make use of it on non-glibc systems if it's available; for other
-systems they poke at locale implementation internals, which we want to
-avoid. this patch provides a compatible interface to the one glibc
-introduced.
----
- include/langinfo.h | 6 ++++++
- src/locale/langinfo.c | 4 ++++
- 2 files changed, 10 insertions(+)
-
-diff --git a/include/langinfo.h b/include/langinfo.h
-index 2153c42e..519c0612 100644
---- a/include/langinfo.h
-+++ b/include/langinfo.h
-@@ -77,6 +77,12 @@ extern "C" {
- #define YESEXPR 0x50000
- #define NOEXPR 0x50001
-
-+#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff)
-+
-+#if defined(_GNU_SOURCE)
-+#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat)
-+#endif
-+
- #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
- #define YESSTR 0x50002
- #define NOSTR 0x50003
-diff --git a/src/locale/langinfo.c b/src/locale/langinfo.c
-index b2c8569e..b16caf44 100644
---- a/src/locale/langinfo.c
-+++ b/src/locale/langinfo.c
-@@ -34,6 +34,10 @@ char *__nl_langinfo_l(nl_item item, locale_t loc)
- const char *str;
-
- if (item == CODESET) return MB_CUR_MAX==1 ? "ASCII" : "UTF-8";
-+
-+ /* _NL_LOCALE_NAME extension */
-+ if (idx == 65535 && cat < LC_ALL)
-+ return loc->cat[cat] ? (char *)loc->cat[cat]->name : "C";
-
- switch (cat) {
- case LC_NUMERIC:
---
-2.14.1
-
diff --git a/main/musl/0001-fix-strftime-y-for-negative-years.patch b/main/musl/0001-fix-strftime-y-for-negative-years.patch
deleted file mode 100644
index 85d21c7e3f..0000000000
--- a/main/musl/0001-fix-strftime-y-for-negative-years.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 61fb81e3959ecf0848eef8d2767bb80ae5d1a68e Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Mon, 2 Jan 2017 17:30:40 -0500
-Subject: [PATCH 1/2] fix strftime %y for negative years
-
-commit 583ea83541dcc6481c7a1bd1a9b485526bad84a1 fixed the case where
-tm_year is negative but the resulting year (offset by 1900) was still
-positive, which is always the case for time_t values that fit in 32
-bits, but not for arbitrary inputs.
-
-based on an earlier patch by Julien Ramseier which was overlooked at
-the time the previous fix was applied.
----
- src/time/strftime.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/time/strftime.c b/src/time/strftime.c
-index e103e02b7204..a30392044bf8 100644
---- a/src/time/strftime.c
-+++ b/src/time/strftime.c
-@@ -166,8 +166,8 @@ const char *__strftime_fmt_1(char (*s)[100], size_t *l, int f, const struct tm *
- item = T_FMT;
- goto nl_strftime;
- case 'y':
-- val = tm->tm_year % 100;
-- if (val<0) val += 100;
-+ val = (tm->tm_year + 1900LL) % 100;
-+ if (val < 0) val = -val;
- goto number;
- case 'Y':
- val = tm->tm_year + 1900LL;
---
-2.8.3
-
diff --git a/main/musl/0002-make-globfree-safe-after-failed-glob-from-over-lengt.patch b/main/musl/0002-make-globfree-safe-after-failed-glob-from-over-lengt.patch
deleted file mode 100644
index db1083531b..0000000000
--- a/main/musl/0002-make-globfree-safe-after-failed-glob-from-over-lengt.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 769f53598e781ffc89191520f3f8a93cb58db91f Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Mon, 2 Jan 2017 19:47:12 -0500
-Subject: [PATCH 2/2] make globfree safe after failed glob from over-length
- argument
-
-commit 0dc99ac413d8bc054a2e95578475c7122455eee8 added input length
-checking to avoid unsafe VLA allocation, but put it in the wrong
-place, before the glob_t structure was zeroed out. while POSIX isn't
-clear on whether it's permitted to call globfree after glob failed
-with GLOB_NOSPACE, making it safe is clearly better than letting
-uninitialized pointers get passed to free in non-conforming callers.
-
-while we're fixing this, change strlen check to the idiomatic strnlen
-version to avoid unbounded input scanning before returning an error.
----
- src/regex/glob.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/regex/glob.c b/src/regex/glob.c
-index 6affee040c31..5b6ff1247f43 100644
---- a/src/regex/glob.c
-+++ b/src/regex/glob.c
-@@ -169,8 +169,6 @@ int glob(const char *restrict pat, int flags, int (*errfunc)(const char *path, i
- d = "";
- }
-
-- if (strlen(p) > PATH_MAX) return GLOB_NOSPACE;
--
- if (!errfunc) errfunc = ignore_err;
-
- if (!(flags & GLOB_APPEND)) {
-@@ -179,6 +177,8 @@ int glob(const char *restrict pat, int flags, int (*errfunc)(const char *path, i
- g->gl_pathv = NULL;
- }
-
-+ if (strnlen(p, PATH_MAX+1) > PATH_MAX) return GLOB_NOSPACE;
-+
- if (*p) error = match_in_dir(d, p, flags, errfunc, &tail);
- if (error == GLOB_NOSPACE) {
- freelist(&head);
---
-2.8.3
-
diff --git a/main/musl/0003-reduce-impact-of-REG_-namespace-pollution-in-x86-_64.patch b/main/musl/0003-reduce-impact-of-REG_-namespace-pollution-in-x86-_64.patch
deleted file mode 100644
index da727113c1..0000000000
--- a/main/musl/0003-reduce-impact-of-REG_-namespace-pollution-in-x86-_64.patch
+++ /dev/null
@@ -1,258 +0,0 @@
-From 150747b41e1ecefe82aa45d68c84b9e957b03e29 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 4 Jan 2017 17:08:19 -0500
-Subject: [PATCH] reduce impact of REG_* namespace pollution in x86[_64]
- signal.h
-
-when _GNU_SOURCE is defined, which is always the case when compiling
-c++ with gcc, these macros for the the indices in gregset_t are
-exposed and likely to clash with applications. by using enum constants
-rather than macros defined with integer literals, we can make the
-clash slightly less likely to break software. the macros are still
-defined in case anything checks for them with #ifdef, but they're
-defined to expand to themselves so that non-file-scope (e.g.
-namespaced) identifiers by the same names still work.
-
-for the sake of avoiding mistakes, the changes were generated with sed
-via the command:
-
-sed -i -e 's/#define *\(REG_[A-Z_0-9]\{1,\}\) *\([0-9]\{1,\}\)'\
-'/enum { \1 = \2 };\n#define \1 \1/' \
-arch/i386/bits/signal.h arch/x86_64/bits/signal.h arch/x32/bits/signal.h
----
- arch/i386/bits/signal.h | 57 ++++++++++++++++++++++++++-------------
- arch/x32/bits/signal.h | 69 +++++++++++++++++++++++++++++++----------------
- arch/x86_64/bits/signal.h | 69 +++++++++++++++++++++++++++++++----------------
- 3 files changed, 130 insertions(+), 65 deletions(-)
-
-diff --git a/arch/i386/bits/signal.h b/arch/i386/bits/signal.h
-index 1f9085a5..9931ee93 100644
---- a/arch/i386/bits/signal.h
-+++ b/arch/i386/bits/signal.h
-@@ -7,25 +7,44 @@
- #endif
-
- #ifdef _GNU_SOURCE
--#define REG_GS 0
--#define REG_FS 1
--#define REG_ES 2
--#define REG_DS 3
--#define REG_EDI 4
--#define REG_ESI 5
--#define REG_EBP 6
--#define REG_ESP 7
--#define REG_EBX 8
--#define REG_EDX 9
--#define REG_ECX 10
--#define REG_EAX 11
--#define REG_TRAPNO 12
--#define REG_ERR 13
--#define REG_EIP 14
--#define REG_CS 15
--#define REG_EFL 16
--#define REG_UESP 17
--#define REG_SS 18
-+enum { REG_GS = 0 };
-+#define REG_GS REG_GS
-+enum { REG_FS = 1 };
-+#define REG_FS REG_FS
-+enum { REG_ES = 2 };
-+#define REG_ES REG_ES
-+enum { REG_DS = 3 };
-+#define REG_DS REG_DS
-+enum { REG_EDI = 4 };
-+#define REG_EDI REG_EDI
-+enum { REG_ESI = 5 };
-+#define REG_ESI REG_ESI
-+enum { REG_EBP = 6 };
-+#define REG_EBP REG_EBP
-+enum { REG_ESP = 7 };
-+#define REG_ESP REG_ESP
-+enum { REG_EBX = 8 };
-+#define REG_EBX REG_EBX
-+enum { REG_EDX = 9 };
-+#define REG_EDX REG_EDX
-+enum { REG_ECX = 10 };
-+#define REG_ECX REG_ECX
-+enum { REG_EAX = 11 };
-+#define REG_EAX REG_EAX
-+enum { REG_TRAPNO = 12 };
-+#define REG_TRAPNO REG_TRAPNO
-+enum { REG_ERR = 13 };
-+#define REG_ERR REG_ERR
-+enum { REG_EIP = 14 };
-+#define REG_EIP REG_EIP
-+enum { REG_CS = 15 };
-+#define REG_CS REG_CS
-+enum { REG_EFL = 16 };
-+#define REG_EFL REG_EFL
-+enum { REG_UESP = 17 };
-+#define REG_UESP REG_UESP
-+enum { REG_SS = 18 };
-+#define REG_SS REG_SS
- #endif
-
- #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
-diff --git a/arch/x32/bits/signal.h b/arch/x32/bits/signal.h
-index 4c4adf31..097be6f4 100644
---- a/arch/x32/bits/signal.h
-+++ b/arch/x32/bits/signal.h
-@@ -7,29 +7,52 @@
- #endif
-
- #ifdef _GNU_SOURCE
--#define REG_R8 0
--#define REG_R9 1
--#define REG_R10 2
--#define REG_R11 3
--#define REG_R12 4
--#define REG_R13 5
--#define REG_R14 6
--#define REG_R15 7
--#define REG_RDI 8
--#define REG_RSI 9
--#define REG_RBP 10
--#define REG_RBX 11
--#define REG_RDX 12
--#define REG_RAX 13
--#define REG_RCX 14
--#define REG_RSP 15
--#define REG_RIP 16
--#define REG_EFL 17
--#define REG_CSGSFS 18
--#define REG_ERR 19
--#define REG_TRAPNO 20
--#define REG_OLDMASK 21
--#define REG_CR2 22
-+enum { REG_R8 = 0 };
-+#define REG_R8 REG_R8
-+enum { REG_R9 = 1 };
-+#define REG_R9 REG_R9
-+enum { REG_R10 = 2 };
-+#define REG_R10 REG_R10
-+enum { REG_R11 = 3 };
-+#define REG_R11 REG_R11
-+enum { REG_R12 = 4 };
-+#define REG_R12 REG_R12
-+enum { REG_R13 = 5 };
-+#define REG_R13 REG_R13
-+enum { REG_R14 = 6 };
-+#define REG_R14 REG_R14
-+enum { REG_R15 = 7 };
-+#define REG_R15 REG_R15
-+enum { REG_RDI = 8 };
-+#define REG_RDI REG_RDI
-+enum { REG_RSI = 9 };
-+#define REG_RSI REG_RSI
-+enum { REG_RBP = 10 };
-+#define REG_RBP REG_RBP
-+enum { REG_RBX = 11 };
-+#define REG_RBX REG_RBX
-+enum { REG_RDX = 12 };
-+#define REG_RDX REG_RDX
-+enum { REG_RAX = 13 };
-+#define REG_RAX REG_RAX
-+enum { REG_RCX = 14 };
-+#define REG_RCX REG_RCX
-+enum { REG_RSP = 15 };
-+#define REG_RSP REG_RSP
-+enum { REG_RIP = 16 };
-+#define REG_RIP REG_RIP
-+enum { REG_EFL = 17 };
-+#define REG_EFL REG_EFL
-+enum { REG_CSGSFS = 18 };
-+#define REG_CSGSFS REG_CSGSFS
-+enum { REG_ERR = 19 };
-+#define REG_ERR REG_ERR
-+enum { REG_TRAPNO = 20 };
-+#define REG_TRAPNO REG_TRAPNO
-+enum { REG_OLDMASK = 21 };
-+#define REG_OLDMASK REG_OLDMASK
-+enum { REG_CR2 = 22 };
-+#define REG_CR2 REG_CR2
- #endif
-
- #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
-diff --git a/arch/x86_64/bits/signal.h b/arch/x86_64/bits/signal.h
-index e3c31417..c99317d3 100644
---- a/arch/x86_64/bits/signal.h
-+++ b/arch/x86_64/bits/signal.h
-@@ -7,29 +7,52 @@
- #endif
-
- #ifdef _GNU_SOURCE
--#define REG_R8 0
--#define REG_R9 1
--#define REG_R10 2
--#define REG_R11 3
--#define REG_R12 4
--#define REG_R13 5
--#define REG_R14 6
--#define REG_R15 7
--#define REG_RDI 8
--#define REG_RSI 9
--#define REG_RBP 10
--#define REG_RBX 11
--#define REG_RDX 12
--#define REG_RAX 13
--#define REG_RCX 14
--#define REG_RSP 15
--#define REG_RIP 16
--#define REG_EFL 17
--#define REG_CSGSFS 18
--#define REG_ERR 19
--#define REG_TRAPNO 20
--#define REG_OLDMASK 21
--#define REG_CR2 22
-+enum { REG_R8 = 0 };
-+#define REG_R8 REG_R8
-+enum { REG_R9 = 1 };
-+#define REG_R9 REG_R9
-+enum { REG_R10 = 2 };
-+#define REG_R10 REG_R10
-+enum { REG_R11 = 3 };
-+#define REG_R11 REG_R11
-+enum { REG_R12 = 4 };
-+#define REG_R12 REG_R12
-+enum { REG_R13 = 5 };
-+#define REG_R13 REG_R13
-+enum { REG_R14 = 6 };
-+#define REG_R14 REG_R14
-+enum { REG_R15 = 7 };
-+#define REG_R15 REG_R15
-+enum { REG_RDI = 8 };
-+#define REG_RDI REG_RDI
-+enum { REG_RSI = 9 };
-+#define REG_RSI REG_RSI
-+enum { REG_RBP = 10 };
-+#define REG_RBP REG_RBP
-+enum { REG_RBX = 11 };
-+#define REG_RBX REG_RBX
-+enum { REG_RDX = 12 };
-+#define REG_RDX REG_RDX
-+enum { REG_RAX = 13 };
-+#define REG_RAX REG_RAX
-+enum { REG_RCX = 14 };
-+#define REG_RCX REG_RCX
-+enum { REG_RSP = 15 };
-+#define REG_RSP REG_RSP
-+enum { REG_RIP = 16 };
-+#define REG_RIP REG_RIP
-+enum { REG_EFL = 17 };
-+#define REG_EFL REG_EFL
-+enum { REG_CSGSFS = 18 };
-+#define REG_CSGSFS REG_CSGSFS
-+enum { REG_ERR = 19 };
-+#define REG_ERR REG_ERR
-+enum { REG_TRAPNO = 20 };
-+#define REG_TRAPNO REG_TRAPNO
-+enum { REG_OLDMASK = 21 };
-+#define REG_OLDMASK REG_OLDMASK
-+enum { REG_CR2 = 22 };
-+#define REG_CR2 REG_CR2
- #endif
-
- #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
---
-2.11.0
-
diff --git a/main/musl/0004-fix-getopt-_long-clobbering-of-optopt-on-success.patch b/main/musl/0004-fix-getopt-_long-clobbering-of-optopt-on-success.patch
deleted file mode 100644
index ad1c637dcb..0000000000
--- a/main/musl/0004-fix-getopt-_long-clobbering-of-optopt-on-success.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-From 786fda875a901dc1807289c940338487854cd3ba Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 4 Jan 2017 19:02:02 -0500
-Subject: [PATCH] fix getopt[_long] clobbering of optopt on success
-
-getopt is only specified to modify optopt on error, and some software
-apparently infers an error from optopt!=0.
-
-getopt_long is changed analogously. the resulting behavior differs
-slightly from the behavior of the GNU implementation of getopt_long,
-which keeps an internal shadow copy of optopt and copies it to the
-public one on return, but since the GNU implementation also exhibits
-this shadow-copy behavior for plain getopt where is is non-conforming,
-I think this can reasonably be considered a bug rather than an
-intentional behavior that merits mimicing.
----
- src/misc/getopt.c | 3 ++-
- src/misc/getopt_long.c | 4 +++-
- 2 files changed, 5 insertions(+), 2 deletions(-)
-
-diff --git a/src/misc/getopt.c b/src/misc/getopt.c
-index 8290aef7..e9bab41c 100644
---- a/src/misc/getopt.c
-+++ b/src/misc/getopt.c
-@@ -60,7 +60,6 @@ int getopt(int argc, char * const argv[], const char *optstring)
- c = 0xfffd; /* replacement char */
- }
- optchar = argv[optind]+optpos;
-- optopt = c;
- optpos += k;
-
- if (!argv[optind][optpos]) {
-@@ -79,6 +78,7 @@ int getopt(int argc, char * const argv[], const char *optstring)
- } while (l && d != c);
-
- if (d != c) {
-+ optopt = c;
- if (optstring[0] != ':' && opterr)
- __getopt_msg(argv[0], ": unrecognized option: ", optchar, k);
- return '?';
-@@ -86,6 +86,7 @@ int getopt(int argc, char * const argv[], const char *optstring)
- if (optstring[i] == ':') {
- if (optstring[i+1] == ':') optarg = 0;
- else if (optind >= argc) {
-+ optopt = c;
- if (optstring[0] == ':') return ':';
- if (opterr) __getopt_msg(argv[0],
- ": option requires an argument: ",
-diff --git a/src/misc/getopt_long.c b/src/misc/getopt_long.c
-index c6e14625..568ae7ba 100644
---- a/src/misc/getopt_long.c
-+++ b/src/misc/getopt_long.c
-@@ -75,9 +75,9 @@ static int __getopt_long_core(int argc, char *const *argv, const char *optstring
- if (cnt==1) {
- i = match;
- optind++;
-- optopt = longopts[i].val;
- if (*opt == '=') {
- if (!longopts[i].has_arg) {
-+ optopt = longopts[i].val;
- if (colon || !opterr)
- return '?';
- __getopt_msg(argv[0],
-@@ -89,6 +89,7 @@ static int __getopt_long_core(int argc, char *const *argv, const char *optstring
- optarg = opt+1;
- } else if (longopts[i].has_arg == required_argument) {
- if (!(optarg = argv[optind])) {
-+ optopt = longopts[i].val;
- if (colon) return ':';
- if (!opterr) return '?';
- __getopt_msg(argv[0],
-@@ -107,6 +108,7 @@ static int __getopt_long_core(int argc, char *const *argv, const char *optstring
- return longopts[i].val;
- }
- if (argv[optind][1] == '-') {
-+ optopt = 0;
- if (!colon && opterr)
- __getopt_msg(argv[0], cnt ?
- ": option is ambiguous: " :
---
-2.11.0
-
diff --git a/main/musl/0005-treat-base-1-as-an-error-in-strtol-family-functions.patch b/main/musl/0005-treat-base-1-as-an-error-in-strtol-family-functions.patch
deleted file mode 100644
index 77c72a68e0..0000000000
--- a/main/musl/0005-treat-base-1-as-an-error-in-strtol-family-functions.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 809ff8cf90254921ea38eb6fa1ce326d9008513b Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 4 Jan 2017 19:48:21 -0500
-Subject: [PATCH] treat base 1 as an error in strtol-family functions
-
-ISO C and POSIX only specify behavior for base arguments of 0 and
-2-36; POSIX mandates an EINVAL error for unsupported bases. it's not
-clear that there's a requirement for implementations not to "support"
-additional bases as an extension, but "base 1" did not work in any
-meaningful way anyway, so it should be considered unsupported and thus
-an error.
----
- src/internal/intscan.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/internal/intscan.c b/src/internal/intscan.c
-index 65d497ec..a4a5ae86 100644
---- a/src/internal/intscan.c
-+++ b/src/internal/intscan.c
-@@ -29,7 +29,7 @@ unsigned long long __intscan(FILE *f, unsigned base, int pok, unsigned long long
- int c, neg=0;
- unsigned x;
- unsigned long long y;
-- if (base > 36) {
-+ if (base > 36 || base == 1) {
- errno = EINVAL;
- return 0;
- }
---
-2.11.0
-
diff --git a/main/musl/0006-fix-crash-from-corrupted-tls-module-list-after-faile.patch b/main/musl/0006-fix-crash-from-corrupted-tls-module-list-after-faile.patch
deleted file mode 100644
index 5fd797d405..0000000000
--- a/main/musl/0006-fix-crash-from-corrupted-tls-module-list-after-faile.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 27b3fd68f67b674440d21ea7ca5cf918d2e1559f Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 4 Jan 2017 22:54:06 -0500
-Subject: [PATCH] fix crash from corrupted tls module list after failed dlopen
-
-commit d56460c939c94a6c547abe8238f442b8de10bfbd introduced this
-regression as part of splitting the tls module list out of the dso
-list. the new code added to dlopen's failure path to undo the changes
-adding the partially-loaded libraries reset the tls_tail pointer
-correctly, but did not clear its link to the next list entry. thus, at
-least until the next successful dlopen, the list was not terminated
-but ended with an invalid next pointer, which __copy_tls attempted to
-follow when a new thread was created.
-
-patch by Mikael Vidstedt.
----
- ldso/dynlink.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index c6890845..48dcd1c2 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -1686,6 +1686,7 @@ void *dlopen(const char *file, int mode)
- }
- if (!orig_tls_tail) libc.tls_head = 0;
- tls_tail = orig_tls_tail;
-+ if (tls_tail) tls_tail->next = 0;
- tls_cnt = orig_tls_cnt;
- tls_offset = orig_tls_offset;
- tls_align = orig_tls_align;
---
-2.11.0
-
diff --git a/main/musl/0007-fix-bindtextdomain-logic-error-deactivating-other-do.patch b/main/musl/0007-fix-bindtextdomain-logic-error-deactivating-other-do.patch
deleted file mode 100644
index bacb3bc8e8..0000000000
--- a/main/musl/0007-fix-bindtextdomain-logic-error-deactivating-other-do.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 01e6bbece2bdcac243cdb8dff6916f2bb80a19e1 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sun, 29 Jan 2017 00:11:23 -0500
-Subject: [PATCH] fix bindtextdomain logic error deactivating other domains
-
-this loop was only supposed to deactivate other bindings for the same
-text domain name, but due to copy-and-paste error, deactivated all
-other bindings.
-
-patch by He X.
----
- src/locale/dcngettext.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/locale/dcngettext.c b/src/locale/dcngettext.c
-index a5ff8475..e48c50f0 100644
---- a/src/locale/dcngettext.c
-+++ b/src/locale/dcngettext.c
-@@ -74,7 +74,7 @@ char *bindtextdomain(const char *domainname, const char *dirname)
- a_store(&p->active, 1);
-
- for (q=bindings; q; q=q->next) {
-- if (!strcmp(p->domainname, domainname) && q != p)
-+ if (!strcmp(q->domainname, domainname) && q != p)
- a_store(&q->active, 0);
- }
-
---
-2.11.1
-
diff --git a/main/musl/0008-fix-use-of-uninitialized-pointer-in-gettext-core.patch b/main/musl/0008-fix-use-of-uninitialized-pointer-in-gettext-core.patch
deleted file mode 100644
index 8e0f33d6ce..0000000000
--- a/main/musl/0008-fix-use-of-uninitialized-pointer-in-gettext-core.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From dbbb3734d8c0176feabd6c46e2e85bbc3b8a60af Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sun, 29 Jan 2017 11:14:00 -0500
-Subject: [PATCH] fix use of uninitialized pointer in gettext core
-
-the plural_rule field of allocated msgcat structures was assumed to be
-initially-null but was never initialized. for future-proofing, the
-nplurals field which was left uninitialized should also be cleared.
-
-likewise, in the binding structure, the active field could be used
-uninitialized by a technicality: the a_store which stores the initial
-value of 0 may be implemented as a cas operation, which reads the old
-value.
-
-rather than fixing these issues individually, just use calloc for both
-allocations. this does result in wasteful clearing of name buffers (up
-to NAME_MAX+PATH_MAX) before filling them, but since the size if
-bounded and the time is dominated by filesystem operations, it really
-doesn't matter; simplicity and future-proofing have more value here.
-
-modified from patch submitted by He X.
----
- src/locale/dcngettext.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/locale/dcngettext.c b/src/locale/dcngettext.c
-index e48c50f0..73a9fd70 100644
---- a/src/locale/dcngettext.c
-+++ b/src/locale/dcngettext.c
-@@ -57,7 +57,7 @@ char *bindtextdomain(const char *domainname, const char *dirname)
- }
-
- if (!p) {
-- p = malloc(sizeof *p + domlen + dirlen + 2);
-+ p = calloc(sizeof *p + domlen + dirlen + 2, 1);
- if (!p) {
- UNLOCK(lock);
- return 0;
-@@ -171,7 +171,7 @@ notrans:
- size_t map_size;
- const void *map = __map_file(name, &map_size);
- if (!map) goto notrans;
-- p = malloc(sizeof *p + namelen + 1);
-+ p = calloc(sizeof *p + namelen + 1, 1);
- if (!p) {
- __munmap((void *)map, map_size);
- goto notrans;
---
-2.11.1
-
diff --git a/main/musl/0009-avoid-unbounded-strlen-in-gettext-functions.patch b/main/musl/0009-avoid-unbounded-strlen-in-gettext-functions.patch
deleted file mode 100644
index b682490010..0000000000
--- a/main/musl/0009-avoid-unbounded-strlen-in-gettext-functions.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From d6601f0af0452b218d247cb47513fc9cd6bbf2e2 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sun, 29 Jan 2017 11:24:20 -0500
-Subject: [PATCH] avoid unbounded strlen in gettext functions
-
-use the standard strnlen idiom for cases where lengths greater than an
-imposed limit are going to be rejected immediately anyway.
----
- src/locale/dcngettext.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/src/locale/dcngettext.c b/src/locale/dcngettext.c
-index 73a9fd70..b68e24bc 100644
---- a/src/locale/dcngettext.c
-+++ b/src/locale/dcngettext.c
-@@ -40,8 +40,8 @@ char *bindtextdomain(const char *domainname, const char *dirname)
- if (!domainname) return 0;
- if (!dirname) return gettextdir(domainname, &(size_t){0});
-
-- size_t domlen = strlen(domainname);
-- size_t dirlen = strlen(dirname);
-+ size_t domlen = strnlen(domainname, NAME_MAX+1);
-+ size_t dirlen = strnlen(dirname, PATH_MAX);
- if (domlen > NAME_MAX || dirlen >= PATH_MAX) {
- errno = EINVAL;
- return 0;
-@@ -127,7 +127,7 @@ char *dcngettext(const char *domainname, const char *msgid1, const char *msgid2,
-
- if (!domainname) domainname = __gettextdomain();
-
-- domlen = strlen(domainname);
-+ domlen = strnlen(domainname, NAME_MAX+1);
- if (domlen > NAME_MAX) goto notrans;
-
- dirname = gettextdir(domainname, &dirlen);
---
-2.11.1
-
diff --git a/main/musl/0010-s390x-implement-dlsym.patch b/main/musl/0010-s390x-implement-dlsym.patch
deleted file mode 100644
index 3611d3efd9..0000000000
--- a/main/musl/0010-s390x-implement-dlsym.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From 9201c3afce0ff53a9b1c5da5285ff84c11dee9d4 Mon Sep 17 00:00:00 2001
-From: Bobby Bingham <koorogi@koorogi.info>
-Date: Sun, 5 Feb 2017 21:29:52 -0600
-Subject: [PATCH] s390x: implement dlsym
-
-This was missed when writing the port initially.
----
- src/ldso/s390x/dlsym.s | 6 ++++++
- 1 file changed, 6 insertions(+)
- create mode 100644 src/ldso/s390x/dlsym.s
-
-diff --git a/src/ldso/s390x/dlsym.s b/src/ldso/s390x/dlsym.s
-new file mode 100644
-index 00000000..2e9fa8fb
---- /dev/null
-+++ b/src/ldso/s390x/dlsym.s
-@@ -0,0 +1,6 @@
-+ .global dlsym
-+ .hidden __dlsym
-+ .type dlsym,@function
-+dlsym:
-+ lgr %r4, %r14
-+ jg __dlsym
---
-2.11.1
-
diff --git a/main/musl/0011-fix-build-regression-in-arm-atomics-asm-with-new-bin.patch b/main/musl/0011-fix-build-regression-in-arm-atomics-asm-with-new-bin.patch
deleted file mode 100644
index 37373594e2..0000000000
--- a/main/musl/0011-fix-build-regression-in-arm-atomics-asm-with-new-bin.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From b261a24256792177a5f0531dbb25cc6267220ca5 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 15 Feb 2017 17:05:50 -0500
-Subject: [PATCH] fix build regression in arm atomics asm with new binutils
-
-binutils commit bada43421274615d0d5f629a61a60b7daa71bc15 tightened
-immediate fixup handling in gas in such a way that the final .arch of
-an object file must be compatible with the fixups used when the
-instruction was assembled; this in turn broke assembling of atomics.s,
-at least in thumb mode.
-
-it's not clear whether this should be considered a bug in gas, but
-.object_arch is preferable anyway for our purpose here of controlling
-the ISA level tag on the object file being produced, and it's the
-intended directive for use in object files with runtime code
-selection. research by Szabolcs Nagy confirmed that .object_arch is
-supported in all relevant versions of binutils and clang's integrated
-assembler.
-
-patch by Reiner Herrmann.
----
- src/thread/arm/atomics.s | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/thread/arm/atomics.s b/src/thread/arm/atomics.s
-index 202faa4a..101ad391 100644
---- a/src/thread/arm/atomics.s
-+++ b/src/thread/arm/atomics.s
-@@ -84,7 +84,7 @@ __a_gettp_cp15:
- bx lr
-
- /* Tag this file with minimum ISA level so as not to affect linking. */
--.arch armv4t
-+.object_arch armv4t
- .eabi_attribute 6,2
-
- .data
---
-2.11.1
-
diff --git a/main/musl/0012-allow-page-size-to-vary-on-arm.patch b/main/musl/0012-allow-page-size-to-vary-on-arm.patch
deleted file mode 100644
index bba55300cd..0000000000
--- a/main/musl/0012-allow-page-size-to-vary-on-arm.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 0a4a16d11cc263c3f32325f985b9ed94b04af79f Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 22 Feb 2017 19:25:13 -0500
-Subject: [PATCH] allow page size to vary on arm
-
-the ABI for arm was silently changed at some point to allow page sizes
-other than 4k; traditional binaries built with only 4k-aligned offsets
-between load segments cannot run on such systems, but newer binutils
-versions use 64k offset alignment.
-
-while larger page size is undesirable for various reasons, users have
-encountered hardware and/or kernels that lock the page size to a
-larger value, so follow the new ABI and allow it to vary.
----
- arch/arm/bits/limits.h | 1 -
- 1 file changed, 1 deletion(-)
-
-diff --git a/arch/arm/bits/limits.h b/arch/arm/bits/limits.h
-index 65a3dd64..fbc6d238 100644
---- a/arch/arm/bits/limits.h
-+++ b/arch/arm/bits/limits.h
-@@ -1,6 +1,5 @@
- #if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \
- || defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
--#define PAGE_SIZE 4096
- #define LONG_BIT 32
- #endif
-
---
-2.11.1
-
diff --git a/main/musl/0013-fix-lsearch-and-lfind-to-pass-key-as-first-arg-to-th.patch b/main/musl/0013-fix-lsearch-and-lfind-to-pass-key-as-first-arg-to-th.patch
deleted file mode 100644
index 75e3d96ba9..0000000000
--- a/main/musl/0013-fix-lsearch-and-lfind-to-pass-key-as-first-arg-to-th.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 827c4e6fbe46142049ef3d8bcb8f35951712797d Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Sun, 5 Mar 2017 23:03:35 +0100
-Subject: [PATCH] fix lsearch and lfind to pass key as first arg to the compar
- callback
-
-this is not a conformance issue as posix does not specify the
-argument order, but the order is specified for bsearch and some
-systems document the order for lsearch consistently (openbsd).
-
-since there were two indpendent reports of this issue it's better
-to use the more widely expected argument order.
----
- src/search/lsearch.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/search/lsearch.c b/src/search/lsearch.c
-index 63f31922..5eb5cc2b 100644
---- a/src/search/lsearch.c
-+++ b/src/search/lsearch.c
-@@ -9,7 +9,7 @@ void *lsearch(const void *key, void *base, size_t *nelp, size_t width,
- size_t i;
-
- for (i = 0; i < n; i++)
-- if (compar(p[i], key) == 0)
-+ if (compar(key, p[i]) == 0)
- return p[i];
- *nelp = n+1;
- return memcpy(p[n], key, width);
-@@ -23,7 +23,7 @@ void *lfind(const void *key, const void *base, size_t *nelp,
- size_t i;
-
- for (i = 0; i < n; i++)
-- if (compar(p[i], key) == 0)
-+ if (compar(key, p[i]) == 0)
- return p[i];
- return 0;
- }
---
-2.11.1
-
diff --git a/main/musl/0014-fix-ld-behavior-dependent-crash-in-ppc64-ldso-startu.patch b/main/musl/0014-fix-ld-behavior-dependent-crash-in-ppc64-ldso-startu.patch
deleted file mode 100644
index cf026c0f9a..0000000000
--- a/main/musl/0014-fix-ld-behavior-dependent-crash-in-ppc64-ldso-startu.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From fc85fb38605a8bf341c367b8ab0d36edab2bdbfc Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 8 Mar 2017 13:35:33 -0500
-Subject: [PATCH] fix ld-behavior-dependent crash in ppc64 ldso startup
-
-the 32-bit pc-relative address for stage 2 of dynamic linker entry was
-wrongly loaded with a zero-extending load instead of sign-extending
-load, resulting in an invalid jump if the offset happened to be
-negative, which depends on the linker's ordering of text sections.
----
- arch/powerpc64/reloc.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/arch/powerpc64/reloc.h b/arch/powerpc64/reloc.h
-index e1bad009..faf70acd 100644
---- a/arch/powerpc64/reloc.h
-+++ b/arch/powerpc64/reloc.h
-@@ -27,6 +27,6 @@
- " bl 1f \n" \
- " .long " #sym "-. \n" \
- "1: mflr %1 \n" \
-- " lwz %0, 0(%1) \n" \
-+ " lwa %0, 0(%1) \n" \
- " add %0, %0, %1 \n" \
- : "=r"(*(fp)), "=r"((long){0}) : : "memory", "lr" )
---
-2.11.1
-
diff --git a/main/musl/0015-treat-STB_WEAK-and-STB_GNU_UNIQUE-like-STB_GLOBAL-in.patch b/main/musl/0015-treat-STB_WEAK-and-STB_GNU_UNIQUE-like-STB_GLOBAL-in.patch
deleted file mode 100644
index af8d843923..0000000000
--- a/main/musl/0015-treat-STB_WEAK-and-STB_GNU_UNIQUE-like-STB_GLOBAL-in.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From c9783e4d32e786c4b76bf77c6030111d9e79dbb7 Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Sat, 3 Dec 2016 20:52:43 +0000
-Subject: [PATCH] treat STB_WEAK and STB_GNU_UNIQUE like STB_GLOBAL in find_sym
-
-A weak symbol definition is not special during dynamic linking, so
-don't let a strong definition in a later module override it.
-(glibc dynamic linker allows overriding weak definitions if
-LD_DYNAMIC_WEAK is set, musl does not.)
-
-STB_GNU_UNIQUE means that the symbol is global, even if it is in a
-module that's loaded with RTLD_LOCAL, and all references resolve to
-the same definition. This semantics is only relevant for c++ plugin
-systems and even there it's often not what the user wants (so it can
-be turned off in g++ by -fno-gnu-unique when the c++ shared lib is
-compiled). In musl just treat it like STB_GLOBAL.
----
- ldso/dynlink.c | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index a03f75e3..d00827a3 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -286,11 +286,9 @@ static struct symdef find_sym(struct dso *dso, const char *s, int need_def)
- continue;
- if (!(1<<(sym->st_info&0xf) & OK_TYPES)) continue;
- if (!(1<<(sym->st_info>>4) & OK_BINDS)) continue;
--
-- if (def.sym && sym->st_info>>4 == STB_WEAK) continue;
- def.sym = sym;
- def.dso = dso;
-- if (sym->st_info>>4 == STB_GLOBAL) break;
-+ break;
- }
- return def;
- }
---
-2.11.1
-
diff --git a/main/musl/0016-rework-ldso-handling-of-global-symbol-table-for-cons.patch b/main/musl/0016-rework-ldso-handling-of-global-symbol-table-for-cons.patch
deleted file mode 100644
index 03e1da813b..0000000000
--- a/main/musl/0016-rework-ldso-handling-of-global-symbol-table-for-cons.patch
+++ /dev/null
@@ -1,255 +0,0 @@
-From 4ff234f6cba96403b5de6d29d48a59fd73252040 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sun, 12 Mar 2017 21:03:05 -0400
-Subject: [PATCH] rework ldso handling of global symbol table for consistency
-
-when loading libraries with dlopen, the caller can request that the
-library's symbols become part of the global symbol table, or that they
-only be used for resolving relocations in the loaded library and its
-dependencies. in the latter case, a subsequent dlopen of the same
-library can upgrade it to global status.
-
-previously, if a library was upgraded from local to global mode, its
-symbols entered the symbol lookup search order at the point where the
-library was originally loaded. this means that a new call to dlopen
-could change the value of a symbol that already had a visible
-definition, an inconsistency which applications could observe.
-
-POSIX is unclear whether this should happen or whether it's permitted
-to happen, but the resolution of Austin Group issue #982 made it
-formally unspecified.
-
-with this patch, a library whose mode is upgraded from local to global
-enters the symbol lookup order at the point where it was made global,
-so that symbol resolution before and after the upgrade are consistent.
-
-in order to implement this change, the per-dso global flag is replaced
-with a separate set of linked-list pointers for participation in the
-global symbol table. this permits the order of dso objects for symbol
-resolution to differ from the order used for iteration of all loaded
-libraries. it also improves performance of find_sym, by avoiding a
-branch per iteration and skipping, and especially in the case where
-many non-global libraries have been loaded, by allowing the loop to
-skip over them entirely. logic for temporarily adding non-global
-libraries to the symbol table for relocation purposes is also mildly
-simplified.
----
- ldso/dynlink.c | 97 ++++++++++++++++++++++++++++++++--------------------------
- 1 file changed, 53 insertions(+), 44 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index d00827a3..0e394e0d 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -58,11 +58,11 @@ struct dso {
- uint32_t *ghashtab;
- int16_t *versym;
- char *strings;
-+ struct dso *syms_next;
- unsigned char *map;
- size_t map_len;
- dev_t dev;
- ino_t ino;
-- signed char global;
- char relocated;
- char constructed;
- char kernel_mapped;
-@@ -113,7 +113,7 @@ static struct builtin_tls {
- static size_t *saved_addends, *apply_addends_to;
-
- static struct dso ldso;
--static struct dso *head, *tail, *fini_head;
-+static struct dso *head, *tail, *fini_head, *syms_tail;
- static char *env_path, *sys_path;
- static unsigned long long gencnt;
- static int runtime;
-@@ -261,9 +261,8 @@ static struct symdef find_sym(struct dso *dso, const char *s, int need_def)
- uint32_t h = 0, gh, gho, *ght;
- size_t ghm = 0;
- struct symdef def = {0};
-- for (; dso; dso=dso->next) {
-+ for (; dso; dso=dso->syms_next) {
- Sym *sym;
-- if (!dso->global) continue;
- if ((ght = dso->ghashtab)) {
- if (!ghm) {
- gh = gnu_hash(s);
-@@ -329,7 +328,7 @@ static void do_relocs(struct dso *dso, size_t *rel, size_t rel_size, size_t stri
- if (sym_index) {
- sym = syms + sym_index;
- name = strings + sym->st_name;
-- ctx = type==REL_COPY ? head->next : head;
-+ ctx = type==REL_COPY ? head->syms_next : head;
- def = (sym->st_info&0xf) == STT_SECTION
- ? (struct symdef){ .dso = dso, .sym = sym }
- : find_sym(ctx, name, type==REL_PLT);
-@@ -932,7 +931,7 @@ static struct dso *load_library(const char *name, struct dso *needed_by)
- if (!ldso.prev) {
- tail->next = &ldso;
- ldso.prev = tail;
-- tail = ldso.next ? ldso.next : &ldso;
-+ tail = &ldso;
- }
- return &ldso;
- }
-@@ -1113,9 +1112,24 @@ static void load_preload(char *s)
- }
- }
-
--static void make_global(struct dso *p)
-+static void add_syms(struct dso *p)
- {
-- for (; p; p=p->next) p->global = 1;
-+ if (!p->syms_next && syms_tail != p) {
-+ syms_tail->syms_next = p;
-+ syms_tail = p;
-+ }
-+}
-+
-+static void revert_syms(struct dso *old_tail)
-+{
-+ struct dso *p, *next;
-+ /* Chop off the tail of the list of dsos that participate in
-+ * the global symbol table, reverting them to RTLD_LOCAL. */
-+ for (p=old_tail; p; p=next) {
-+ next = p->syms_next;
-+ p->syms_next = 0;
-+ }
-+ syms_tail = old_tail;
- }
-
- static void do_mips_relocs(struct dso *p, size_t *got)
-@@ -1344,7 +1358,6 @@ void __dls2(unsigned char *base, size_t *sp)
- }
- Ehdr *ehdr = (void *)ldso.base;
- ldso.name = ldso.shortname = "libc.so";
-- ldso.global = 1;
- ldso.phnum = ehdr->e_phnum;
- ldso.phdr = laddr(&ldso, ehdr->e_phoff);
- ldso.phentsize = ehdr->e_phentsize;
-@@ -1532,7 +1545,6 @@ _Noreturn void __dls3(size_t *sp)
- #endif
- tls_align = MAXP2(tls_align, app.tls.align);
- }
-- app.global = 1;
- decode_dyn(&app);
- if (DL_FDPIC) {
- makefuncdescs(&app);
-@@ -1547,7 +1559,21 @@ _Noreturn void __dls3(size_t *sp)
- argv[-3] = (void *)app.loadmap;
- }
-
-- /* Attach to vdso, if provided by the kernel */
-+ /* Initial dso chain consists only of the app. */
-+ head = tail = syms_tail = &app;
-+
-+ /* Donate unused parts of app and library mapping to malloc */
-+ reclaim_gaps(&app);
-+ reclaim_gaps(&ldso);
-+
-+ /* Load preload/needed libraries, add symbols to global namespace. */
-+ if (env_preload) load_preload(env_preload);
-+ load_deps(&app);
-+ for (struct dso *p=head; p; p=p->next)
-+ add_syms(p);
-+
-+ /* Attach to vdso, if provided by the kernel, last so that it does
-+ * not become part of the global namespace. */
- if (search_vec(auxv, &vdso_base, AT_SYSINFO_EHDR) && vdso_base) {
- Ehdr *ehdr = (void *)vdso_base;
- Phdr *phdr = vdso.phdr = (void *)(vdso_base + ehdr->e_phoff);
-@@ -1561,26 +1587,13 @@ _Noreturn void __dls3(size_t *sp)
- }
- vdso.name = "";
- vdso.shortname = "linux-gate.so.1";
-- vdso.global = 1;
- vdso.relocated = 1;
- decode_dyn(&vdso);
-- vdso.prev = &ldso;
-- ldso.next = &vdso;
-+ vdso.prev = tail;
-+ tail->next = &vdso;
-+ tail = &vdso;
- }
-
-- /* Initial dso chain consists only of the app. */
-- head = tail = &app;
--
-- /* Donate unused parts of app and library mapping to malloc */
-- reclaim_gaps(&app);
-- reclaim_gaps(&ldso);
--
-- /* Load preload/needed libraries, add their symbols to the global
-- * namespace, and perform all remaining relocations. */
-- if (env_preload) load_preload(env_preload);
-- load_deps(&app);
-- make_global(&app);
--
- for (i=0; app.dynv[i]; i+=2) {
- if (!DT_DEBUG_INDIRECT && app.dynv[i]==DT_DEBUG)
- app.dynv[i+1] = (size_t)&debug;
-@@ -1641,7 +1654,7 @@ _Noreturn void __dls3(size_t *sp)
-
- void *dlopen(const char *file, int mode)
- {
-- struct dso *volatile p, *orig_tail, *next;
-+ struct dso *volatile p, *orig_tail, *orig_syms_tail, *next;
- struct tls_module *orig_tls_tail;
- size_t orig_tls_cnt, orig_tls_offset, orig_tls_align;
- size_t i;
-@@ -1659,15 +1672,14 @@ void *dlopen(const char *file, int mode)
- orig_tls_cnt = tls_cnt;
- orig_tls_offset = tls_offset;
- orig_tls_align = tls_align;
-+ orig_syms_tail = syms_tail;
- orig_tail = tail;
- noload = mode & RTLD_NOLOAD;
-
- rtld_fail = &jb;
- if (setjmp(*rtld_fail)) {
- /* Clean up anything new that was (partially) loaded */
-- if (p && p->deps) for (i=0; p->deps[i]; i++)
-- if (p->deps[i]->global < 0)
-- p->deps[i]->global = 0;
-+ revert_syms(orig_syms_tail);
- for (p=orig_tail->next; p; p=next) {
- next = p->next;
- while (p->td_index) {
-@@ -1703,24 +1715,21 @@ void *dlopen(const char *file, int mode)
- }
-
- /* First load handling */
-- if (!p->deps) {
-+ if (!p->relocated) {
- load_deps(p);
-+ /* Make new symbols global, at least temporarily, so we can do
-+ * relocations. If not RTLD_GLOBAL, this is reverted below. */
-+ add_syms(p);
- if (p->deps) for (i=0; p->deps[i]; i++)
-- if (!p->deps[i]->global)
-- p->deps[i]->global = -1;
-- if (!p->global) p->global = -1;
-+ add_syms(p->deps[i]);
- reloc_all(p);
-- if (p->deps) for (i=0; p->deps[i]; i++)
-- if (p->deps[i]->global < 0)
-- p->deps[i]->global = 0;
-- if (p->global < 0) p->global = 0;
- }
-
-- if (mode & RTLD_GLOBAL) {
-- if (p->deps) for (i=0; p->deps[i]; i++)
-- p->deps[i]->global = 1;
-- p->global = 1;
-- }
-+ /* If RTLD_GLOBAL was not specified, undo any new additions
-+ * to the global symbol table. This is a nop if the library was
-+ * previously loaded and already global. */
-+ if (!(mode & RTLD_GLOBAL))
-+ revert_syms(orig_syms_tail);
-
- update_tls_size();
- _dl_debug_state();
---
-2.12.1
-
diff --git a/main/musl/0017-reorder-addend-handling-before-symbol-lookup-in-relo.patch b/main/musl/0017-reorder-addend-handling-before-symbol-lookup-in-relo.patch
deleted file mode 100644
index 970c2e99ad..0000000000
--- a/main/musl/0017-reorder-addend-handling-before-symbol-lookup-in-relo.patch
+++ /dev/null
@@ -1,68 +0,0 @@
-From 4823b13a75b40c4408c1101b363ab00fd118fb27 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Mon, 13 Mar 2017 00:30:26 -0400
-Subject: [PATCH] reorder addend handling before symbol lookup in relocation
- code
-
-these two tasks are independent now, but in order to support lazy
-relocations, the failure path for symbol lookup may want the addend to
-be available.
----
- ldso/dynlink.c | 33 +++++++++++++++++----------------
- 1 file changed, 17 insertions(+), 16 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index 0e394e0d..0bd9d50c 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -323,8 +323,24 @@ static void do_relocs(struct dso *dso, size_t *rel, size_t rel_size, size_t stri
- if (skip_relative && IS_RELATIVE(rel[1], dso->syms)) continue;
- type = R_TYPE(rel[1]);
- if (type == REL_NONE) continue;
-- sym_index = R_SYM(rel[1]);
- reloc_addr = laddr(dso, rel[0]);
-+
-+ if (stride > 2) {
-+ addend = rel[2];
-+ } else if (type==REL_GOT || type==REL_PLT|| type==REL_COPY) {
-+ addend = 0;
-+ } else if (reuse_addends) {
-+ /* Save original addend in stage 2 where the dso
-+ * chain consists of just ldso; otherwise read back
-+ * saved addend since the inline one was clobbered. */
-+ if (head==&ldso)
-+ saved_addends[save_slot] = *reloc_addr;
-+ addend = saved_addends[save_slot++];
-+ } else {
-+ addend = *reloc_addr;
-+ }
-+
-+ sym_index = R_SYM(rel[1]);
- if (sym_index) {
- sym = syms + sym_index;
- name = strings + sym->st_name;
-@@ -345,21 +361,6 @@ static void do_relocs(struct dso *dso, size_t *rel, size_t rel_size, size_t stri
- def.dso = dso;
- }
-
-- if (stride > 2) {
-- addend = rel[2];
-- } else if (type==REL_GOT || type==REL_PLT|| type==REL_COPY) {
-- addend = 0;
-- } else if (reuse_addends) {
-- /* Save original addend in stage 2 where the dso
-- * chain consists of just ldso; otherwise read back
-- * saved addend since the inline one was clobbered. */
-- if (head==&ldso)
-- saved_addends[save_slot] = *reloc_addr;
-- addend = saved_addends[save_slot++];
-- } else {
-- addend = *reloc_addr;
-- }
--
- sym_val = def.sym ? (size_t)laddr(def.dso, def.sym->st_value) : 0;
- tls_val = def.sym ? def.sym->st_value : 0;
-
---
-2.12.1
-
diff --git a/main/musl/0018-emulate-lazy-relocation-as-deferrable-relocation.patch b/main/musl/0018-emulate-lazy-relocation-as-deferrable-relocation.patch
deleted file mode 100644
index 19e3764e68..0000000000
--- a/main/musl/0018-emulate-lazy-relocation-as-deferrable-relocation.patch
+++ /dev/null
@@ -1,172 +0,0 @@
-From 6476b8135760659b25c93ff9308425ca98a9e777 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Mon, 13 Mar 2017 08:52:41 -0400
-Subject: [PATCH] emulate lazy relocation as deferrable relocation
-
-traditional lazy relocation with call-time plt resolver is
-intentionally not implemented, as it is a huge bug surface and demands
-significant amounts of arch-specific code and requires ongoing
-maintenance to ensure compatibility with applications which make use
-of new additions to the arch's register file in passing function
-arguments.
-
-some applications, however, depend on the ability to dlopen modules
-which have unsatisfied symbol references at the time they are loaded,
-either avoiding use of the affected interfaces or manually loading
-another module to provide the missing definition via their own module
-dependency tracking outside the ELF data structures. while such usage
-is non-conforming, failure to support it has been a significant
-obstacle for users/distributions trying to support affected software,
-particularly the X.org server.
-
-instead of resolving lazy relocations at call time, this patch saves
-unresolved GOT/PLT relocations for deferral and retries them after
-each subsequent dlopen until they are resolved. since dlopen is the
-only time at which the effective global symbol table can change, this
-behavior is not observably different from traditional lazy binding,
-and the required code is minimal.
----
- ldso/dynlink.c | 69 +++++++++++++++++++++++++++++++++++++++++++++++++++++++---
- 1 file changed, 66 insertions(+), 3 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index 0bd9d50c..f8db1f82 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -58,7 +58,8 @@ struct dso {
- uint32_t *ghashtab;
- int16_t *versym;
- char *strings;
-- struct dso *syms_next;
-+ struct dso *syms_next, *lazy_next;
-+ size_t *lazy, lazy_cnt;
- unsigned char *map;
- size_t map_len;
- dev_t dev;
-@@ -113,7 +114,7 @@ static struct builtin_tls {
- static size_t *saved_addends, *apply_addends_to;
-
- static struct dso ldso;
--static struct dso *head, *tail, *fini_head, *syms_tail;
-+static struct dso *head, *tail, *fini_head, *syms_tail, *lazy_head;
- static char *env_path, *sys_path;
- static unsigned long long gencnt;
- static int runtime;
-@@ -350,6 +351,13 @@ static void do_relocs(struct dso *dso, size_t *rel, size_t rel_size, size_t stri
- : find_sym(ctx, name, type==REL_PLT);
- if (!def.sym && (sym->st_shndx != SHN_UNDEF
- || sym->st_info>>4 != STB_WEAK)) {
-+ if (dso->lazy && (type==REL_PLT || type==REL_GOT)) {
-+ dso->lazy[3*dso->lazy_cnt+0] = rel[0];
-+ dso->lazy[3*dso->lazy_cnt+1] = rel[1];
-+ dso->lazy[3*dso->lazy_cnt+2] = addend;
-+ dso->lazy_cnt++;
-+ continue;
-+ }
- error("Error relocating %s: %s: symbol not found",
- dso->name, name);
- if (runtime) longjmp(*rtld_fail, 1);
-@@ -451,6 +459,26 @@ static void do_relocs(struct dso *dso, size_t *rel, size_t rel_size, size_t stri
- }
- }
-
-+static void redo_lazy_relocs()
-+{
-+ struct dso *p = lazy_head, *next;
-+ lazy_head = 0;
-+ for (; p; p=next) {
-+ next = p->lazy_next;
-+ size_t size = p->lazy_cnt*3*sizeof(size_t);
-+ p->lazy_cnt = 0;
-+ do_relocs(p, p->lazy, size, 3);
-+ if (p->lazy_cnt) {
-+ p->lazy_next = lazy_head;
-+ lazy_head = p;
-+ } else {
-+ free(p->lazy);
-+ p->lazy = 0;
-+ p->lazy_next = 0;
-+ }
-+ }
-+}
-+
- /* A huge hack: to make up for the wastefulness of shared libraries
- * needing at least a page of dirty memory even if they have no global
- * data, we reclaim the gaps at the beginning and end of writable maps
-@@ -1653,9 +1681,31 @@ _Noreturn void __dls3(size_t *sp)
- for(;;);
- }
-
-+static void prepare_lazy(struct dso *p)
-+{
-+ size_t dyn[DYN_CNT], n, flags1=0;
-+ decode_vec(p->dynv, dyn, DYN_CNT);
-+ search_vec(p->dynv, &flags1, DT_FLAGS_1);
-+ if (dyn[DT_BIND_NOW] || (dyn[DT_FLAGS] & DF_BIND_NOW) || (flags1 & DF_1_NOW))
-+ return;
-+ n = dyn[DT_RELSZ]/2 + dyn[DT_RELASZ]/3 + dyn[DT_PLTRELSZ]/2 + 1;
-+ if (NEED_MIPS_GOT_RELOCS) {
-+ size_t j=0; search_vec(p->dynv, &j, DT_MIPS_GOTSYM);
-+ size_t i=0; search_vec(p->dynv, &i, DT_MIPS_SYMTABNO);
-+ n += i-j;
-+ }
-+ p->lazy = calloc(n, 3*sizeof(size_t));
-+ if (!p->lazy) {
-+ error("Error preparing lazy relocation for %s: %m", p->name);
-+ longjmp(*rtld_fail, 1);
-+ }
-+ p->lazy_next = lazy_head;
-+ lazy_head = p;
-+}
-+
- void *dlopen(const char *file, int mode)
- {
-- struct dso *volatile p, *orig_tail, *orig_syms_tail, *next;
-+ struct dso *volatile p, *orig_tail, *orig_syms_tail, *orig_lazy_head, *next;
- struct tls_module *orig_tls_tail;
- size_t orig_tls_cnt, orig_tls_offset, orig_tls_align;
- size_t i;
-@@ -1673,6 +1723,7 @@ void *dlopen(const char *file, int mode)
- orig_tls_cnt = tls_cnt;
- orig_tls_offset = tls_offset;
- orig_tls_align = tls_align;
-+ orig_lazy_head = lazy_head;
- orig_syms_tail = syms_tail;
- orig_tail = tail;
- noload = mode & RTLD_NOLOAD;
-@@ -1701,6 +1752,7 @@ void *dlopen(const char *file, int mode)
- tls_cnt = orig_tls_cnt;
- tls_offset = orig_tls_offset;
- tls_align = orig_tls_align;
-+ lazy_head = orig_lazy_head;
- tail = orig_tail;
- tail->next = 0;
- p = 0;
-@@ -1718,6 +1770,12 @@ void *dlopen(const char *file, int mode)
- /* First load handling */
- if (!p->relocated) {
- load_deps(p);
-+ if ((mode & RTLD_LAZY)) {
-+ prepare_lazy(p);
-+ if (p->deps) for (i=0; p->deps[i]; i++)
-+ if (!p->deps[i]->relocated)
-+ prepare_lazy(p->deps[i]);
-+ }
- /* Make new symbols global, at least temporarily, so we can do
- * relocations. If not RTLD_GLOBAL, this is reverted below. */
- add_syms(p);
-@@ -1732,6 +1790,11 @@ void *dlopen(const char *file, int mode)
- if (!(mode & RTLD_GLOBAL))
- revert_syms(orig_syms_tail);
-
-+ /* Processing of deferred lazy relocations must not happen until
-+ * the new libraries are committed; otherwise we could end up with
-+ * relocations resolved to symbol definitions that get removed. */
-+ redo_lazy_relocs();
-+
- update_tls_size();
- _dl_debug_state();
- orig_tail = tail;
---
-2.12.1
-
diff --git a/main/musl/0019-fix-free-of-uninitialized-buffer-pointer-on-error-in.patch b/main/musl/0019-fix-free-of-uninitialized-buffer-pointer-on-error-in.patch
deleted file mode 100644
index f168e0c7fe..0000000000
--- a/main/musl/0019-fix-free-of-uninitialized-buffer-pointer-on-error-in.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From 6582baa752a8facb2c8a7b5b3dcf67331429cdc1 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 14 Mar 2017 14:18:07 -0400
-Subject: [PATCH] fix free of uninitialized buffer pointer on error in regexec
-
-the fix in commit c3edc06d1e1360f3570db9155d6b318ae0d0f0f7 for
-CVE-2016-8859 used gotos to exit on overflow conditions, but the code
-in that error path assumed the buffer pointer was valid or null. thus,
-the conditions which previously led to under-allocation and buffer
-overflow could instead lead to an invalid pointer being passed to
-free.
----
- src/regex/regexec.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/src/regex/regexec.c b/src/regex/regexec.c
-index 5c4cb922..253b0e14 100644
---- a/src/regex/regexec.c
-+++ b/src/regex/regexec.c
-@@ -215,15 +215,15 @@ tre_tnfa_run_parallel(const tre_tnfa_t *tnfa, const void *string,
- /* Ensure that tbytes and xbytes*num_states cannot overflow, and that
- * they don't contribute more than 1/8 of SIZE_MAX to total_bytes. */
- if (num_tags > SIZE_MAX/(8 * sizeof(regoff_t) * tnfa->num_states))
-- goto error_exit;
-+ return REG_ESPACE;
-
- /* Likewise check rbytes. */
- if (tnfa->num_states+1 > SIZE_MAX/(8 * sizeof(*reach_next)))
-- goto error_exit;
-+ return REG_ESPACE;
-
- /* Likewise check pbytes. */
- if (tnfa->num_states > SIZE_MAX/(8 * sizeof(*reach_pos)))
-- goto error_exit;
-+ return REG_ESPACE;
-
- /* Compute the length of the block we need. */
- tbytes = sizeof(*tmp_tags) * num_tags;
---
-2.11.1
-
diff --git a/main/musl/0020-in-static-dl_iterate_phdr-fix-use-of-possibly-uninit.patch b/main/musl/0020-in-static-dl_iterate_phdr-fix-use-of-possibly-uninit.patch
deleted file mode 100644
index 0dd2d6f8b6..0000000000
--- a/main/musl/0020-in-static-dl_iterate_phdr-fix-use-of-possibly-uninit.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 500f5bee6c03981961f1586fca2a1dee6fdce7c7 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 14 Mar 2017 14:29:50 -0400
-Subject: [PATCH] in static dl_iterate_phdr, fix use of possibly-uninitialized
- aux data
-
-this could only happen if an incomplete auxv was passed into the
-program, but it's better to just initialize the data anyway.
----
- src/ldso/dl_iterate_phdr.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/ldso/dl_iterate_phdr.c b/src/ldso/dl_iterate_phdr.c
-index c141fd9b..e55cbf76 100644
---- a/src/ldso/dl_iterate_phdr.c
-+++ b/src/ldso/dl_iterate_phdr.c
-@@ -11,7 +11,7 @@ static int static_dl_iterate_phdr(int(*callback)(struct dl_phdr_info *info, size
- size_t base = 0;
- size_t n;
- struct dl_phdr_info info;
-- size_t i, aux[AUX_CNT];
-+ size_t i, aux[AUX_CNT] = {0};
-
- for (i=0; libc.auxv[i]; i+=2)
- if (libc.auxv[i]<AUX_CNT) aux[libc.auxv[i]] = libc.auxv[i+1];
---
-2.11.1
-
diff --git a/main/musl/0021-fix-possible-fd-leak-unrestored-cancellation-state-o.patch b/main/musl/0021-fix-possible-fd-leak-unrestored-cancellation-state-o.patch
deleted file mode 100644
index 138bd77f83..0000000000
--- a/main/musl/0021-fix-possible-fd-leak-unrestored-cancellation-state-o.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 6a209f14ff7273d9429e5153c5b6b1990cb508e3 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 14 Mar 2017 14:31:34 -0400
-Subject: [PATCH] fix possible fd leak, unrestored cancellation state on dns
- socket fail
-
----
- src/network/res_msend.c | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/src/network/res_msend.c b/src/network/res_msend.c
-index de7f6157..3e018009 100644
---- a/src/network/res_msend.c
-+++ b/src/network/res_msend.c
-@@ -76,7 +76,11 @@ int __res_msend_rc(int nqueries, const unsigned char *const *queries,
- fd = socket(AF_INET, SOCK_DGRAM|SOCK_CLOEXEC|SOCK_NONBLOCK, 0);
- family = AF_INET;
- }
-- if (fd < 0 || bind(fd, (void *)&sa, sl) < 0) return -1;
-+ if (fd < 0 || bind(fd, (void *)&sa, sl) < 0) {
-+ if (fd >= 0) close(fd);
-+ pthread_setcancelstate(cs, 0);
-+ return -1;
-+ }
-
- /* Past this point, there are no errors. Each individual query will
- * yield either no reply (indicated by zero length) or an answer
---
-2.11.1
-
diff --git a/main/musl/0022-fix-wide-scanf-s-use-of-a-compound-literal-past-its-.patch b/main/musl/0022-fix-wide-scanf-s-use-of-a-compound-literal-past-its-.patch
deleted file mode 100644
index 4e0c165fb6..0000000000
--- a/main/musl/0022-fix-wide-scanf-s-use-of-a-compound-literal-past-its-.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 733d1ea759119bcd0554f25034d1b4113b910900 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 14 Mar 2017 15:06:58 -0400
-Subject: [PATCH] fix wide scanf's use of a compound literal past its lifetime
-
----
- src/stdio/vfwscanf.c | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/src/stdio/vfwscanf.c b/src/stdio/vfwscanf.c
-index 223aad4f..1ebc5cef 100644
---- a/src/stdio/vfwscanf.c
-+++ b/src/stdio/vfwscanf.c
-@@ -214,11 +214,12 @@ int vfwscanf(FILE *restrict f, const wchar_t *restrict fmt, va_list ap)
- set = L"";
- } else if (t == 's') {
- invert = 1;
-- set = (const wchar_t[]){
-+ static const wchar_t spaces[] = {
- ' ', '\t', '\n', '\r', 11, 12, 0x0085,
- 0x2000, 0x2001, 0x2002, 0x2003, 0x2004, 0x2005,
- 0x2006, 0x2008, 0x2009, 0x200a,
- 0x2028, 0x2029, 0x205f, 0x3000, 0 };
-+ set = spaces;
- } else {
- if (*++p == '^') p++, invert = 1;
- else invert = 0;
---
-2.11.1
-
diff --git a/main/musl/0023-fix-one-byte-overflow-in-legacy-getpass-function.patch b/main/musl/0023-fix-one-byte-overflow-in-legacy-getpass-function.patch
deleted file mode 100644
index ef0efac006..0000000000
--- a/main/musl/0023-fix-one-byte-overflow-in-legacy-getpass-function.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 3ec8b3aeb88cef8574a7b0f677ebc1801f03821d Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 14 Mar 2017 15:13:16 -0400
-Subject: [PATCH] fix one-byte overflow in legacy getpass function
-
-if the length of the input was equal to the buffer size (128), a fixed
-value of zero was written one byte past the end of the static buffer.
----
- src/legacy/getpass.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/legacy/getpass.c b/src/legacy/getpass.c
-index 15ab9851..d51286c0 100644
---- a/src/legacy/getpass.c
-+++ b/src/legacy/getpass.c
-@@ -27,7 +27,7 @@ char *getpass(const char *prompt)
-
- l = read(fd, password, sizeof password);
- if (l >= 0) {
-- if (l > 0 && password[l-1] == '\n') l--;
-+ if (l > 0 && password[l-1] == '\n' || l==sizeof password) l--;
- password[l] = 0;
- }
-
---
-2.11.1
-
diff --git a/main/musl/0024-avoid-loading-of-multiple-libc-versions-via-explicit.patch b/main/musl/0024-avoid-loading-of-multiple-libc-versions-via-explicit.patch
deleted file mode 100644
index d2e352183f..0000000000
--- a/main/musl/0024-avoid-loading-of-multiple-libc-versions-via-explicit.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-From c49d3c8adadfa24235fcf4779bb722b1aa6f480b Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 14 Mar 2017 18:51:27 -0400
-Subject: [PATCH] avoid loading of multiple libc versions via explicit pathname
-
-such loading is unsafe, and can happen when programs use their own
-logic to locate a .so file then pass the absolute pathname to dlopen,
-or if an absolute pathname ends up in DT_NEEDED headers. multiple
-loads with only the base name were already precluded, provided libc
-was named appropriately, by special-casing standard library names.
-
-one function symbol (in the reserved namespace, but public, since it's
-part of the crt1 entry point ABI) and one data symbol are checked.
-this way we avoid likely false positives, particularly from libraries
-interposing and wrapping functions. there is no hard requirement to
-avoid breaking such usage, since trying to run a hook before libc is
-even initialized is not a supported usage case, but it's friendlier
-not to break things.
----
- ldso/dynlink.c | 12 +++++++++++-
- 1 file changed, 11 insertions(+), 1 deletion(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index f8db1f82..80d85e94 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -1042,6 +1042,17 @@ static struct dso *load_library(const char *name, struct dso *needed_by)
- close(fd);
- if (!map) return 0;
-
-+ /* Avoid the danger of getting two versions of libc mapped into the
-+ * same process when an absolute pathname was used. The symbols
-+ * checked are chosen to catch both musl and glibc, and to avoid
-+ * false positives from interposition-hack libraries. */
-+ decode_dyn(&temp_dso);
-+ if (find_sym(&temp_dso, "__libc_start_main", 1).sym &&
-+ find_sym(&temp_dso, "stdin", 1).sym) {
-+ unmap_library(&temp_dso);
-+ return load_library("libc.so", needed_by);
-+ }
-+
- /* Allocate storage for the new DSO. When there is TLS, this
- * storage must include a reservation for all pre-existing
- * threads to obtain copies of both the new TLS, and an
-@@ -1061,7 +1072,6 @@ static struct dso *load_library(const char *name, struct dso *needed_by)
- return 0;
- }
- memcpy(p, &temp_dso, sizeof temp_dso);
-- decode_dyn(p);
- p->dev = st.st_dev;
- p->ino = st.st_ino;
- p->refcnt = 1;
---
-2.11.1
-
diff --git a/main/musl/0025-remove-unused-refcnt-field-for-shared-libraries.patch b/main/musl/0025-remove-unused-refcnt-field-for-shared-libraries.patch
deleted file mode 100644
index 15b76119fe..0000000000
--- a/main/musl/0025-remove-unused-refcnt-field-for-shared-libraries.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From cb525397bb053ea49cf160965477a17b17286eb3 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 14 Mar 2017 19:00:02 -0400
-Subject: [PATCH] remove unused refcnt field for shared libraries
-
----
- ldso/dynlink.c | 4 ----
- 1 file changed, 4 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index 80d85e94..178fe27e 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -52,7 +52,6 @@ struct dso {
- Phdr *phdr;
- int phnum;
- size_t phentsize;
-- int refcnt;
- Sym *syms;
- Elf_Symndx *hashtab;
- uint32_t *ghashtab;
-@@ -971,7 +970,6 @@ static struct dso *load_library(const char *name, struct dso *needed_by)
- /* Search for the name to see if it's already loaded */
- for (p=head->next; p; p=p->next) {
- if (p->shortname && !strcmp(p->shortname, name)) {
-- p->refcnt++;
- return p;
- }
- }
-@@ -1034,7 +1032,6 @@ static struct dso *load_library(const char *name, struct dso *needed_by)
- if (!p->shortname && pathname != name)
- p->shortname = strrchr(p->name, '/')+1;
- close(fd);
-- p->refcnt++;
- return p;
- }
- }
-@@ -1074,7 +1071,6 @@ static struct dso *load_library(const char *name, struct dso *needed_by)
- memcpy(p, &temp_dso, sizeof temp_dso);
- p->dev = st.st_dev;
- p->ino = st.st_ino;
-- p->refcnt = 1;
- p->needed_by = needed_by;
- p->name = p->buf;
- strcpy(p->name, pathname);
---
-2.11.1
-
diff --git a/main/musl/0026-fix-threshold-constants-in-j0f-y0f-j1f-y1f.patch b/main/musl/0026-fix-threshold-constants-in-j0f-y0f-j1f-y1f.patch
deleted file mode 100644
index 52eed490a5..0000000000
--- a/main/musl/0026-fix-threshold-constants-in-j0f-y0f-j1f-y1f.patch
+++ /dev/null
@@ -1,103 +0,0 @@
-From 8cba1dc46c8f29261aa441e70bac798f2c2c0f58 Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Wed, 15 Mar 2017 02:55:49 +0100
-Subject: [PATCH] fix threshold constants in j0f, y0f, j1f, y1f
-
-partly following freebsd rev 279491
-https://svnweb.freebsd.org/base?view=revision&revision=279491
-(musl had some of the fixes before freebsd).
-
-the change should not matter much for j0f, y0f, but it improves
-j1f and y1f in [2.5,~3.75] (that is [0x40200000,~0x40700000]).
-near roots (e.g. around 3.8317 for j1f) there are still large
-ulp errors.
-
-dropped code that tried to raise inexact.
----
- src/math/j0f.c | 8 ++++----
- src/math/j1f.c | 17 ++++++++---------
- 2 files changed, 12 insertions(+), 13 deletions(-)
-
-diff --git a/src/math/j0f.c b/src/math/j0f.c
-index 45883dc4..fab554a3 100644
---- a/src/math/j0f.c
-+++ b/src/math/j0f.c
-@@ -208,8 +208,8 @@ static float pzerof(float x)
- GET_FLOAT_WORD(ix, x);
- ix &= 0x7fffffff;
- if (ix >= 0x41000000){p = pR8; q = pS8;}
-- else if (ix >= 0x40f71c58){p = pR5; q = pS5;}
-- else if (ix >= 0x4036db68){p = pR3; q = pS3;}
-+ else if (ix >= 0x409173eb){p = pR5; q = pS5;}
-+ else if (ix >= 0x4036d917){p = pR3; q = pS3;}
- else /*ix >= 0x40000000*/ {p = pR2; q = pS2;}
- z = 1.0f/(x*x);
- r = p[0]+z*(p[1]+z*(p[2]+z*(p[3]+z*(p[4]+z*p[5]))));
-@@ -304,8 +304,8 @@ static float qzerof(float x)
- GET_FLOAT_WORD(ix, x);
- ix &= 0x7fffffff;
- if (ix >= 0x41000000){p = qR8; q = qS8;}
-- else if (ix >= 0x40f71c58){p = qR5; q = qS5;}
-- else if (ix >= 0x4036db68){p = qR3; q = qS3;}
-+ else if (ix >= 0x409173eb){p = qR5; q = qS5;}
-+ else if (ix >= 0x4036d917){p = qR3; q = qS3;}
- else /*ix >= 0x40000000*/ {p = qR2; q = qS2;}
- z = 1.0f/(x*x);
- r = p[0]+z*(p[1]+z*(p[2]+z*(p[3]+z*(p[4]+z*p[5]))));
-diff --git a/src/math/j1f.c b/src/math/j1f.c
-index 58875af9..3434c53d 100644
---- a/src/math/j1f.c
-+++ b/src/math/j1f.c
-@@ -74,14 +74,13 @@ float j1f(float x)
- return 1/(x*x);
- if (ix >= 0x40000000) /* |x| >= 2 */
- return common(ix, fabsf(x), 0, sign);
-- if (ix >= 0x32000000) { /* |x| >= 2**-27 */
-+ if (ix >= 0x39000000) { /* |x| >= 2**-13 */
- z = x*x;
- r = z*(r00+z*(r01+z*(r02+z*r03)));
- s = 1+z*(s01+z*(s02+z*(s03+z*(s04+z*s05))));
- z = 0.5f + r/s;
- } else
-- /* raise inexact if x!=0 */
-- z = 0.5f + x;
-+ z = 0.5f;
- return z*x;
- }
-
-@@ -114,7 +113,7 @@ float y1f(float x)
- return 1/x;
- if (ix >= 0x40000000) /* |x| >= 2.0 */
- return common(ix,x,1,0);
-- if (ix < 0x32000000) /* x < 2**-27 */
-+ if (ix < 0x33000000) /* x < 2**-25 */
- return -tpi/x;
- z = x*x;
- u = U0[0]+z*(U0[1]+z*(U0[2]+z*(U0[3]+z*U0[4])));
-@@ -205,8 +204,8 @@ static float ponef(float x)
- GET_FLOAT_WORD(ix, x);
- ix &= 0x7fffffff;
- if (ix >= 0x41000000){p = pr8; q = ps8;}
-- else if (ix >= 0x40f71c58){p = pr5; q = ps5;}
-- else if (ix >= 0x4036db68){p = pr3; q = ps3;}
-+ else if (ix >= 0x409173eb){p = pr5; q = ps5;}
-+ else if (ix >= 0x4036d917){p = pr3; q = ps3;}
- else /*ix >= 0x40000000*/ {p = pr2; q = ps2;}
- z = 1.0f/(x*x);
- r = p[0]+z*(p[1]+z*(p[2]+z*(p[3]+z*(p[4]+z*p[5]))));
-@@ -300,9 +299,9 @@ static float qonef(float x)
-
- GET_FLOAT_WORD(ix, x);
- ix &= 0x7fffffff;
-- if (ix >= 0x40200000){p = qr8; q = qs8;}
-- else if (ix >= 0x40f71c58){p = qr5; q = qs5;}
-- else if (ix >= 0x4036db68){p = qr3; q = qs3;}
-+ if (ix >= 0x41000000){p = qr8; q = qs8;}
-+ else if (ix >= 0x409173eb){p = qr5; q = qs5;}
-+ else if (ix >= 0x4036d917){p = qr3; q = qs3;}
- else /*ix >= 0x40000000*/ {p = qr2; q = qs2;}
- z = 1.0f/(x*x);
- r = p[0]+z*(p[1]+z*(p[2]+z*(p[3]+z*(p[4]+z*p[5]))));
---
-2.11.1
-
diff --git a/main/musl/0027-precalculate-gnu-hash-rather-than-doing-it-lazily-in.patch b/main/musl/0027-precalculate-gnu-hash-rather-than-doing-it-lazily-in.patch
deleted file mode 100644
index 4ad7149fc8..0000000000
--- a/main/musl/0027-precalculate-gnu-hash-rather-than-doing-it-lazily-in.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From a393d5cc8d22b628fcc1da1b3a2cdae42ca643a9 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 15 Mar 2017 16:50:19 -0400
-Subject: [PATCH] precalculate gnu hash rather than doing it lazily in find_sym
- inner loop
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-this change was suggested based on testing done by Timo Teräs almost
-two years ago; the branch (and probably call prep overhead) in the
-inner loop was found to contribute noticably to total symbol lookup
-time. this change will make lookup slightly slower if libraries were
-built with only the traditional "sysv" ELF hash table, but based on
-how much slower lookup tends to be without the gnu hash table, it
-seems reasonable to assume that (1) users building without gnu hash
-don't care about dynamic linking performance, and (2) the extra time
-spent computing the gnu hash is likely to be dominated by the slowness
-of the sysv hash table lookup anyway.
----
- ldso/dynlink.c | 10 ++--------
- 1 file changed, 2 insertions(+), 8 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index 178fe27e..5361b844 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -258,18 +258,12 @@ static Sym *gnu_lookup_filtered(uint32_t h1, uint32_t *hashtab, struct dso *dso,
-
- static struct symdef find_sym(struct dso *dso, const char *s, int need_def)
- {
-- uint32_t h = 0, gh, gho, *ght;
-- size_t ghm = 0;
-+ uint32_t h = 0, gh = gnu_hash(s), gho = gh / (8*sizeof(size_t)), *ght;
-+ size_t ghm = 1ul << gh % (8*sizeof(size_t));
- struct symdef def = {0};
- for (; dso; dso=dso->syms_next) {
- Sym *sym;
- if ((ght = dso->ghashtab)) {
-- if (!ghm) {
-- gh = gnu_hash(s);
-- int maskbits = 8 * sizeof ghm;
-- gho = gh / maskbits;
-- ghm = 1ul << gh % maskbits;
-- }
- sym = gnu_lookup_filtered(gh, ght, dso, s, gho, ghm);
- } else {
- if (!h) h = sysv_hash(s);
---
-2.12.1
-
diff --git a/main/musl/0028-s390x-fix-fpreg_t-and-remove-unused-per_struct.patch b/main/musl/0028-s390x-fix-fpreg_t-and-remove-unused-per_struct.patch
deleted file mode 100644
index 6ad516e316..0000000000
--- a/main/musl/0028-s390x-fix-fpreg_t-and-remove-unused-per_struct.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 74bca42e1613c58805d7b048841c2fa8f8502158 Mon Sep 17 00:00:00 2001
-From: "Tuan M. Hoang" <tmhoang@flatglobe.org>
-Date: Tue, 14 Mar 2017 16:44:04 -0400
-Subject: [PATCH] s390x: fix fpreg_t and remove unused per_struct
-
-Including sys/procfs.h complains unknown type name 'fpreg_t' in
-bits/user.h. fpreg_t in bits/signal.h and elf_fpreg_t in bits/user.h
-are practically the same.
-
-per_struct is never used, even conflicts with kernel header
-asm/ptrace.h
----
- arch/s390x/bits/user.h | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/arch/s390x/bits/user.h b/arch/s390x/bits/user.h
-index 90f07b78..17bce16f 100644
---- a/arch/s390x/bits/user.h
-+++ b/arch/s390x/bits/user.h
-@@ -8,7 +8,7 @@ typedef union {
-
- typedef struct {
- unsigned fpc;
-- fpreg_t fprs[16];
-+ elf_fpreg_t fprs[16];
- } elf_fpregset_t;
-
- #define ELF_NGREG 27
-@@ -32,7 +32,7 @@ struct _user_per_struct {
- unsigned short perc_atmid;
- unsigned long address;
- unsigned char access_id;
--} per_struct;
-+};
-
- struct _user_regs_struct {
- struct _user_psw_struct psw;
---
-2.11.1
-
diff --git a/main/musl/0029-fix-POSIX-format-TZ-dst-transition-times-for-souther.patch b/main/musl/0029-fix-POSIX-format-TZ-dst-transition-times-for-souther.patch
deleted file mode 100644
index f3bcceb6dc..0000000000
--- a/main/musl/0029-fix-POSIX-format-TZ-dst-transition-times-for-souther.patch
+++ /dev/null
@@ -1,47 +0,0 @@
-From dbff2bb889bc831599b022c49252c69bf48f4e4e Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 15 Mar 2017 20:27:38 -0400
-Subject: [PATCH] fix POSIX-format TZ dst transition times for southern
- hemisphere
-
-the time of day at which daylight time switches over is specified in
-local time in the dst state prior to the transition. the code for
-handling this wrongly assumed it needed to switch whether dst or
-standard offset is applied to the transition time when the dst end
-date is before the dst start date (souther hemisphere summer), but in
-fact the end transition time should always be adjusted for dst, and
-the start transition time should always be adjusted for standard time.
----
- src/time/__tz.c | 12 ++++--------
- 1 file changed, 4 insertions(+), 8 deletions(-)
-
-diff --git a/src/time/__tz.c b/src/time/__tz.c
-index 0e0c4ea2..ffe8d402 100644
---- a/src/time/__tz.c
-+++ b/src/time/__tz.c
-@@ -373,18 +373,14 @@ void __secs_to_zone(long long t, int local, int *isdst, long *offset, long *oppo
- long long t0 = rule_to_secs(r0, y);
- long long t1 = rule_to_secs(r1, y);
-
-+ if (!local) {
-+ t0 += __timezone;
-+ t1 += dst_off;
-+ }
- if (t0 < t1) {
-- if (!local) {
-- t0 += __timezone;
-- t1 += dst_off;
-- }
- if (t >= t0 && t < t1) goto dst;
- goto std;
- } else {
-- if (!local) {
-- t1 += __timezone;
-- t0 += dst_off;
-- }
- if (t >= t1 && t < t0) goto std;
- goto dst;
- }
---
-2.11.1
-
diff --git a/main/musl/0030-fix-dlopen-dlsym-regression-opening-libs-already-loa.patch b/main/musl/0030-fix-dlopen-dlsym-regression-opening-libs-already-loa.patch
deleted file mode 100644
index 81fd2d7145..0000000000
--- a/main/musl/0030-fix-dlopen-dlsym-regression-opening-libs-already-loa.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 0c53178ec09478ca5f6ca6b5ad09d50a10c8f19d Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 21 Mar 2017 08:35:59 -0400
-Subject: [PATCH] fix dlopen/dlsym regression opening libs already loaded at
- startup
-
-commit 4ff234f6cba96403b5de6d29d48a59fd73252040 erroneously changed
-the condition for running certain code at dlopen time to check whether
-the library was already relocated rather than whether it already had
-its deps[] table filled. this was out of concern over whether the code
-under the conditional would be idempotent/safe to call on an
-already-loaded libraries. however, I missed a consideration in the
-opposite direction: if a library was loaded at program startup rather
-than dlopen, its deps[] table was not yet allocated/filled, and
-load_deps needs to be called at dlopen time in order for dlsym to be
-able to perform dependency-order symbol lookups.
-
-in order to avoid wasteful allocation of lazy-binding relocation
-tables for libraries which were already loaded and relocated at
-startup, the check for !p->relocated is not deleted entirely, but
-moved to apply only to allocation of these dables.
----
- ldso/dynlink.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index 5361b844..d20dbd87 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -1768,9 +1768,9 @@ void *dlopen(const char *file, int mode)
- }
-
- /* First load handling */
-- if (!p->relocated) {
-+ if (!p->deps) {
- load_deps(p);
-- if ((mode & RTLD_LAZY)) {
-+ if (!p->relocated && (mode & RTLD_LAZY)) {
- prepare_lazy(p);
- if (p->deps) for (i=0; p->deps[i]; i++)
- if (!p->deps[i]->relocated)
---
-2.12.1
-
diff --git a/main/musl/0031-s390x-provide-a-working-sigcontext-struct-definition.patch b/main/musl/0031-s390x-provide-a-working-sigcontext-struct-definition.patch
deleted file mode 100644
index 359da6fe97..0000000000
--- a/main/musl/0031-s390x-provide-a-working-sigcontext-struct-definition.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 555504166852a9b9c56ac4e1fb5bb1bf20cbf8ad Mon Sep 17 00:00:00 2001
-From: Bobby Bingham <koorogi@koorogi.info>
-Date: Sun, 26 Mar 2017 14:50:37 -0500
-Subject: s390x: provide sigcontext struct definition
-
-This structure was missed when creating the s390x port.
-
-This is based on the report and patch from William Pitcock, but with a
-modified structure defintion to more closely match the kernel's
-definition.
----
- arch/s390x/bits/signal.h | 15 +++++++++++++++
- 1 file changed, 15 insertions(+)
-
-diff --git a/arch/s390x/bits/signal.h b/arch/s390x/bits/signal.h
-index c866583..e5aca4b 100644
---- a/arch/s390x/bits/signal.h
-+++ b/arch/s390x/bits/signal.h
-@@ -33,6 +33,21 @@ typedef struct
- fpregset_t fpregs;
- } mcontext_t;
-
-+struct sigcontext {
-+ unsigned long oldmask[1];
-+ struct {
-+ struct {
-+ __psw_t psw;
-+ unsigned long gprs[16];
-+ unsigned acrs[16];
-+ } regs;
-+ struct {
-+ unsigned fpc;
-+ double fprs[16];
-+ } fpregs;
-+ } *sregs;
-+};
-+
- #else
-
- typedef struct {
---
-cgit v0.11.2
-
diff --git a/main/musl/0032-fix-support-for-dl_iterate_phdr-in-static-pie-binaries.patch b/main/musl/0032-fix-support-for-dl_iterate_phdr-in-static-pie-binaries.patch
deleted file mode 100644
index 5d1957e059..0000000000
--- a/main/musl/0032-fix-support-for-dl_iterate_phdr-in-static-pie-binaries.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From: Shiz <hi@shiz.me>
-Date: Wed, 12 Apr 2017 05:50:14 +0200
-Subject: [PATCH] Fix support for dl_iterate_phdr in static PIE binaries
-
-Commit 5bf7eba213cacc4c1220627c91c28deff2ffecda in musl upstream fixes TLS
-initialisation for static PIE binaries, but a similar fix is needed for the
-dl_iterate_phdr function. This fixes, among others, exception unwinding
-breakage on static PIE binaries.
----
- src/ldso/dl_iterate_phdr.c
- 1 file changed, 5 insertions(+)
-
-diff --git a/src/ldso/dl_iterate_phdr.c b/src/ldso/dl_iterate_phdr.c
---- a/src/ldso/dl_iterate_phdr.c 2017-01-01 04:27:17.000000000 +0100
-+++ b/src/ldso/dl_iterate_phdr.c 2017-04-12 03:19:44.000000000 +0200
-@@ -4,6 +4,9 @@
-
- #define AUX_CNT 38
-
-+__attribute__((__weak__, __visibility__("hidden")))
-+extern const size_t _DYNAMIC[];
-+
- static int static_dl_iterate_phdr(int(*callback)(struct dl_phdr_info *info, size_t size, void *data), void *data)
- {
- unsigned char *p;
-@@ -20,6 +23,8 @@
- phdr = (void *)p;
- if (phdr->p_type == PT_PHDR)
- base = aux[AT_PHDR] - phdr->p_vaddr;
-+ if (phdr->p_type == PT_DYNAMIC && _DYNAMIC)
-+ base = (size_t)_DYNAMIC - phdr->p_vaddr;
- if (phdr->p_type == PT_TLS)
- tls_phdr = phdr;
- }
----
-2.12.2
diff --git a/main/musl/0033-fix-scalbn-when-result-is-in-the-subnormal-range.patch b/main/musl/0033-fix-scalbn-when-result-is-in-the-subnormal-range.patch
deleted file mode 100644
index a29a18efe5..0000000000
--- a/main/musl/0033-fix-scalbn-when-result-is-in-the-subnormal-range.patch
+++ /dev/null
@@ -1,89 +0,0 @@
-From 8c44a060243f04283ca68dad199aab90336141db Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Mon, 3 Apr 2017 02:38:13 +0200
-Subject: [PATCH] fix scalbn when result is in the subnormal range
-
-in nearest rounding mode scalbn could introduce double rounding error
-when an intermediate value and the final result were both in the
-subnormal range e.g.
-
- scalbn(0x1.7ffffffffffffp-1, -1073)
-
-returned 0x1p-1073 instead of 0x1p-1074, because the intermediate
-computation got rounded to 0x1.8p-1023.
-
-with the fix an intermediate value can only be in the subnormal range
-if the final result is 0 which is correct even after double rounding.
-(there still can be two roundings so signals may be raised twice, but
-that's only observable with trapping exceptions which is not supported.)
----
- src/math/scalbn.c | 10 ++++++----
- src/math/scalbnf.c | 8 ++++----
- src/math/scalbnl.c | 8 ++++----
- 3 files changed, 14 insertions(+), 12 deletions(-)
-
-diff --git a/src/math/scalbn.c b/src/math/scalbn.c
-index 530e07c7..182f5610 100644
---- a/src/math/scalbn.c
-+++ b/src/math/scalbn.c
-@@ -16,11 +16,13 @@ double scalbn(double x, int n)
- n = 1023;
- }
- } else if (n < -1022) {
-- y *= 0x1p-1022;
-- n += 1022;
-+ /* make sure final n < -53 to avoid double
-+ rounding in the subnormal range */
-+ y *= 0x1p-1022 * 0x1p53;
-+ n += 1022 - 53;
- if (n < -1022) {
-- y *= 0x1p-1022;
-- n += 1022;
-+ y *= 0x1p-1022 * 0x1p53;
-+ n += 1022 - 53;
- if (n < -1022)
- n = -1022;
- }
-diff --git a/src/math/scalbnf.c b/src/math/scalbnf.c
-index 0b62c3c7..a5ad208b 100644
---- a/src/math/scalbnf.c
-+++ b/src/math/scalbnf.c
-@@ -16,11 +16,11 @@ float scalbnf(float x, int n)
- n = 127;
- }
- } else if (n < -126) {
-- y *= 0x1p-126f;
-- n += 126;
-+ y *= 0x1p-126f * 0x1p24f;
-+ n += 126 - 24;
- if (n < -126) {
-- y *= 0x1p-126f;
-- n += 126;
-+ y *= 0x1p-126f * 0x1p24f;
-+ n += 126 - 24;
- if (n < -126)
- n = -126;
- }
-diff --git a/src/math/scalbnl.c b/src/math/scalbnl.c
-index 08a4c587..db44dab0 100644
---- a/src/math/scalbnl.c
-+++ b/src/math/scalbnl.c
-@@ -20,11 +20,11 @@ long double scalbnl(long double x, int n)
- n = 16383;
- }
- } else if (n < -16382) {
-- x *= 0x1p-16382L;
-- n += 16382;
-+ x *= 0x1p-16382L * 0x1p113L;
-+ n += 16382 - 113;
- if (n < -16382) {
-- x *= 0x1p-16382L;
-- n += 16382;
-+ x *= 0x1p-16382L * 0x1p113L;
-+ n += 16382 - 113;
- if (n < -16382)
- n = -16382;
- }
---
-2.13.0
-
diff --git a/main/musl/0034-fix-regression-in-support-for-resolv.conf-attempts-o.patch b/main/musl/0034-fix-regression-in-support-for-resolv.conf-attempts-o.patch
deleted file mode 100644
index fdd9c028ce..0000000000
--- a/main/musl/0034-fix-regression-in-support-for-resolv.conf-attempts-o.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 1a7fa5e5211a67e89861583516ee1566609467a1 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Fri, 21 Apr 2017 17:34:26 -0400
-Subject: [PATCH] fix regression in support for resolv.conf attempts option
-
-commit d6cb08bcaca4ff1f921375510ca72bccea969c75 moved the code and
-introduced an incorrect string offset for the new parsing, probably
-due to a copy-and-paste error.
-
-patch by Stefan Sedich.
----
- src/network/resolvconf.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/src/network/resolvconf.c b/src/network/resolvconf.c
-index 2cf1f475..4c3e4c4b 100644
---- a/src/network/resolvconf.c
-+++ b/src/network/resolvconf.c
-@@ -45,8 +45,8 @@ int __get_resolv_conf(struct resolvconf *conf, char *search, size_t search_sz)
- if (z != p) conf->ndots = x > 15 ? 15 : x;
- }
- p = strstr(line, "attempts:");
-- if (p && isdigit(p[6])) {
-- p += 6;
-+ if (p && isdigit(p[9])) {
-+ p += 9;
- unsigned long x = strtoul(p, &z, 10);
- if (z != p) conf->attempts = x > 10 ? 10 : x;
- }
---
-2.13.0
-
diff --git a/main/musl/0035-make-ttyname-_r-return-ENODEV-rather-than-ENOENT.patch b/main/musl/0035-make-ttyname-_r-return-ENODEV-rather-than-ENOENT.patch
deleted file mode 100644
index c6fed3afd4..0000000000
--- a/main/musl/0035-make-ttyname-_r-return-ENODEV-rather-than-ENOENT.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From e1232f5b5185e8f337806841018369407e32e77d Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Fri, 21 Apr 2017 17:41:10 -0400
-Subject: [PATCH] make ttyname[_r] return ENODEV rather than ENOENT
-
-commit 0a950dcf15bb9f7274c804dca490e9e20e475f3e added checking that
-the pathname a tty device was opened with actually matches the device,
-which can fail to hold when a container inherits a tty from outside
-the container. the error code added at the time was ENOENT; however,
-discussions between affected applications and glibc developers
-resulted in glibc adopting ENODEV as the error for this condition, and
-this has now been documented in the man pages project as well. adopt
-the same error code for consistency.
-
-patch by Christian Brauner.
----
- src/unistd/ttyname_r.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/unistd/ttyname_r.c b/src/unistd/ttyname_r.c
-index a38ba4f2..33aa4ae1 100644
---- a/src/unistd/ttyname_r.c
-+++ b/src/unistd/ttyname_r.c
-@@ -23,7 +23,7 @@ int ttyname_r(int fd, char *name, size_t size)
- if (stat(name, &st1) || fstat(fd, &st2))
- return errno;
- if (st1.st_dev != st2.st_dev || st1.st_ino != st2.st_ino)
-- return ENOENT;
-+ return ENODEV;
-
- return 0;
- }
---
-2.13.0
-
diff --git a/main/musl/0036-implement-new-posix_spawn-flag-POSIX_SPAWN_SETSID.patch b/main/musl/0036-implement-new-posix_spawn-flag-POSIX_SPAWN_SETSID.patch
deleted file mode 100644
index 4e39d63697..0000000000
--- a/main/musl/0036-implement-new-posix_spawn-flag-POSIX_SPAWN_SETSID.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From bb439bb17108b67f3df9c9af824d3a607b5b059d Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sat, 22 Apr 2017 18:39:40 -0400
-Subject: [PATCH] implement new posix_spawn flag POSIX_SPAWN_SETSID
-
-this functionality has been adopted for inclusion in the next issue of
-POSIX as the result of Austin Group issue #1044.
-
-based on patch by Daurnimator.
----
- include/spawn.h | 1 +
- src/process/posix_spawn.c | 4 ++++
- 2 files changed, 5 insertions(+)
-
-diff --git a/include/spawn.h b/include/spawn.h
-index 29c799ee..f3e9e23c 100644
---- a/include/spawn.h
-+++ b/include/spawn.h
-@@ -21,6 +21,7 @@ struct sched_param;
- #define POSIX_SPAWN_SETSIGMASK 8
- #define POSIX_SPAWN_SETSCHEDPARAM 16
- #define POSIX_SPAWN_SETSCHEDULER 32
-+#define POSIX_SPAWN_SETSID 128
-
- typedef struct {
- int __flags;
-diff --git a/src/process/posix_spawn.c b/src/process/posix_spawn.c
-index 0bdf71cd..ea5d2998 100644
---- a/src/process/posix_spawn.c
-+++ b/src/process/posix_spawn.c
-@@ -73,6 +73,10 @@ static int child(void *args_vp)
- __libc_sigaction(i, &sa, 0);
- }
-
-+ if (attr->__flags & POSIX_SPAWN_SETSID)
-+ if ((ret=__syscall(SYS_setsid)) < 0)
-+ goto fail;
-+
- if (attr->__flags & POSIX_SPAWN_SETPGROUP)
- if ((ret=__syscall(SYS_setpgid, 0, attr->__pgrp)))
- goto fail;
---
-2.13.0
-
diff --git a/main/musl/0037-add-no-op-POSIX_SPAWN_USEVFORK-to-spawn.h.patch b/main/musl/0037-add-no-op-POSIX_SPAWN_USEVFORK-to-spawn.h.patch
deleted file mode 100644
index 735e919210..0000000000
--- a/main/musl/0037-add-no-op-POSIX_SPAWN_USEVFORK-to-spawn.h.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 77e895dcfadb156c9f378d26c9d0497ce2baf13f Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sat, 22 Apr 2017 20:40:09 -0400
-Subject: [PATCH] add no-op POSIX_SPAWN_USEVFORK to spawn.h
-
-the bit is reserved anyway for ABI-compat reasons; this documents it
-and makes it so we can have posix_spawnattr_setflags check for flag
-validity without hard-coding an anonymous bit value.
----
- include/spawn.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/include/spawn.h b/include/spawn.h
-index f3e9e23c..bba57ce4 100644
---- a/include/spawn.h
-+++ b/include/spawn.h
-@@ -21,6 +21,7 @@ struct sched_param;
- #define POSIX_SPAWN_SETSIGMASK 8
- #define POSIX_SPAWN_SETSCHEDPARAM 16
- #define POSIX_SPAWN_SETSCHEDULER 32
-+#define POSIX_SPAWN_USEVFORK 64
- #define POSIX_SPAWN_SETSID 128
-
- typedef struct {
---
-2.13.0
-
diff --git a/main/musl/0038-have-posix_spawnattr_setflags-check-for-supported-fl.patch b/main/musl/0038-have-posix_spawnattr_setflags-check-for-supported-fl.patch
deleted file mode 100644
index 3c2e944bbb..0000000000
--- a/main/musl/0038-have-posix_spawnattr_setflags-check-for-supported-fl.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From f9f686b7721e2cc35e20fa5c6df6da2dc4ac3f50 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sat, 22 Apr 2017 20:45:16 -0400
-Subject: [PATCH] have posix_spawnattr_setflags check for supported flags
-
-per POSIX, EINVAL is not a mandatory error, only an optional one. but
-reporting unsupported flags allows an application to fallback
-gracefully when a requested feature is not supported. this is not
-helpful now, but it may be in the future if additional flags are
-added.
-
-had this checking been present before, applications would have been
-able to check for the newly-added POSIX_SPAWN_SETSID feature (added in
-commit bb439bb17108b67f3df9c9af824d3a607b5b059d) at runtime.
----
- src/process/posix_spawnattr_setflags.c | 11 +++++++++++
- 1 file changed, 11 insertions(+)
-
-diff --git a/src/process/posix_spawnattr_setflags.c b/src/process/posix_spawnattr_setflags.c
-index f750c040..68780992 100644
---- a/src/process/posix_spawnattr_setflags.c
-+++ b/src/process/posix_spawnattr_setflags.c
-@@ -1,7 +1,18 @@
- #include <spawn.h>
-+#include <errno.h>
-
- int posix_spawnattr_setflags(posix_spawnattr_t *attr, short flags)
- {
-+ const unsigned all_flags =
-+ POSIX_SPAWN_RESETIDS |
-+ POSIX_SPAWN_SETPGROUP |
-+ POSIX_SPAWN_SETSIGDEF |
-+ POSIX_SPAWN_SETSIGMASK |
-+ POSIX_SPAWN_SETSCHEDPARAM |
-+ POSIX_SPAWN_SETSCHEDULER |
-+ POSIX_SPAWN_USEVFORK |
-+ POSIX_SPAWN_SETSID;
-+ if (flags & ~all_flags) return EINVAL;
- attr->__flags = flags;
- return 0;
- }
---
-2.13.0
-
diff --git a/main/musl/0039-fix-iconv-conversions-to-legacy-8bit-encodings.patch b/main/musl/0039-fix-iconv-conversions-to-legacy-8bit-encodings.patch
deleted file mode 100644
index be89291505..0000000000
--- a/main/musl/0039-fix-iconv-conversions-to-legacy-8bit-encodings.patch
+++ /dev/null
@@ -1,71 +0,0 @@
-From 97bd6b09dbe7478d5a90a06ecd9e5b59389d8eb9 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Sat, 27 May 2017 21:36:00 -0400
-Subject: [PATCH] fix iconv conversions to legacy 8bit encodings
-
-there was missing reverse-conversion logic for the case, handled
-specially in the character set tables, where a byte represents a
-unicode codepoint with the same value.
-
-this patch adds code to handle the case, and refactors the two-level
-10-bit table lookup for legacy character sets into a function to avoid
-repeating it yet another time as part of the fix.
----
- src/locale/iconv.c | 21 ++++++++++++---------
- 1 file changed, 12 insertions(+), 9 deletions(-)
-
-diff --git a/src/locale/iconv.c b/src/locale/iconv.c
-index 1eeea94e..4636307f 100644
---- a/src/locale/iconv.c
-+++ b/src/locale/iconv.c
-@@ -151,6 +151,14 @@ static void put_32(unsigned char *s, unsigned c, int e)
- #define mbrtowc_utf8 mbrtowc
- #define wctomb_utf8 wctomb
-
-+static unsigned legacy_map(const unsigned char *map, unsigned c)
-+{
-+ unsigned x = c - 128 + map[-1];
-+ x = legacy_chars[ map[x*5/4]>>2*x%8 |
-+ map[x*5/4+1]<<8-2*x%8 & 1023 ];
-+ return x ? x : c;
-+}
-+
- size_t iconv(iconv_t cd0, char **restrict in, size_t *restrict inb, char **restrict out, size_t *restrict outb)
- {
- size_t x=0;
-@@ -364,10 +372,7 @@ size_t iconv(iconv_t cd0, char **restrict in, size_t *restrict inb, char **restr
- break;
- default:
- if (c < 128+type) break;
-- c -= 128+type;
-- c = legacy_chars[ map[c*5/4]>>2*c%8 |
-- map[c*5/4+1]<<8-2*c%8 & 1023 ];
-- if (!c) c = *(unsigned char *)*in;
-+ c = legacy_map(map, c);
- if (c==1) goto ilseq;
- }
-
-@@ -392,17 +397,15 @@ size_t iconv(iconv_t cd0, char **restrict in, size_t *restrict inb, char **restr
- if (c > 0x7f) subst: x++, c='*';
- default:
- if (*outb < 1) goto toobig;
-- if (c < 128+totype) {
-+ if (c < 128+totype || (c<256 && c==legacy_map(tomap, c))) {
- revout:
- *(*out)++ = c;
- *outb -= 1;
- break;
- }
- d = c;
-- for (c=0; c<128-totype; c++) {
-- if (d == legacy_chars[ tomap[c*5/4]>>2*c%8 |
-- tomap[c*5/4+1]<<8-2*c%8 & 1023 ]) {
-- c += 128;
-+ for (c=128+totype; c<256; c++) {
-+ if (d == legacy_map(tomap, c)) {
- goto revout;
- }
- }
---
-2.13.0
-
diff --git a/main/musl/0040-fix-fchown-fallback-on-arches-without-chown-2.patch b/main/musl/0040-fix-fchown-fallback-on-arches-without-chown-2.patch
deleted file mode 100644
index bfe3a93ed9..0000000000
--- a/main/musl/0040-fix-fchown-fallback-on-arches-without-chown-2.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 81f4a1200a58a84c83e73da645d4f226a8785bdf Mon Sep 17 00:00:00 2001
-From: Samuel Holland <samuel@sholland.org>
-Date: Sat, 27 May 2017 15:20:01 -0500
-Subject: [PATCH] fix fchown fallback on arches without chown(2)
-
-The flags argument was missing, causing uninitalized data to be passed
-to fchownat(2). The correct value of flags should match the fallback for
-chown(3).
----
- src/unistd/fchown.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/unistd/fchown.c b/src/unistd/fchown.c
-index 03459849..75075eec 100644
---- a/src/unistd/fchown.c
-+++ b/src/unistd/fchown.c
-@@ -16,7 +16,7 @@ int fchown(int fd, uid_t uid, gid_t gid)
- #ifdef SYS_chown
- return syscall(SYS_chown, buf, uid, gid);
- #else
-- return syscall(SYS_fchownat, AT_FDCWD, buf, uid, gid);
-+ return syscall(SYS_fchownat, AT_FDCWD, buf, uid, gid, 0);
- #endif
-
- }
---
-2.13.0
-
diff --git a/main/musl/0041-towupper-towlower-fast-path-for-ascii-chars.patch b/main/musl/0041-towupper-towlower-fast-path-for-ascii-chars.patch
deleted file mode 100644
index 5a45eb39eb..0000000000
--- a/main/musl/0041-towupper-towlower-fast-path-for-ascii-chars.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 179766aa2ef06df854bc1d9616bf6f00ce49b7f9 Mon Sep 17 00:00:00 2001
-From: Natanael Copa <ncopa@alpinelinux.org>
-Date: Tue, 30 May 2017 14:23:24 +0200
-Subject: [PATCH] towupper/towlower: fast path for ascii chars
-
-Make a fast path for ascii chars which is assumed to be the most common
-case. This has significant performance benefit on xml json and similar
----
- src/ctype/towctrans.c | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/src/ctype/towctrans.c b/src/ctype/towctrans.c
-index 6af61875..cf13a862 100644
---- a/src/ctype/towctrans.c
-+++ b/src/ctype/towctrans.c
-@@ -1,3 +1,4 @@
-+#include <ctype.h>
- #include <wctype.h>
- #include "libc.h"
-
-@@ -9,7 +10,6 @@ static const struct {
- signed char lower;
- unsigned char len;
- } casemaps[] = {
-- CASEMAP('A','Z','a'),
- CASEMAP(0xc0,0xde,0xe0),
-
- CASELACE(0x0100,0x012e),
-@@ -257,12 +257,12 @@ static wchar_t __towcase(wchar_t wc, int lower)
-
- wint_t towupper(wint_t wc)
- {
-- return __towcase(wc, 0);
-+ return (unsigned)wc < 128 ? toupper(wc) : __towcase(wc, 0);
- }
-
- wint_t towlower(wint_t wc)
- {
-- return __towcase(wc, 1);
-+ return (unsigned)wc < 128 ? tolower(wc) : __towcase(wc, 1);
- }
-
- wint_t __towupper_l(wint_t c, locale_t l)
---
-2.13.0
-
diff --git a/main/musl/0042-fix-glob-failure-to-match-plain-to-root-directory.patch b/main/musl/0042-fix-glob-failure-to-match-plain-to-root-directory.patch
deleted file mode 100644
index cc9166248e..0000000000
--- a/main/musl/0042-fix-glob-failure-to-match-plain-to-root-directory.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 84eff797e3e38210cc311b000b1586b948b4fc35 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Thu, 8 Jun 2017 19:50:23 -0400
-Subject: [PATCH] fix glob failure to match plain "/" to root directory
-
-the check to prevent matching empty string wrongly blocked matching
-of "/" due to checking emptiness after stripping leading slashes
-rather than checking the full original argument string.
-
-simplified from patch by Julien Ramseier.
----
- src/regex/glob.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/regex/glob.c b/src/regex/glob.c
-index 5b6ff124..2d4d562e 100644
---- a/src/regex/glob.c
-+++ b/src/regex/glob.c
-@@ -179,7 +179,7 @@ int glob(const char *restrict pat, int flags, int (*errfunc)(const char *path, i
-
- if (strnlen(p, PATH_MAX+1) > PATH_MAX) return GLOB_NOSPACE;
-
-- if (*p) error = match_in_dir(d, p, flags, errfunc, &tail);
-+ if (*pat) error = match_in_dir(d, p, flags, errfunc, &tail);
- if (error == GLOB_NOSPACE) {
- freelist(&head);
- return error;
---
-2.13.0
-
diff --git a/main/musl/0043-catopen-set-errno-to-EOPNOTSUPP.patch b/main/musl/0043-catopen-set-errno-to-EOPNOTSUPP.patch
deleted file mode 100644
index 4d87ad4429..0000000000
--- a/main/musl/0043-catopen-set-errno-to-EOPNOTSUPP.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From af0517301677b4206c605caaef25f5d57a31b5b8 Mon Sep 17 00:00:00 2001
-From: "A. Wilcox" <AWilcox@Wilcox-Tech.com>
-Date: Fri, 9 Jun 2017 00:26:16 -0500
-Subject: [PATCH] catopen: set errno to EOPNOTSUPP
-
-Per 1003.1-2008 (2016 ed.), catopen must set errno on failure.
-
-We set errno to EOPNOTSUPP because musl does not currently support
-message catalogues.
----
- src/locale/catopen.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/src/locale/catopen.c b/src/locale/catopen.c
-index 4423c4d9..3fbc7717 100644
---- a/src/locale/catopen.c
-+++ b/src/locale/catopen.c
-@@ -1,6 +1,8 @@
- #include <nl_types.h>
-+#include <errno.h>
-
- nl_catd catopen (const char *name, int oflag)
- {
-+ errno = EOPNOTSUPP;
- return (nl_catd)-1;
- }
---
-2.13.0
-
diff --git a/main/musl/0044-getdate-correctly-specify-error-number.patch b/main/musl/0044-getdate-correctly-specify-error-number.patch
deleted file mode 100644
index e9e48068a9..0000000000
--- a/main/musl/0044-getdate-correctly-specify-error-number.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 10800088099ec4c27c1db6c613c8bbf9f76e4057 Mon Sep 17 00:00:00 2001
-From: "A. Wilcox" <AWilcox@Wilcox-Tech.com>
-Date: Fri, 9 Jun 2017 00:26:18 -0500
-Subject: [PATCH] getdate: correctly specify error number
-
-POSIX defines getdate error #5 as:
-"An I/O error is encountered while reading the template file."
-
-POSIX defines getdate error #7 as:
-"There is no line in the template that matches the input."
-
-This change correctly disambiguates between the two error conditions.
----
- src/time/getdate.c | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/src/time/getdate.c b/src/time/getdate.c
-index 89f21699..420cd8e4 100644
---- a/src/time/getdate.c
-+++ b/src/time/getdate.c
-@@ -37,7 +37,8 @@ struct tm *getdate(const char *s)
- }
- }
-
-- getdate_err = 7;
-+ if (ferror(f)) getdate_err = 5;
-+ else getdate_err = 7;
- out:
- if (f) fclose(f);
- pthread_setcancelstate(cs, 0);
---
-2.13.0
-
diff --git a/main/musl/0045-handle-mremap-failure-in-realloc-of-mmap-serviced-al.patch b/main/musl/0045-handle-mremap-failure-in-realloc-of-mmap-serviced-al.patch
deleted file mode 100644
index b5c86231d1..0000000000
--- a/main/musl/0045-handle-mremap-failure-in-realloc-of-mmap-serviced-al.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 1c86c7f5c26dd0569df7afc23ee9866fb3f645dc Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Thu, 15 Jun 2017 12:54:40 -0400
-Subject: [PATCH] handle mremap failure in realloc of mmap-serviced allocations
-
-mremap seems to always fail on nommu, and on some non-Linux
-implementations of the Linux syscall API, it at least fails to
-increase allocation size, and may fail to move (i.e. defragment) the
-existing mapping when shrinking it too. instead of failing realloc or
-leaving an over-sized allocation that may waste a large amount of
-memory, fallback to malloc-memcpy-free if mremap fails.
----
- src/malloc/malloc.c | 3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
-diff --git a/src/malloc/malloc.c b/src/malloc/malloc.c
-index c38c46fe..d5ee4280 100644
---- a/src/malloc/malloc.c
-+++ b/src/malloc/malloc.c
-@@ -406,7 +406,7 @@ void *realloc(void *p, size_t n)
- if (oldlen == newlen) return p;
- base = __mremap(base, oldlen, newlen, MREMAP_MAYMOVE);
- if (base == (void *)-1)
-- return newlen < oldlen ? p : 0;
-+ goto copy_realloc;
- self = (void *)(base + extra);
- self->csize = newlen - extra;
- return CHUNK_TO_MEM(self);
-@@ -439,6 +439,7 @@ void *realloc(void *p, size_t n)
- return CHUNK_TO_MEM(self);
- }
-
-+copy_realloc:
- /* As a last resort, allocate a new chunk and copy to it. */
- new = malloc(n-OVERHEAD);
- if (!new) return 0;
---
-2.13.0
-
diff --git a/main/musl/0046-handle-localtime-errors-in-ctime.patch b/main/musl/0046-handle-localtime-errors-in-ctime.patch
deleted file mode 100644
index 00a4dce65e..0000000000
--- a/main/musl/0046-handle-localtime-errors-in-ctime.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 5c10c33d2a35204ee76931625a007fcc8cca3228 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Thu, 15 Jun 2017 12:58:08 -0400
-Subject: [PATCH] handle localtime errors in ctime
-
-ctime passes the result from localtime directly to asctime. But in case
-of error, localtime returns 0. This causes an error (NULL pointer
-dereference) in asctime.
-
-based on patch by Omer Anson.
----
- src/time/ctime.c | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-diff --git a/src/time/ctime.c b/src/time/ctime.c
-index 185ec554..36029315 100644
---- a/src/time/ctime.c
-+++ b/src/time/ctime.c
-@@ -2,5 +2,7 @@
-
- char *ctime(const time_t *t)
- {
-- return asctime(localtime(t));
-+ struct tm *tm = localtime(t);
-+ if (!tm) return 0;
-+ return asctime(tm);
- }
---
-2.13.0
-
diff --git a/main/musl/0047-set-errno-when-getpw-_r-getgr-_r-and-getspnam_r-fail.patch b/main/musl/0047-set-errno-when-getpw-_r-getgr-_r-and-getspnam_r-fail.patch
deleted file mode 100644
index fa687c429d..0000000000
--- a/main/musl/0047-set-errno-when-getpw-_r-getgr-_r-and-getspnam_r-fail.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-From 2d7d05f031e014068a61d3076c6178513395d2ae Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Thu, 15 Jun 2017 13:01:34 -0400
-Subject: [PATCH] set errno when getpw*_r, getgr*_r, and getspnam_r fail
-
-these functions return an error code, and are not explicitly
-documented to set errno, but they are nonstandard and the historical
-implementations do set errno as well, and some applications expect
-this behavior. do likewise for compatibility.
-
-patch by Rudolph Pereira.
----
- src/passwd/getgr_r.c | 1 +
- src/passwd/getpw_r.c | 1 +
- src/passwd/getspnam_r.c | 8 +++++---
- 3 files changed, 7 insertions(+), 3 deletions(-)
-
-diff --git a/src/passwd/getgr_r.c b/src/passwd/getgr_r.c
-index 7246e8a4..f3e8f603 100644
---- a/src/passwd/getgr_r.c
-+++ b/src/passwd/getgr_r.c
-@@ -34,6 +34,7 @@ static int getgr_r(const char *name, gid_t gid, struct group *gr, char *buf, siz
- free(mem);
- free(line);
- pthread_setcancelstate(cs, 0);
-+ if (rv) errno = rv;
- return rv;
- }
-
-diff --git a/src/passwd/getpw_r.c b/src/passwd/getpw_r.c
-index e8cc811e..0c87ab05 100644
---- a/src/passwd/getpw_r.c
-+++ b/src/passwd/getpw_r.c
-@@ -27,6 +27,7 @@ static int getpw_r(const char *name, uid_t uid, struct passwd *pw, char *buf, si
- }
- free(line);
- pthread_setcancelstate(cs, 0);
-+ if (rv) errno = rv;
- return rv;
- }
-
-diff --git a/src/passwd/getspnam_r.c b/src/passwd/getspnam_r.c
-index 92339528..e488b67f 100644
---- a/src/passwd/getspnam_r.c
-+++ b/src/passwd/getspnam_r.c
-@@ -72,14 +72,15 @@ int getspnam_r(const char *name, struct spwd *sp, char *buf, size_t size, struct
-
- /* Disallow potentially-malicious user names */
- if (*name=='.' || strchr(name, '/') || !l)
-- return EINVAL;
-+ return errno = EINVAL;
-
- /* Buffer size must at least be able to hold name, plus some.. */
-- if (size < l+100) return ERANGE;
-+ if (size < l+100)
-+ return errno = EINVAL;
-
- /* Protect against truncation */
- if (snprintf(path, sizeof path, "/etc/tcb/%s/shadow", name) >= sizeof path)
-- return EINVAL;
-+ return errno = EINVAL;
-
- fd = open(path, O_RDONLY|O_NOFOLLOW|O_NONBLOCK|O_CLOEXEC);
- if (fd >= 0) {
-@@ -112,5 +113,6 @@ int getspnam_r(const char *name, struct spwd *sp, char *buf, size_t size, struct
- break;
- }
- pthread_cleanup_pop(1);
-+ if (rv) errno = rv;
- return rv;
- }
---
-2.13.0
-
diff --git a/main/musl/0048-handle-errors-from-localtime_r-in-ctime_r.patch b/main/musl/0048-handle-errors-from-localtime_r-in-ctime_r.patch
deleted file mode 100644
index 37d608e4a3..0000000000
--- a/main/musl/0048-handle-errors-from-localtime_r-in-ctime_r.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From 64f855874c32e192382df69f4765a7e32057a005 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 20 Jun 2017 20:31:35 -0400
-Subject: [PATCH] handle errors from localtime_r in ctime_r
-
-POSIX requires ctime_r return a null pointer on failure, which can
-occur if the input time_t value is not representable in broken down
-form.
-
-based on patch by Alexander Monakov.
----
- src/time/ctime_r.c | 5 ++---
- 1 file changed, 2 insertions(+), 3 deletions(-)
-
-diff --git a/src/time/ctime_r.c b/src/time/ctime_r.c
-index d2260a16..3e24aa68 100644
---- a/src/time/ctime_r.c
-+++ b/src/time/ctime_r.c
-@@ -2,7 +2,6 @@
-
- char *ctime_r(const time_t *t, char *buf)
- {
-- struct tm tm;
-- localtime_r(t, &tm);
-- return asctime_r(&tm, buf);
-+ struct tm tm, *tm_p = localtime_r(t, &tm);
-+ return tm_p ? asctime_r(tm_p, buf) : 0;
- }
---
-2.13.0
-
diff --git a/main/musl/0049-fix-iconv-conversions-for-iso88592-iso885916.patch b/main/musl/0049-fix-iconv-conversions-for-iso88592-iso885916.patch
deleted file mode 100644
index 721c2b31b9..0000000000
--- a/main/musl/0049-fix-iconv-conversions-for-iso88592-iso885916.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From b7bfb5c3a8330002250f304cb5deb522fa054eae Mon Sep 17 00:00:00 2001
-From: Bartosz Brachaczek <b.brachaczek@gmail.com>
-Date: Thu, 15 Jun 2017 23:30:48 +0200
-Subject: [PATCH] fix iconv conversions for iso88592-iso885916
-
-commit 97bd6b09dbe7478d5a90a06ecd9e5b59389d8eb9 refactored the table
-lookup into a function and introduced an error in index computation.
-the error caused garbage to be read from the table if the given charmap
-had a non-zero number of elided entries.
----
- src/locale/iconv.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/locale/iconv.c b/src/locale/iconv.c
-index 4636307f..fd2f2e01 100644
---- a/src/locale/iconv.c
-+++ b/src/locale/iconv.c
-@@ -153,7 +153,7 @@ static void put_32(unsigned char *s, unsigned c, int e)
-
- static unsigned legacy_map(const unsigned char *map, unsigned c)
- {
-- unsigned x = c - 128 + map[-1];
-+ unsigned x = c - 128 - map[-1];
- x = legacy_chars[ map[x*5/4]>>2*x%8 |
- map[x*5/4+1]<<8-2*x%8 & 1023 ];
- return x ? x : c;
---
-2.13.0
-
diff --git a/main/musl/0050-fix-regression-in-getspnam-_r-error-code-for-insuffi.patch b/main/musl/0050-fix-regression-in-getspnam-_r-error-code-for-insuffi.patch
deleted file mode 100644
index cc11a81ce1..0000000000
--- a/main/musl/0050-fix-regression-in-getspnam-_r-error-code-for-insuffi.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 91d34c4533e6bf6eacad7a9f001f28f9e5ebc656 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 21 Jun 2017 19:06:45 -0400
-Subject: [PATCH 50/50] fix regression in getspnam[_r] error code for
- insufficient buffer size
-
-commit 2d7d05f031e014068a61d3076c6178513395d2ae wrongly changed ERANGE
-to EINVAL, likely as the result of copy-and-paste error.
----
- src/passwd/getspnam_r.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/passwd/getspnam_r.c b/src/passwd/getspnam_r.c
-index e488b67f..541206fa 100644
---- a/src/passwd/getspnam_r.c
-+++ b/src/passwd/getspnam_r.c
-@@ -76,7 +76,7 @@ int getspnam_r(const char *name, struct spwd *sp, char *buf, size_t size, struct
-
- /* Buffer size must at least be able to hold name, plus some.. */
- if (size < l+100)
-- return errno = EINVAL;
-+ return errno = ERANGE;
-
- /* Protect against truncation */
- if (snprintf(path, sizeof path, "/etc/tcb/%s/shadow", name) >= sizeof path)
---
-2.13.1
-
diff --git a/main/musl/0051-fix-arm-run-time-abi-string-functions.patch b/main/musl/0051-fix-arm-run-time-abi-string-functions.patch
deleted file mode 100644
index a5327410e0..0000000000
--- a/main/musl/0051-fix-arm-run-time-abi-string-functions.patch
+++ /dev/null
@@ -1,177 +0,0 @@
-From e6def544358afd5648a428d2e02c147a1f901048 Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Tue, 21 Feb 2017 00:07:34 +0000
-Subject: [PATCH 51/51] fix arm run-time abi string functions
-
-in arm rtabi these __aeabi_* functions have special abi (they are
-only allowed to clobber r0,r1,r2,r3,ip,lr,cpsr), so they cannot
-be simple wrappers around normal string functions (which may
-clobber other registers), the safest solution is to write them in
-asm, a minimalistic implementation works because these are not
-supposed to be emitted by compilers or used in general.
----
- src/string/arm/__aeabi_memclr.c | 9 --------
- src/string/arm/__aeabi_memcpy.c | 9 --------
- src/string/arm/__aeabi_memcpy.s | 45 ++++++++++++++++++++++++++++++++++++++++
- src/string/arm/__aeabi_memmove.c | 9 --------
- src/string/arm/__aeabi_memset.c | 9 --------
- src/string/arm/__aeabi_memset.s | 31 +++++++++++++++++++++++++++
- 6 files changed, 76 insertions(+), 36 deletions(-)
- delete mode 100644 src/string/arm/__aeabi_memclr.c
- delete mode 100644 src/string/arm/__aeabi_memcpy.c
- create mode 100644 src/string/arm/__aeabi_memcpy.s
- delete mode 100644 src/string/arm/__aeabi_memmove.c
- delete mode 100644 src/string/arm/__aeabi_memset.c
- create mode 100644 src/string/arm/__aeabi_memset.s
-
-diff --git a/src/string/arm/__aeabi_memclr.c b/src/string/arm/__aeabi_memclr.c
-deleted file mode 100644
-index a25306d7..00000000
---- a/src/string/arm/__aeabi_memclr.c
-+++ /dev/null
-@@ -1,9 +0,0 @@
--#include <string.h>
--#include "libc.h"
--
--void __aeabi_memclr(void *dest, size_t n)
--{
-- memset(dest, 0, n);
--}
--weak_alias(__aeabi_memclr, __aeabi_memclr4);
--weak_alias(__aeabi_memclr, __aeabi_memclr8);
-diff --git a/src/string/arm/__aeabi_memcpy.c b/src/string/arm/__aeabi_memcpy.c
-deleted file mode 100644
-index 4ae5c777..00000000
---- a/src/string/arm/__aeabi_memcpy.c
-+++ /dev/null
-@@ -1,9 +0,0 @@
--#include <string.h>
--#include "libc.h"
--
--void __aeabi_memcpy(void *restrict dest, const void *restrict src, size_t n)
--{
-- memcpy(dest, src, n);
--}
--weak_alias(__aeabi_memcpy, __aeabi_memcpy4);
--weak_alias(__aeabi_memcpy, __aeabi_memcpy8);
-diff --git a/src/string/arm/__aeabi_memcpy.s b/src/string/arm/__aeabi_memcpy.s
-new file mode 100644
-index 00000000..3a527e41
---- /dev/null
-+++ b/src/string/arm/__aeabi_memcpy.s
-@@ -0,0 +1,45 @@
-+.syntax unified
-+
-+.global __aeabi_memcpy8
-+.global __aeabi_memcpy4
-+.global __aeabi_memcpy
-+.global __aeabi_memmove8
-+.global __aeabi_memmove4
-+.global __aeabi_memmove
-+
-+.type __aeabi_memcpy8,%function
-+.type __aeabi_memcpy4,%function
-+.type __aeabi_memcpy,%function
-+.type __aeabi_memmove8,%function
-+.type __aeabi_memmove4,%function
-+.type __aeabi_memmove,%function
-+
-+__aeabi_memmove8:
-+__aeabi_memmove4:
-+__aeabi_memmove:
-+ cmp r0, r1
-+ bls 3f
-+ cmp r2, #0
-+ beq 2f
-+ adds r0, r0, r2
-+ adds r2, r1, r2
-+1: subs r2, r2, #1
-+ ldrb r3, [r2]
-+ subs r0, r0, #1
-+ strb r3, [r0]
-+ cmp r1, r2
-+ bne 1b
-+2: bx lr
-+__aeabi_memcpy8:
-+__aeabi_memcpy4:
-+__aeabi_memcpy:
-+3: cmp r2, #0
-+ beq 2f
-+ adds r2, r1, r2
-+1: ldrb r3, [r1]
-+ adds r1, r1, #1
-+ strb r3, [r0]
-+ adds r0, r0, #1
-+ cmp r1, r2
-+ bne 1b
-+2: bx lr
-diff --git a/src/string/arm/__aeabi_memmove.c b/src/string/arm/__aeabi_memmove.c
-deleted file mode 100644
-index 951e7d39..00000000
---- a/src/string/arm/__aeabi_memmove.c
-+++ /dev/null
-@@ -1,9 +0,0 @@
--#include <string.h>
--#include "libc.h"
--
--void __aeabi_memmove(void *dest, const void *src, size_t n)
--{
-- memmove(dest, src, n);
--}
--weak_alias(__aeabi_memmove, __aeabi_memmove4);
--weak_alias(__aeabi_memmove, __aeabi_memmove8);
-diff --git a/src/string/arm/__aeabi_memset.c b/src/string/arm/__aeabi_memset.c
-deleted file mode 100644
-index 89299757..00000000
---- a/src/string/arm/__aeabi_memset.c
-+++ /dev/null
-@@ -1,9 +0,0 @@
--#include <string.h>
--#include "libc.h"
--
--void __aeabi_memset(void *dest, size_t n, int c)
--{
-- memset(dest, c, n);
--}
--weak_alias(__aeabi_memset, __aeabi_memset4);
--weak_alias(__aeabi_memset, __aeabi_memset8);
-diff --git a/src/string/arm/__aeabi_memset.s b/src/string/arm/__aeabi_memset.s
-new file mode 100644
-index 00000000..f9f60583
---- /dev/null
-+++ b/src/string/arm/__aeabi_memset.s
-@@ -0,0 +1,31 @@
-+.syntax unified
-+
-+.global __aeabi_memclr8
-+.global __aeabi_memclr4
-+.global __aeabi_memclr
-+.global __aeabi_memset8
-+.global __aeabi_memset4
-+.global __aeabi_memset
-+
-+.type __aeabi_memclr8,%function
-+.type __aeabi_memclr4,%function
-+.type __aeabi_memclr,%function
-+.type __aeabi_memset8,%function
-+.type __aeabi_memset4,%function
-+.type __aeabi_memset,%function
-+
-+__aeabi_memclr8:
-+__aeabi_memclr4:
-+__aeabi_memclr:
-+ movs r2, #0
-+__aeabi_memset8:
-+__aeabi_memset4:
-+__aeabi_memset:
-+ cmp r1, #0
-+ beq 2f
-+ adds r1, r0, r1
-+1: strb r2, [r0]
-+ adds r0, r0, #1
-+ cmp r1, r0
-+ bne 1b
-+2: bx lr
---
-2.13.1
-
diff --git a/main/musl/0052-ldso-avoid-spurious-possible-erroneous-work-for-libs.patch b/main/musl/0052-ldso-avoid-spurious-possible-erroneous-work-for-libs.patch
deleted file mode 100644
index 86ca7ea9e9..0000000000
--- a/main/musl/0052-ldso-avoid-spurious-possible-erroneous-work-for-libs.patch
+++ /dev/null
@@ -1,84 +0,0 @@
-From 66b53cfa8876342f7e7d7907d30c719c38cd5a1b Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 4 Jul 2017 10:58:13 -0400
-Subject: [PATCH 52/52] ldso: avoid spurious & possible erroneous work for libs
- with no deps
-
-a null pointer for a library's deps list was ambiguous: it could
-indicate either no dependencies or that the dependency list had not
-yet been populated. inability to distinguish could lead to spurious
-work when dlopen is called multiple times on a library with no deps,
-and due to related bugs, could actually cause other libraries to
-falsely appear as dependencies, translating into false positives for
-dlsym.
-
-avoid the problem by always initializing the deps pointer, pointing to
-an empty list if there are no deps. rather than wasting memory and
-introducing another failure path by allocating an empty list per
-library, simply share a global dummy list.
-
-further fixes will be needed for related bugs, and much of this code
-may end up being replaced.
----
- ldso/dynlink.c | 11 +++++++----
- 1 file changed, 7 insertions(+), 4 deletions(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index d20dbd87..239007ff 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -129,6 +129,7 @@ static size_t static_tls_cnt;
- static pthread_mutex_t init_fini_lock = { ._m_type = PTHREAD_MUTEX_RECURSIVE };
- static struct fdpic_loadmap *app_loadmap;
- static struct fdpic_dummy_loadmap app_dummy_loadmap;
-+static struct dso *const nodeps_dummy;
-
- struct debug *_dl_debug_addr = &debug;
-
-@@ -1125,6 +1126,7 @@ static void load_deps(struct dso *p)
- }
- }
- }
-+ if (!*deps) *deps = (struct dso **)&nodeps_dummy;
- }
-
- static void load_preload(char *s)
-@@ -1742,7 +1744,8 @@ void *dlopen(const char *file, int mode)
- free(p->funcdescs);
- if (p->rpath != p->rpath_orig)
- free(p->rpath);
-- free(p->deps);
-+ if (p->deps != &nodeps_dummy)
-+ free(p->deps);
- unmap_library(p);
- free(p);
- }
-@@ -1772,14 +1775,14 @@ void *dlopen(const char *file, int mode)
- load_deps(p);
- if (!p->relocated && (mode & RTLD_LAZY)) {
- prepare_lazy(p);
-- if (p->deps) for (i=0; p->deps[i]; i++)
-+ for (i=0; p->deps[i]; i++)
- if (!p->deps[i]->relocated)
- prepare_lazy(p->deps[i]);
- }
- /* Make new symbols global, at least temporarily, so we can do
- * relocations. If not RTLD_GLOBAL, this is reverted below. */
- add_syms(p);
-- if (p->deps) for (i=0; p->deps[i]; i++)
-+ for (i=0; p->deps[i]; i++)
- add_syms(p->deps[i]);
- reloc_all(p);
- }
-@@ -1878,7 +1881,7 @@ static void *do_dlsym(struct dso *p, const char *s, void *ra)
- return p->funcdescs + (sym - p->syms);
- if (sym && sym->st_value && (1<<(sym->st_info&0xf) & OK_TYPES))
- return laddr(p, sym->st_value);
-- if (p->deps) for (i=0; p->deps[i]; i++) {
-+ for (i=0; p->deps[i]; i++) {
- if ((ght = p->deps[i]->ghashtab)) {
- if (!gh) gh = gnu_hash(s);
- sym = gnu_lookup(gh, ght, p->deps[i], s);
---
-2.13.1
-
diff --git a/main/musl/0053-fix-regression-in-dlopen-promotion-from-RTLD_LOCAL-t.patch b/main/musl/0053-fix-regression-in-dlopen-promotion-from-RTLD_LOCAL-t.patch
deleted file mode 100644
index b5ba7cc87d..0000000000
--- a/main/musl/0053-fix-regression-in-dlopen-promotion-from-RTLD_LOCAL-t.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 43c423af5b8453afde86e4ba81e0fcc663ae7c22 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 4 Jul 2017 11:34:39 -0400
-Subject: [PATCH 53/53] fix regression in dlopen promotion from RTLD_LOCAL to
- RTLD_GLOBAL
-
-commit 4ff234f6cba96403b5de6d29d48a59fd73252040 inadvertently removed
-the logic to do this when changing the representation of global
-status.
----
- ldso/dynlink.c | 7 ++++++-
- 1 file changed, 6 insertions(+), 1 deletion(-)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index 239007ff..fc6a68b8 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -1771,7 +1771,8 @@ void *dlopen(const char *file, int mode)
- }
-
- /* First load handling */
-- if (!p->deps) {
-+ int first_load = !p->deps;
-+ if (first_load) {
- load_deps(p);
- if (!p->relocated && (mode & RTLD_LAZY)) {
- prepare_lazy(p);
-@@ -1779,11 +1780,15 @@ void *dlopen(const char *file, int mode)
- if (!p->deps[i]->relocated)
- prepare_lazy(p->deps[i]);
- }
-+ }
-+ if (first_load || (mode & RTLD_GLOBAL)) {
- /* Make new symbols global, at least temporarily, so we can do
- * relocations. If not RTLD_GLOBAL, this is reverted below. */
- add_syms(p);
- for (i=0; p->deps[i]; i++)
- add_syms(p->deps[i]);
-+ }
-+ if (first_load) {
- reloc_all(p);
- }
-
---
-2.13.1
-
diff --git a/main/musl/0054-allow-specifying-argv-0-when-invoking-a-program-via-.patch b/main/musl/0054-allow-specifying-argv-0-when-invoking-a-program-via-.patch
deleted file mode 100644
index 9855ac7778..0000000000
--- a/main/musl/0054-allow-specifying-argv-0-when-invoking-a-program-via-.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From f3055e0163aad1cebb0867078643b36643c5d95f Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 4 Jul 2017 16:58:28 -0400
-Subject: [PATCH 54/54] allow specifying argv[0] when invoking a program via
- ldso command
-
-previously, the pathname used to load the program was always used as
-argv[0]. the default remains the same, but a new --argv0 option can be
-used to provide a different value.
----
- ldso/dynlink.c | 7 +++++++
- 1 file changed, 7 insertions(+)
-
-diff --git a/ldso/dynlink.c b/ldso/dynlink.c
-index fc6a68b8..35a90aef 100644
---- a/ldso/dynlink.c
-+++ b/ldso/dynlink.c
-@@ -1437,6 +1437,7 @@ _Noreturn void __dls3(size_t *sp)
- size_t aux[AUX_CNT], *auxv;
- size_t i;
- char *env_preload=0;
-+ char *replace_argv0=0;
- size_t vdso_base;
- int argc = *sp;
- char **argv = (void *)(sp+1);
-@@ -1521,6 +1522,10 @@ _Noreturn void __dls3(size_t *sp)
- if (opt[7]=='=') env_preload = opt+8;
- else if (opt[7]) *argv = 0;
- else if (*argv) env_preload = *argv++;
-+ } else if (!memcmp(opt, "argv0", 5)) {
-+ if (opt[5]=='=') replace_argv0 = opt+6;
-+ else if (opt[5]) *argv = 0;
-+ else if (*argv) replace_argv0 = *argv++;
- } else {
- argv[0] = 0;
- }
-@@ -1677,6 +1682,8 @@ _Noreturn void __dls3(size_t *sp)
- debug.state = 0;
- _dl_debug_state();
-
-+ if (replace_argv0) argv[0] = replace_argv0;
-+
- errno = 0;
-
- CRTJMP((void *)aux[AT_ENTRY], argv-1);
---
-2.13.1
-
diff --git a/main/musl/0055-reapply-va_arg-hacks-removal-to-wprintf.patch b/main/musl/0055-reapply-va_arg-hacks-removal-to-wprintf.patch
deleted file mode 100644
index 944f5253b4..0000000000
--- a/main/musl/0055-reapply-va_arg-hacks-removal-to-wprintf.patch
+++ /dev/null
@@ -1,89 +0,0 @@
-From f6888840613a510c99915ba7732df8ec54d52637 Mon Sep 17 00:00:00 2001
-From: Alexander Monakov <amonakov@ispras.ru>
-Date: Tue, 4 Jul 2017 22:59:06 +0300
-Subject: [PATCH 55/55] reapply va_arg hacks removal to wprintf
-
-commit 58e2396a9aa23c132faf4198ca4d779c84955b38 missed that the same
-code was duplicated in implementation of vfwprintf.
----
- src/stdio/vfwprintf.c | 27 +--------------------------
- 1 file changed, 1 insertion(+), 26 deletions(-)
-
-diff --git a/src/stdio/vfwprintf.c b/src/stdio/vfwprintf.c
-index b8fff208..1e6e47cc 100644
---- a/src/stdio/vfwprintf.c
-+++ b/src/stdio/vfwprintf.c
-@@ -4,6 +4,7 @@
- #include <limits.h>
- #include <string.h>
- #include <stdarg.h>
-+#include <stddef.h>
- #include <wchar.h>
- #include <inttypes.h>
-
-@@ -19,14 +20,6 @@
-
- #define FLAGMASK (ALT_FORM|ZERO_PAD|LEFT_ADJ|PAD_POS|MARK_POS|GROUPED)
-
--#if UINT_MAX == ULONG_MAX
--#define LONG_IS_INT
--#endif
--
--#if SIZE_MAX != ULONG_MAX || UINTMAX_MAX != ULLONG_MAX
--#define ODD_TYPES
--#endif
--
- /* State machine to accept length modifiers + conversion specifiers.
- * Result is 0 on failure, or an argument type to pop on success. */
-
-@@ -35,23 +28,9 @@ enum {
- ZTPRE, JPRE,
- STOP,
- PTR, INT, UINT, ULLONG,
--#ifndef LONG_IS_INT
- LONG, ULONG,
--#else
--#define LONG INT
--#define ULONG UINT
--#endif
- SHORT, USHORT, CHAR, UCHAR,
--#ifdef ODD_TYPES
- LLONG, SIZET, IMAX, UMAX, PDIFF, UIPTR,
--#else
--#define LLONG ULLONG
--#define SIZET ULONG
--#define IMAX LLONG
--#define UMAX ULLONG
--#define PDIFF LONG
--#define UIPTR ULONG
--#endif
- DBL, LDBL,
- NOARG,
- MAXSTATE
-@@ -125,23 +104,19 @@ static void pop_arg(union arg *arg, int type, va_list *ap)
- case PTR: arg->p = va_arg(*ap, void *);
- break; case INT: arg->i = va_arg(*ap, int);
- break; case UINT: arg->i = va_arg(*ap, unsigned int);
--#ifndef LONG_IS_INT
- break; case LONG: arg->i = va_arg(*ap, long);
- break; case ULONG: arg->i = va_arg(*ap, unsigned long);
--#endif
- break; case ULLONG: arg->i = va_arg(*ap, unsigned long long);
- break; case SHORT: arg->i = (short)va_arg(*ap, int);
- break; case USHORT: arg->i = (unsigned short)va_arg(*ap, int);
- break; case CHAR: arg->i = (signed char)va_arg(*ap, int);
- break; case UCHAR: arg->i = (unsigned char)va_arg(*ap, int);
--#ifdef ODD_TYPES
- break; case LLONG: arg->i = va_arg(*ap, long long);
- break; case SIZET: arg->i = va_arg(*ap, size_t);
- break; case IMAX: arg->i = va_arg(*ap, intmax_t);
- break; case UMAX: arg->i = va_arg(*ap, uintmax_t);
- break; case PDIFF: arg->i = va_arg(*ap, ptrdiff_t);
- break; case UIPTR: arg->i = (uintptr_t)va_arg(*ap, void *);
--#endif
- break; case DBL: arg->f = va_arg(*ap, double);
- break; case LDBL: arg->f = va_arg(*ap, long double);
- }
---
-2.13.1
-
diff --git a/main/musl/0056-fix-undefined-behavior-in-free.patch b/main/musl/0056-fix-undefined-behavior-in-free.patch
deleted file mode 100644
index cccf2db4c0..0000000000
--- a/main/musl/0056-fix-undefined-behavior-in-free.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 60ab365cae24063b0f21821860ca16fb63e81f81 Mon Sep 17 00:00:00 2001
-From: Alexander Monakov <amonakov@ispras.ru>
-Date: Tue, 27 Jun 2017 20:58:47 +0300
-Subject: [PATCH 56/56] fix undefined behavior in free
-
----
- src/malloc/malloc.c | 5 +++--
- 1 file changed, 3 insertions(+), 2 deletions(-)
-
-diff --git a/src/malloc/malloc.c b/src/malloc/malloc.c
-index d5ee4280..9e05e1d6 100644
---- a/src/malloc/malloc.c
-+++ b/src/malloc/malloc.c
-@@ -450,14 +450,15 @@ copy_realloc:
-
- void free(void *p)
- {
-- struct chunk *self = MEM_TO_CHUNK(p);
-- struct chunk *next;
-+ struct chunk *self, *next;
- size_t final_size, new_size, size;
- int reclaim=0;
- int i;
-
- if (!p) return;
-
-+ self = MEM_TO_CHUNK(p);
-+
- if (IS_MMAPPED(self)) {
- size_t extra = self->psize;
- char *base = (char *)self - extra;
---
-2.13.1
-
diff --git a/main/musl/0057-fix-missing-volatile-qualifier-on-lock-in-__get_loca.patch b/main/musl/0057-fix-missing-volatile-qualifier-on-lock-in-__get_loca.patch
deleted file mode 100644
index d8e6e8adde..0000000000
--- a/main/musl/0057-fix-missing-volatile-qualifier-on-lock-in-__get_loca.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From a08910fc2cc739f631b75b2d09b8d72a0d64d285 Mon Sep 17 00:00:00 2001
-From: Jens Gustedt <Jens.Gustedt@inria.fr>
-Date: Sat, 24 Jun 2017 11:54:25 +0200
-Subject: [PATCH 57/57] fix missing volatile qualifier on lock in __get_locale
-
----
- src/locale/locale_map.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/locale/locale_map.c b/src/locale/locale_map.c
-index c3e59174..188fcf39 100644
---- a/src/locale/locale_map.c
-+++ b/src/locale/locale_map.c
-@@ -26,7 +26,7 @@ static const char envvars[][12] = {
-
- const struct __locale_map *__get_locale(int cat, const char *val)
- {
-- static int lock[2];
-+ static volatile int lock[2];
- static void *volatile loc_head;
- const struct __locale_map *p;
- struct __locale_map *new = 0;
---
-2.13.1
-
diff --git a/main/musl/0058-ppc64-fix-setjmp-longjmp-handling-of-TOC-pointer.patch b/main/musl/0058-ppc64-fix-setjmp-longjmp-handling-of-TOC-pointer.patch
deleted file mode 100644
index 37d188b77c..0000000000
--- a/main/musl/0058-ppc64-fix-setjmp-longjmp-handling-of-TOC-pointer.patch
+++ /dev/null
@@ -1,178 +0,0 @@
-From e31c8c2d796e8a9596503f079dc567c45f93c2ae Mon Sep 17 00:00:00 2001
-From: Bobby Bingham <koorogi@koorogi.info>
-Date: Fri, 4 Aug 2017 00:12:32 -0500
-Subject: [PATCH] ppc64: fix setjmp/longjmp handling of TOC pointer
-
-The TOC pointer is constant within a single dso, but needs to be saved
-and restored around cross-dso calls. The PLT stub saves it to the
-caller's stack frame, and the linker adds code to the caller to restore
-it.
-
-With a local call, as within a single dso or with static linking, this
-doesn't happen and the TOC pointer is always in r2. Therefore,
-setjmp/longjmp need to save/restore the TOC pointer from/to different
-locations depending on whether the call to setjmp was a local or non-local
-call.
-
-It is always safe for longjmp to restore to both r2 and the caller's stack.
-If the call to setjmp was local, and only r2 matters and the stack location
-will be ignored, but is required by the ABI to be reserved for the TOC
-pointer. If the call was non-local, then only the stack location matters,
-and whatever is restored into r2 will be clobbered anyway when the caller
-reloads r2 from the stack.
-
-A little extra care is required for sigsetjmp, because it uses setjmp
-internally. After the second return from this setjmp call, r2 will contain
-the caller's TOC pointer instead of libc's TOC pointer. We need to save
-and restore the correct libc pointer before we can tail call to
-__sigsetjmp_tail.
----
- src/setjmp/powerpc64/longjmp.s | 14 +++++++++-----
- src/setjmp/powerpc64/setjmp.s | 21 ++++++++++++++++-----
- src/signal/powerpc64/sigsetjmp.s | 21 ++++++++++++++-------
- 3 files changed, 39 insertions(+), 17 deletions(-)
-
-diff --git a/src/setjmp/powerpc64/longjmp.s b/src/setjmp/powerpc64/longjmp.s
-index 7f241c2d..81d45ff6 100644
---- a/src/setjmp/powerpc64/longjmp.s
-+++ b/src/setjmp/powerpc64/longjmp.s
-@@ -10,10 +10,14 @@ longjmp:
- # 1) restore cr
- ld 0, 1*8(3)
- mtcr 0
-- # 2) restore r1-r2 (SP and TOC)
-+ # 2) restore SP
- ld 1, 2*8(3)
-+ # 3) restore TOC into both r2 and the caller's stack.
-+ # Which location is required depends on whether setjmp was called
-+ # locally or non-locally, but it's always safe to restore to both.
- ld 2, 3*8(3)
-- # 3) restore r14-r31
-+ std 2, 24(1)
-+ # 4) restore r14-r31
- ld 14, 4*8(3)
- ld 15, 5*8(3)
- ld 16, 6*8(3)
-@@ -32,7 +36,7 @@ longjmp:
- ld 29, 19*8(3)
- ld 30, 20*8(3)
- ld 31, 21*8(3)
-- # 4) restore floating point registers f14-f31
-+ # 5) restore floating point registers f14-f31
- lfd 14, 22*8(3)
- lfd 15, 23*8(3)
- lfd 16, 24*8(3)
-@@ -52,7 +56,7 @@ longjmp:
- lfd 30, 38*8(3)
- lfd 31, 39*8(3)
-
-- # 5) restore vector registers v20-v31
-+ # 6) restore vector registers v20-v31
- addi 3, 3, 40*8
- lvx 20, 0, 3 ; addi 3, 3, 16
- lvx 21, 0, 3 ; addi 3, 3, 16
-@@ -67,7 +71,7 @@ longjmp:
- lvx 30, 0, 3 ; addi 3, 3, 16
- lvx 31, 0, 3
-
-- # 6) return r4 ? r4 : 1
-+ # 7) return r4 ? r4 : 1
- mr 3, 4
- cmpwi cr7, 4, 0
- bne cr7, 1f
-diff --git a/src/setjmp/powerpc64/setjmp.s b/src/setjmp/powerpc64/setjmp.s
-index d16d4bae..37683fda 100644
---- a/src/setjmp/powerpc64/setjmp.s
-+++ b/src/setjmp/powerpc64/setjmp.s
-@@ -1,24 +1,35 @@
-- .global ___setjmp
-- .hidden ___setjmp
- .global __setjmp
- .global _setjmp
- .global setjmp
- .type __setjmp,@function
- .type _setjmp,@function
- .type setjmp,@function
--___setjmp:
- __setjmp:
- _setjmp:
- setjmp:
-+ ld 5, 24(1) # load from the TOC slot in the caller's stack frame
-+ b __setjmp_toc
-+
-+ .localentry __setjmp,.-__setjmp
-+ .localentry _setjmp,.-_setjmp
-+ .localentry setjmp,.-setjmp
-+ mr 5, 2
-+
-+ .global __setjmp_toc
-+ .hidden __setjmp_toc
-+ # same as normal setjmp, except TOC pointer to save is provided in r5.
-+ # r4 would normally be the 2nd parameter, but we're using r5 to simplify calling from sigsetjmp.
-+ # solves the problem of knowing whether to save the TOC pointer from r2 or the caller's stack frame.
-+__setjmp_toc:
- # 0) store IP into 0, then into the jmpbuf pointed to by r3 (first arg)
- mflr 0
- std 0, 0*8(3)
- # 1) store cr
- mfcr 0
- std 0, 1*8(3)
-- # 2) store r1-r2 (SP and TOC)
-+ # 2) store SP and TOC
- std 1, 2*8(3)
-- std 2, 3*8(3)
-+ std 5, 3*8(3)
- # 3) store r14-31
- std 14, 4*8(3)
- std 15, 5*8(3)
-diff --git a/src/signal/powerpc64/sigsetjmp.s b/src/signal/powerpc64/sigsetjmp.s
-index 52ac1d03..410c2831 100644
---- a/src/signal/powerpc64/sigsetjmp.s
-+++ b/src/signal/powerpc64/sigsetjmp.s
-@@ -2,29 +2,36 @@
- .global __sigsetjmp
- .type sigsetjmp,%function
- .type __sigsetjmp,%function
-- .hidden ___setjmp
-+ .hidden __setjmp_toc
- sigsetjmp:
- __sigsetjmp:
- addis 2, 12, .TOC.-__sigsetjmp@ha
- addi 2, 2, .TOC.-__sigsetjmp@l
-+ ld 5, 24(1) # load from the TOC slot in the caller's stack frame
-+ b 1f
-+
- .localentry sigsetjmp,.-sigsetjmp
- .localentry __sigsetjmp,.-__sigsetjmp
-+ mr 5, 2
-
-+1:
- cmpwi cr7, 4, 0
-- beq- cr7, ___setjmp
-+ beq- cr7, __setjmp_toc
-
-- mflr 5
-- std 5, 512(3)
-- std 16, 512+8+8(3)
-+ mflr 6
-+ std 6, 512(3)
-+ std 2, 512+16(3)
-+ std 16, 512+24(3)
- mr 16, 3
-
-- bl ___setjmp
-+ bl __setjmp_toc
-
- mr 4, 3
- mr 3, 16
- ld 5, 512(3)
- mtlr 5
-- ld 16, 512+8+8(3)
-+ ld 2, 512+16(3)
-+ ld 16, 512+24(3)
-
- .hidden __sigsetjmp_tail
- b __sigsetjmp_tail
---
-2.13.1
-
diff --git a/main/musl/0059-fix-erroneous-stop-before-input-limit-in-mbsnrtowcs-.patch b/main/musl/0059-fix-erroneous-stop-before-input-limit-in-mbsnrtowcs-.patch
deleted file mode 100644
index 65b1cab4c1..0000000000
--- a/main/musl/0059-fix-erroneous-stop-before-input-limit-in-mbsnrtowcs-.patch
+++ /dev/null
@@ -1,78 +0,0 @@
-From 11ddc314b57196519316103b02acffe10299dad3 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Thu, 31 Aug 2017 14:30:28 -0400
-Subject: [PATCH 1/2] fix erroneous stop before input limit in mbsnrtowcs and
- wcsnrtombs
-
-the value computed as an output limit that bounds the amount of input
-consumed below the input limit was incorrectly being used as the
-actual amount of input consumed. instead, compute the actual amount of
-input consumed as a difference of pointers before and after the
-conversion.
-
-patch by Mikhail Kremnyov.
----
- src/multibyte/mbsnrtowcs.c | 4 +++-
- src/multibyte/wcsnrtombs.c | 4 +++-
- 2 files changed, 6 insertions(+), 2 deletions(-)
-
-diff --git a/src/multibyte/mbsnrtowcs.c b/src/multibyte/mbsnrtowcs.c
-index cae4caa2..931192e2 100644
---- a/src/multibyte/mbsnrtowcs.c
-+++ b/src/multibyte/mbsnrtowcs.c
-@@ -5,6 +5,7 @@ size_t mbsnrtowcs(wchar_t *restrict wcs, const char **restrict src, size_t n, si
- size_t l, cnt=0, n2;
- wchar_t *ws, wbuf[256];
- const char *s = *src;
-+ const char *tmp_s;
-
- if (!wcs) ws = wbuf, wn = sizeof wbuf / sizeof *wbuf;
- else ws = wcs;
-@@ -15,7 +16,7 @@ size_t mbsnrtowcs(wchar_t *restrict wcs, const char **restrict src, size_t n, si
-
- while ( s && wn && ( (n2=n/4)>=wn || n2>32 ) ) {
- if (n2>=wn) n2=wn;
-- n -= n2;
-+ tmp_s = s;
- l = mbsrtowcs(ws, &s, n2, st);
- if (!(l+1)) {
- cnt = l;
-@@ -26,6 +27,7 @@ size_t mbsnrtowcs(wchar_t *restrict wcs, const char **restrict src, size_t n, si
- ws += l;
- wn -= l;
- }
-+ n = s ? n - (s - tmp_s) : 0;
- cnt += l;
- }
- if (s) while (wn && n) {
-diff --git a/src/multibyte/wcsnrtombs.c b/src/multibyte/wcsnrtombs.c
-index 640cbbeb..676932b5 100644
---- a/src/multibyte/wcsnrtombs.c
-+++ b/src/multibyte/wcsnrtombs.c
-@@ -5,13 +5,14 @@ size_t wcsnrtombs(char *restrict dst, const wchar_t **restrict wcs, size_t wn, s
- size_t l, cnt=0, n2;
- char *s, buf[256];
- const wchar_t *ws = *wcs;
-+ const wchar_t *tmp_ws;
-
- if (!dst) s = buf, n = sizeof buf;
- else s = dst;
-
- while ( ws && n && ( (n2=wn)>=n || n2>32 ) ) {
- if (n2>=n) n2=n;
-- wn -= n2;
-+ tmp_ws = ws;
- l = wcsrtombs(s, &ws, n2, 0);
- if (!(l+1)) {
- cnt = l;
-@@ -22,6 +23,7 @@ size_t wcsnrtombs(char *restrict dst, const wchar_t **restrict wcs, size_t wn, s
- s += l;
- n -= l;
- }
-+ wn = ws ? wn - (ws - tmp_ws) : 0;
- cnt += l;
- }
- if (ws) while (n && wn) {
---
-2.13.3
-
diff --git a/main/musl/0060-fix-erroneous-acceptance-of-f4-9x-xx-xx-code-sequenc.patch b/main/musl/0060-fix-erroneous-acceptance-of-f4-9x-xx-xx-code-sequenc.patch
deleted file mode 100644
index 25dde60cc8..0000000000
--- a/main/musl/0060-fix-erroneous-acceptance-of-f4-9x-xx-xx-code-sequenc.patch
+++ /dev/null
@@ -1,30 +0,0 @@
-From 39db00afadc9d8d0456c46eab42b8cb8ff9f375c Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Fri, 1 Sep 2017 17:05:40 -0400
-Subject: [PATCH 2/2] fix erroneous acceptance of f4 9x xx xx code sequences by
- utf-8 decoder
-
-the DFA table controlling accepted ranges for the f4 prefix used an
-incorrect upper bound of 0xa0 where it should have been 0x90, allowing
-such sequences to be accepted and decoded as non-Unicode-scalar values
-0x110000 through 0x11ffff.
----
- src/multibyte/internal.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/multibyte/internal.c b/src/multibyte/internal.c
-index 7e1b1c03..2f5aaa91 100644
---- a/src/multibyte/internal.c
-+++ b/src/multibyte/internal.c
-@@ -9,7 +9,7 @@
- | x )
- #define F(x) ( ( x>=5 ? 0 : \
- x==0 ? R(0x90,0xc0) : \
-- x==4 ? R(0x80,0xa0) : \
-+ x==4 ? R(0x80,0x90) : \
- R(0x80,0xc0) ) \
- | ( R(0x80,0xc0) >> 6 ) \
- | ( R(0x80,0xc0) >> 12 ) \
---
-2.13.3
-
diff --git a/main/musl/0061-fix-OOB-reads-in-Xbyte_memmem.patch b/main/musl/0061-fix-OOB-reads-in-Xbyte_memmem.patch
deleted file mode 100644
index 42684d8328..0000000000
--- a/main/musl/0061-fix-OOB-reads-in-Xbyte_memmem.patch
+++ /dev/null
@@ -1,54 +0,0 @@
-From 51bdcdc424bd7169c8cccdc2de7cad17f5ea0f70 Mon Sep 17 00:00:00 2001
-From: Alexander Monakov <amonakov@ispras.ru>
-Date: Fri, 30 Jun 2017 00:35:33 +0300
-Subject: [PATCH 21/30] fix OOB reads in Xbyte_memmem
-
-Reported by Leah Neukirchen.
----
- src/string/memmem.c | 18 +++++++++---------
- 1 file changed, 9 insertions(+), 9 deletions(-)
-
-diff --git a/src/string/memmem.c b/src/string/memmem.c
-index 4be6a310..54a66e46 100644
---- a/src/string/memmem.c
-+++ b/src/string/memmem.c
-@@ -5,27 +5,27 @@
- static char *twobyte_memmem(const unsigned char *h, size_t k, const unsigned char *n)
- {
- uint16_t nw = n[0]<<8 | n[1], hw = h[0]<<8 | h[1];
-- for (h++, k--; k; k--, hw = hw<<8 | *++h)
-- if (hw == nw) return (char *)h-1;
-- return 0;
-+ for (h+=2, k-=2; k; k--, hw = hw<<8 | *h++)
-+ if (hw == nw) return (char *)h-2;
-+ return hw == nw ? (char *)h-2 : 0;
- }
-
- static char *threebyte_memmem(const unsigned char *h, size_t k, const unsigned char *n)
- {
- uint32_t nw = n[0]<<24 | n[1]<<16 | n[2]<<8;
- uint32_t hw = h[0]<<24 | h[1]<<16 | h[2]<<8;
-- for (h+=2, k-=2; k; k--, hw = (hw|*++h)<<8)
-- if (hw == nw) return (char *)h-2;
-- return 0;
-+ for (h+=3, k-=3; k; k--, hw = (hw|*h++)<<8)
-+ if (hw == nw) return (char *)h-3;
-+ return hw == nw ? (char *)h-3 : 0;
- }
-
- static char *fourbyte_memmem(const unsigned char *h, size_t k, const unsigned char *n)
- {
- uint32_t nw = n[0]<<24 | n[1]<<16 | n[2]<<8 | n[3];
- uint32_t hw = h[0]<<24 | h[1]<<16 | h[2]<<8 | h[3];
-- for (h+=3, k-=3; k; k--, hw = hw<<8 | *++h)
-- if (hw == nw) return (char *)h-3;
-- return 0;
-+ for (h+=4, k-=4; k; k--, hw = hw<<8 | *h++)
-+ if (hw == nw) return (char *)h-4;
-+ return hw == nw ? (char *)h-4 : 0;
- }
-
- #define MAX(a,b) ((a)>(b)?(a):(b))
---
-2.13.3
-
diff --git a/main/musl/0062-free-allocations-in-clearenv.patch b/main/musl/0062-free-allocations-in-clearenv.patch
deleted file mode 100644
index a5bb4bca00..0000000000
--- a/main/musl/0062-free-allocations-in-clearenv.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From cc0dbd5f09337c187156fe8b697245e6ea9263d0 Mon Sep 17 00:00:00 2001
-From: Alexander Monakov <amonakov@ispras.ru>
-Date: Sun, 3 Sep 2017 22:12:21 +0300
-Subject: free allocations in clearenv
-
-This aligns clearenv with the Linux man page by setting 'environ'
-rather than '*environ' to NULL, and stops it from leaking entries
-allocated by the libc.
----
- src/env/clearenv.c | 8 ++++++--
- 1 file changed, 6 insertions(+), 2 deletions(-)
-
-diff --git a/src/env/clearenv.c b/src/env/clearenv.c
-index 62d5095..da18775 100644
---- a/src/env/clearenv.c
-+++ b/src/env/clearenv.c
-@@ -1,10 +1,14 @@
- #define _GNU_SOURCE
- #include <stdlib.h>
-+#include "libc.h"
-
--extern char **__environ;
-+static void dummy(char *old, char *new) {}
-+weak_alias(dummy, __env_rm_add);
-
- int clearenv()
- {
-- __environ[0] = 0;
-+ char **e = __environ;
-+ __environ = 0;
-+ if (e) while (*e) __env_rm_add(*e++, 0);
- return 0;
- }
---
-cgit v0.11.2
-
diff --git a/main/musl/0063-fix-undefined-behavior-in-memset-due-to-missing-sequ.patch b/main/musl/0063-fix-undefined-behavior-in-memset-due-to-missing-sequ.patch
deleted file mode 100644
index e247b7f404..0000000000
--- a/main/musl/0063-fix-undefined-behavior-in-memset-due-to-missing-sequ.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 9d4c902c42b3fda368d7ea64bb9575c46228fa7f Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Tue, 29 Aug 2017 19:53:50 -0400
-Subject: [PATCH 11/30] fix undefined behavior in memset due to missing
- sequence points
-
-patch by Pascal Cuoq.
----
- src/string/memset.c | 12 ++++++++----
- 1 file changed, 8 insertions(+), 4 deletions(-)
-
-diff --git a/src/string/memset.c b/src/string/memset.c
-index f438b073..5613a148 100644
---- a/src/string/memset.c
-+++ b/src/string/memset.c
-@@ -11,12 +11,16 @@ void *memset(void *dest, int c, size_t n)
- * offsets are well-defined and in the dest region. */
-
- if (!n) return dest;
-- s[0] = s[n-1] = c;
-+ s[0] = c;
-+ s[n-1] = c;
- if (n <= 2) return dest;
-- s[1] = s[n-2] = c;
-- s[2] = s[n-3] = c;
-+ s[1] = c;
-+ s[2] = c;
-+ s[n-2] = c;
-+ s[n-3] = c;
- if (n <= 6) return dest;
-- s[3] = s[n-4] = c;
-+ s[3] = c;
-+ s[n-4] = c;
- if (n <= 8) return dest;
-
- /* Advance pointer to align it at a 4-byte boundary,
---
-2.13.3
-
diff --git a/main/musl/0064-handle-whitespace-before-in-scanf.patch b/main/musl/0064-handle-whitespace-before-in-scanf.patch
deleted file mode 100644
index f079ee3092..0000000000
--- a/main/musl/0064-handle-whitespace-before-in-scanf.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From 9255dad97e7bfd4165d1aa0f93f2aae321a7a4d8 Mon Sep 17 00:00:00 2001
-From: Bartosz Brachaczek <b.brachaczek@gmail.com>
-Date: Sun, 9 Jul 2017 23:00:18 +0200
-Subject: [PATCH 22/30] handle whitespace before %% in scanf
-
-this is mandated by C and POSIX standards and is in accordance with
-glibc behavior.
----
- src/stdio/vfscanf.c | 10 +++++++---
- src/stdio/vfwscanf.c | 8 ++++++--
- 2 files changed, 13 insertions(+), 5 deletions(-)
-
-diff --git a/src/stdio/vfscanf.c b/src/stdio/vfscanf.c
-index d4d2454b..9e030fc4 100644
---- a/src/stdio/vfscanf.c
-+++ b/src/stdio/vfscanf.c
-@@ -89,15 +89,19 @@ int vfscanf(FILE *restrict f, const char *restrict fmt, va_list ap)
- continue;
- }
- if (*p != '%' || p[1] == '%') {
-- p += *p=='%';
- shlim(f, 0);
-- c = shgetc(f);
-+ if (*p == '%') {
-+ p++;
-+ while (isspace((c=shgetc(f))));
-+ } else {
-+ c = shgetc(f);
-+ }
- if (c!=*p) {
- shunget(f);
- if (c<0) goto input_fail;
- goto match_fail;
- }
-- pos++;
-+ pos += shcnt(f);
- continue;
- }
-
-diff --git a/src/stdio/vfwscanf.c b/src/stdio/vfwscanf.c
-index 1ebc5cef..a7cd0923 100644
---- a/src/stdio/vfwscanf.c
-+++ b/src/stdio/vfwscanf.c
-@@ -117,8 +117,12 @@ int vfwscanf(FILE *restrict f, const wchar_t *restrict fmt, va_list ap)
- continue;
- }
- if (*p != '%' || p[1] == '%') {
-- p += *p=='%';
-- c = getwc(f);
-+ if (*p == '%') {
-+ p++;
-+ while (iswspace((c=getwc(f)))) pos++;
-+ } else {
-+ c = getwc(f);
-+ }
- if (c!=*p) {
- ungetwc(c, f);
- if (c<0) goto input_fail;
---
-2.13.3
-
diff --git a/main/musl/0065-make-syscall.h-consistent-with-linux.patch b/main/musl/0065-make-syscall.h-consistent-with-linux.patch
deleted file mode 100644
index dd546aca7d..0000000000
--- a/main/musl/0065-make-syscall.h-consistent-with-linux.patch
+++ /dev/null
@@ -1,296 +0,0 @@
-From 822dddfbf1884553341114663aff56ed87d57663 Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Sat, 18 Feb 2017 00:50:09 +0000
-Subject: [PATCH 23/30] make syscall.h consistent with linux
-
-most of the found naming differences don't matter to musl, because
-internally it unifies the syscall names that vary across targets,
-but for external code the names should match the kernel uapi.
-
-aarch64:
- __NR_fstatat is called __NR_newfstatat in linux.
- __NR_or1k_atomic got mistakenly copied from or1k.
-arm:
- __NR_arm_sync_file_range is an alias for __NR_sync_file_range2
- __NR_fadvise64_64 is called __NR_arm_fadvise64_64 in linux,
- the old non-arm name is kept too, it should not cause issues.
- (powerpc has similar nonstandard fadvise and it uses the
- normal name.)
-i386:
- __NR_madvise1 was removed from linux in commit
- 303395ac3bf3e2cb488435537d416bc840438fcb 2011-11-11
-microblaze:
- __NR_fadvise, __NR_fstatat, __NR_pread, __NR_pwrite
- had different name in linux.
-mips:
- __NR_fadvise, __NR_fstatat, __NR_pread, __NR_pwrite, __NR_select
- had different name in linux.
-mipsn32:
- __NR_fstatat is called __NR_newfstatat in linux.
-or1k:
- __NR__llseek is called __NR_llseek in linux.
- the old name is kept too because that's the name musl uses
- internally.
-powerpc:
- __NR_{get,set}res{gid,uid}32 was never present in powerpc linux.
- __NR_timerfd was briefly defined in linux but then got renamed.
----
- arch/aarch64/bits/syscall.h.in | 3 +--
- arch/arm/bits/syscall.h.in | 2 ++
- arch/i386/bits/syscall.h.in | 1 -
- arch/microblaze/bits/syscall.h.in | 8 ++++----
- arch/mips/bits/syscall.h.in | 10 +++++-----
- arch/mips/syscall_arch.h | 6 +++---
- arch/mipsn32/bits/syscall.h.in | 2 +-
- arch/mipsn32/syscall_arch.h | 6 +++---
- arch/or1k/bits/syscall.h.in | 1 +
- arch/powerpc/bits/syscall.h.in | 5 -----
- 10 files changed, 20 insertions(+), 24 deletions(-)
-
-diff --git a/arch/aarch64/bits/syscall.h.in b/arch/aarch64/bits/syscall.h.in
-index fd388eec..8b56afff 100644
---- a/arch/aarch64/bits/syscall.h.in
-+++ b/arch/aarch64/bits/syscall.h.in
-@@ -77,7 +77,7 @@
- #define __NR_splice 76
- #define __NR_tee 77
- #define __NR_readlinkat 78
--#define __NR_fstatat 79
-+#define __NR_newfstatat 79
- #define __NR_fstat 80
- #define __NR_sync 81
- #define __NR_fsync 82
-@@ -242,7 +242,6 @@
- #define __NR_perf_event_open 241
- #define __NR_accept4 242
- #define __NR_recvmmsg 243
--#define __NR_or1k_atomic 244
- #define __NR_wait4 260
- #define __NR_prlimit64 261
- #define __NR_fanotify_init 262
-diff --git a/arch/arm/bits/syscall.h.in b/arch/arm/bits/syscall.h.in
-index 9b129b23..0096fe7c 100644
---- a/arch/arm/bits/syscall.h.in
-+++ b/arch/arm/bits/syscall.h.in
-@@ -224,6 +224,7 @@
- #define __NR_tgkill 268
- #define __NR_utimes 269
- #define __NR_fadvise64_64 270
-+#define __NR_arm_fadvise64_64 270
- #define __NR_pciconfig_iobase 271
- #define __NR_pciconfig_read 272
- #define __NR_pciconfig_write 273
-@@ -295,6 +296,7 @@
- #define __NR_get_robust_list 339
- #define __NR_splice 340
- #define __NR_sync_file_range2 341
-+#define __NR_arm_sync_file_range 341
- #define __NR_tee 342
- #define __NR_vmsplice 343
- #define __NR_move_pages 344
-diff --git a/arch/i386/bits/syscall.h.in b/arch/i386/bits/syscall.h.in
-index 3a1d9270..1217f89a 100644
---- a/arch/i386/bits/syscall.h.in
-+++ b/arch/i386/bits/syscall.h.in
-@@ -218,7 +218,6 @@
- #define __NR_pivot_root 217
- #define __NR_mincore 218
- #define __NR_madvise 219
--#define __NR_madvise1 219
- #define __NR_getdents64 220
- #define __NR_fcntl64 221
- /* 223 is unused */
-diff --git a/arch/microblaze/bits/syscall.h.in b/arch/microblaze/bits/syscall.h.in
-index 109fcdeb..e5f928e3 100644
---- a/arch/microblaze/bits/syscall.h.in
-+++ b/arch/microblaze/bits/syscall.h.in
-@@ -178,8 +178,8 @@
- #define __NR_rt_sigtimedwait 177
- #define __NR_rt_sigqueueinfo 178
- #define __NR_rt_sigsuspend 179
--#define __NR_pread 180
--#define __NR_pwrite 181
-+#define __NR_pread64 180
-+#define __NR_pwrite64 181
- #define __NR_chown 182
- #define __NR_getcwd 183
- #define __NR_capget 184
-@@ -246,7 +246,7 @@
- #define __NR_io_getevents 247
- #define __NR_io_submit 248
- #define __NR_io_cancel 249
--#define __NR_fadvise 250
-+#define __NR_fadvise64 250
- #define __NR_exit_group 252
- #define __NR_lookup_dcookie 253
- #define __NR_epoll_create 254
-@@ -294,7 +294,7 @@
- #define __NR_mknodat 297
- #define __NR_fchownat 298
- #define __NR_futimesat 299
--#define __NR_fstatat 300
-+#define __NR_fstatat64 300
- #define __NR_unlinkat 301
- #define __NR_renameat 302
- #define __NR_linkat 303
-diff --git a/arch/mips/bits/syscall.h.in b/arch/mips/bits/syscall.h.in
-index 6c9b3d8c..1a2147a7 100644
---- a/arch/mips/bits/syscall.h.in
-+++ b/arch/mips/bits/syscall.h.in
-@@ -140,7 +140,7 @@
- #define __NR_setfsgid 4139
- #define __NR__llseek 4140
- #define __NR_getdents 4141
--#define __NR_select 4142
-+#define __NR__newselect 4142
- #define __NR_flock 4143
- #define __NR_msync 4144
- #define __NR_readv 4145
-@@ -198,8 +198,8 @@
- #define __NR_rt_sigtimedwait 4197
- #define __NR_rt_sigqueueinfo 4198
- #define __NR_rt_sigsuspend 4199
--#define __NR_pread 4200
--#define __NR_pwrite 4201
-+#define __NR_pread64 4200
-+#define __NR_pwrite64 4201
- #define __NR_chown 4202
- #define __NR_getcwd 4203
- #define __NR_capget 4204
-@@ -252,7 +252,7 @@
- #define __NR_remap_file_pages 4251
- #define __NR_set_tid_address 4252
- #define __NR_restart_syscall 4253
--#define __NR_fadvise 4254
-+#define __NR_fadvise64 4254
- #define __NR_statfs64 4255
- #define __NR_fstatfs64 4256
- #define __NR_timer_create 4257
-@@ -290,7 +290,7 @@
- #define __NR_mknodat 4290
- #define __NR_fchownat 4291
- #define __NR_futimesat 4292
--#define __NR_fstatat 4293
-+#define __NR_fstatat64 4293
- #define __NR_unlinkat 4294
- #define __NR_renameat 4295
- #define __NR_linkat 4296
-diff --git a/arch/mips/syscall_arch.h b/arch/mips/syscall_arch.h
-index 3ac4da21..666f413f 100644
---- a/arch/mips/syscall_arch.h
-+++ b/arch/mips/syscall_arch.h
-@@ -99,7 +99,7 @@ static inline long __syscall4(long n, long a, long b, long c, long d)
- if (r7) return -r2;
- long ret = r2;
- if (n == SYS_stat64 || n == SYS_fstat64 || n == SYS_lstat64) __stat_fix(b);
-- if (n == SYS_fstatat) __stat_fix(c);
-+ if (n == SYS_fstatat64) __stat_fix(c);
- return ret;
- }
-
-@@ -108,7 +108,7 @@ static inline long __syscall5(long n, long a, long b, long c, long d, long e)
- long r2 = (__syscall)(n, a, b, c, d, e);
- if (r2 > -4096UL) return r2;
- if (n == SYS_stat64 || n == SYS_fstat64 || n == SYS_lstat64) __stat_fix(b);
-- if (n == SYS_fstatat) __stat_fix(c);
-+ if (n == SYS_fstatat64) __stat_fix(c);
- return r2;
- }
-
-@@ -117,7 +117,7 @@ static inline long __syscall6(long n, long a, long b, long c, long d, long e, lo
- long r2 = (__syscall)(n, a, b, c, d, e, f);
- if (r2 > -4096UL) return r2;
- if (n == SYS_stat64 || n == SYS_fstat64 || n == SYS_lstat64) __stat_fix(b);
-- if (n == SYS_fstatat) __stat_fix(c);
-+ if (n == SYS_fstatat64) __stat_fix(c);
- return r2;
- }
-
-diff --git a/arch/mipsn32/bits/syscall.h.in b/arch/mipsn32/bits/syscall.h.in
-index d6b24e8f..cd843a76 100644
---- a/arch/mipsn32/bits/syscall.h.in
-+++ b/arch/mipsn32/bits/syscall.h.in
-@@ -253,7 +253,7 @@
- #define __NR_mknodat 6253
- #define __NR_fchownat 6254
- #define __NR_futimesat 6255
--#define __NR_fstatat 6256
-+#define __NR_newfstatat 6256
- #define __NR_unlinkat 6257
- #define __NR_renameat 6258
- #define __NR_linkat 6259
-diff --git a/arch/mipsn32/syscall_arch.h b/arch/mipsn32/syscall_arch.h
-index 37e71a7e..93a026f6 100644
---- a/arch/mipsn32/syscall_arch.h
-+++ b/arch/mipsn32/syscall_arch.h
-@@ -97,7 +97,7 @@ static inline long __syscall4(long n, long a, long b, long c, long d)
- if (r7) return -r2;
- long ret = r2;
- if (n == SYS_stat || n == SYS_fstat || n == SYS_lstat) __stat_fix(b);
-- if (n == SYS_fstatat) __stat_fix(c);
-+ if (n == SYS_newfstatat) __stat_fix(c);
- return ret;
- }
-
-@@ -106,7 +106,7 @@ static inline long __syscall5(long n, long a, long b, long c, long d, long e)
- long r2 = (__syscall)(n, a, b, c, d, e);
- if (r2 > -4096UL) return r2;
- if (n == SYS_stat || n == SYS_fstat || n == SYS_lstat) __stat_fix(b);
-- if (n == SYS_fstatat) __stat_fix(c);
-+ if (n == SYS_newfstatat) __stat_fix(c);
- return r2;
- }
-
-@@ -115,7 +115,7 @@ static inline long __syscall6(long n, long a, long b, long c, long d, long e, lo
- long r2 = (__syscall)(n, a, b, c, d, e, f);
- if (r2 > -4096UL) return r2;
- if (n == SYS_stat || n == SYS_fstat || n == SYS_lstat) __stat_fix(b);
-- if (n == SYS_fstatat) __stat_fix(c);
-+ if (n == SYS_newfstatat) __stat_fix(c);
- return r2;
- }
-
-diff --git a/arch/or1k/bits/syscall.h.in b/arch/or1k/bits/syscall.h.in
-index 89788a9d..54581fb4 100644
---- a/arch/or1k/bits/syscall.h.in
-+++ b/arch/or1k/bits/syscall.h.in
-@@ -61,6 +61,7 @@
- #define __NR_quotactl 60
- #define __NR_getdents64 61
- #define __NR__llseek 62
-+#define __NR_llseek 62
- #define __NR_read 63
- #define __NR_write 64
- #define __NR_readv 65
-diff --git a/arch/powerpc/bits/syscall.h.in b/arch/powerpc/bits/syscall.h.in
-index 9d022321..35f7033e 100644
---- a/arch/powerpc/bits/syscall.h.in
-+++ b/arch/powerpc/bits/syscall.h.in
-@@ -162,16 +162,12 @@
- #define __NR_sched_rr_get_interval 161
- #define __NR_nanosleep 162
- #define __NR_mremap 163
--#define __NR_setresuid32 164
- #define __NR_setresuid 164
--#define __NR_getresuid32 165
- #define __NR_getresuid 165
- #define __NR_query_module 166
- #define __NR_poll 167
- #define __NR_nfsservctl 168
--#define __NR_setresgid32 169
- #define __NR_setresgid 169
--#define __NR_getresgid32 170
- #define __NR_getresgid 170
- #define __NR_prctl 171
- #define __NR_rt_sigreturn 172
-@@ -306,7 +302,6 @@
- #define __NR_epoll_pwait 303
- #define __NR_utimensat 304
- #define __NR_signalfd 305
--#define __NR_timerfd 306
- #define __NR_timerfd_create 306
- #define __NR_eventfd 307
- #define __NR_sync_file_range2 308
---
-2.13.3
-
diff --git a/main/musl/0066-fix-signal-masking-race-in-pthread_create-with-prior.patch b/main/musl/0066-fix-signal-masking-race-in-pthread_create-with-prior.patch
deleted file mode 100644
index ddf61e3962..0000000000
--- a/main/musl/0066-fix-signal-masking-race-in-pthread_create-with-prior.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From 9e01be6e49b9ae433072207f420ef33c8189eb78 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 6 Sep 2017 20:37:19 -0400
-Subject: [PATCH 24/30] fix signal masking race in pthread_create with priority
- attributes
-
-if the parent thread was able to set the new thread's priority before
-it reached the check for 'startlock', the new thread failed to restore
-its signal mask and thus ran with all signals blocked.
-
-concept for patch by Sergei, who reported the issue; unnecessary
-changes were removed and comments added since the whole 'startlock'
-thing is non-idiomatic and confusing. eventually it should be replaced
-with use of idiomatic synchronization primitives.
----
- src/thread/pthread_create.c | 9 +++++++--
- 1 file changed, 7 insertions(+), 2 deletions(-)
-
-diff --git a/src/thread/pthread_create.c b/src/thread/pthread_create.c
-index 49f2f729..6cbf85b3 100644
---- a/src/thread/pthread_create.c
-+++ b/src/thread/pthread_create.c
-@@ -131,9 +131,14 @@ void __do_cleanup_pop(struct __ptcb *cb)
- static int start(void *p)
- {
- pthread_t self = p;
-+ /* States for startlock:
-+ * 0 = no need for start sync
-+ * 1 = waiting for parent to do work
-+ * 2 = failure in parent, child must abort
-+ * 3 = success in parent, child must restore sigmask */
- if (self->startlock[0]) {
- __wait(self->startlock, 0, 1, 1);
-- if (self->startlock[0]) {
-+ if (self->startlock[0] == 2) {
- self->detached = 2;
- pthread_exit(0);
- }
-@@ -295,7 +300,7 @@ int __pthread_create(pthread_t *restrict res, const pthread_attr_t *restrict att
- if (do_sched) {
- ret = __syscall(SYS_sched_setscheduler, new->tid,
- attr._a_policy, &attr._a_prio);
-- a_store(new->startlock, ret<0 ? 2 : 0);
-+ a_store(new->startlock, ret<0 ? 2 : 3);
- __wake(new->startlock, 1, 1);
- if (ret < 0) return -ret;
- }
---
-2.13.3
-
diff --git a/main/musl/0067-don-t-treat-numeric-port-strings-as-servent-records-.patch b/main/musl/0067-don-t-treat-numeric-port-strings-as-servent-records-.patch
deleted file mode 100644
index 8e5fd0068e..0000000000
--- a/main/musl/0067-don-t-treat-numeric-port-strings-as-servent-records-.patch
+++ /dev/null
@@ -1,73 +0,0 @@
-From 565dbee24d4bf55728be1c274fca1e7f3196fd73 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 6 Sep 2017 21:42:15 -0400
-Subject: [PATCH 25/30] don't treat numeric port strings as servent records in
- getservby*()
-
-some applications use getservbyport to find port numbers that are not
-assigned to a service; if getservbyport always succeeds with a numeric
-string as the result, they fail to find any available ports.
-
-POSIX doesn't seem to mandate the behavior one way or another. it
-specifies an abstract service database, which an implementation could
-define to include numeric port strings, but it makes more sense to
-align behavior with traditional implementations.
-
-based on patch by A. Wilcox. the original patch only changed
-getservbyport[_r]. to maintain a consistent view of the "service
-database", I have also modified getservbyname[_r] to exclude numeric
-port strings.
----
- src/network/getservbyname_r.c | 6 ++++++
- src/network/getservbyport_r.c | 4 ++++
- 2 files changed, 10 insertions(+)
-
-diff --git a/src/network/getservbyname_r.c b/src/network/getservbyname_r.c
-index ad3d6164..cad6317a 100644
---- a/src/network/getservbyname_r.c
-+++ b/src/network/getservbyname_r.c
-@@ -5,6 +5,7 @@
- #include <inttypes.h>
- #include <errno.h>
- #include <string.h>
-+#include <stdlib.h>
- #include "lookup.h"
-
- #define ALIGN (sizeof(struct { char a; char *b; }) - sizeof(char *))
-@@ -17,6 +18,11 @@ int getservbyname_r(const char *name, const char *prots,
-
- *res = 0;
-
-+ /* Don't treat numeric port number strings as service records. */
-+ char *end = "";
-+ strtoul(name, &end, 10);
-+ if (!*end) return ENOENT;
-+
- /* Align buffer */
- align = -(uintptr_t)buf & ALIGN-1;
- if (buflen < 2*sizeof(char *)+align)
-diff --git a/src/network/getservbyport_r.c b/src/network/getservbyport_r.c
-index 0ae0e415..b7f21c6b 100644
---- a/src/network/getservbyport_r.c
-+++ b/src/network/getservbyport_r.c
-@@ -5,6 +5,7 @@
- #include <inttypes.h>
- #include <errno.h>
- #include <string.h>
-+#include <stdlib.h>
-
- int getservbyport_r(int port, const char *prots,
- struct servent *se, char *buf, size_t buflen, struct servent **res)
-@@ -51,6 +52,9 @@ int getservbyport_r(int port, const char *prots,
- break;
- }
-
-+ /* A numeric port string is not a service record. */
-+ if (strtol(buf, 0, 10)==ntohs(port)) return ENOENT;
-+
- *res = se;
- return 0;
- }
---
-2.13.3
-
diff --git a/main/musl/0068-fix-glob-descent-into-.-and-.-with-GLOB_PERIOD.patch b/main/musl/0068-fix-glob-descent-into-.-and-.-with-GLOB_PERIOD.patch
deleted file mode 100644
index 99f3547ed1..0000000000
--- a/main/musl/0068-fix-glob-descent-into-.-and-.-with-GLOB_PERIOD.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-From 8c4be3e2209d2a1d3874b8bc2b474668fcbbbac6 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 6 Sep 2017 21:59:22 -0400
-Subject: [PATCH 26/30] fix glob descent into . and .. with GLOB_PERIOD
-
-GLOB_PERIOD is a gnu extension, and GNU glob does not seem to honor it
-except in the last path component. it's not clear whether this a bug
-or intentional, but it seems reasonable that it should exclude the
-special entries . and .. when walking.
-
-changes based on report and analysis by Julien Ramseier.
----
- src/regex/glob.c | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/src/regex/glob.c b/src/regex/glob.c
-index 2d4d562e..6f8425ca 100644
---- a/src/regex/glob.c
-+++ b/src/regex/glob.c
-@@ -100,6 +100,10 @@ static int match_in_dir(const char *d, const char *p, int flags, int (*errfunc)(
- continue;
- if (p2 && de->d_type && !S_ISDIR(de->d_type<<12) && !S_ISLNK(de->d_type<<12))
- continue;
-+ if (p2 && de->d_name[0]=='.' && !de->d_name[1])
-+ continue;
-+ if (p2 && de->d_name[0]=='.' && de->d_name[1]=='.' && !de->d_name[2])
-+ continue;
- if (*d) {
- memcpy(name, d, l);
- name[l] = '/';
---
-2.13.3
-
diff --git a/main/musl/0069-work-around-incorrect-EPERM-from-mmap-syscall.patch b/main/musl/0069-work-around-incorrect-EPERM-from-mmap-syscall.patch
deleted file mode 100644
index 076f39c5ae..0000000000
--- a/main/musl/0069-work-around-incorrect-EPERM-from-mmap-syscall.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From da438ee1fc516c41ba1790cef7be551a9e244397 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Wed, 6 Sep 2017 22:09:28 -0400
-Subject: [PATCH 27/30] work around incorrect EPERM from mmap syscall
-
-under some conditions, the mmap syscall wrongly fails with EPERM
-instead of ENOMEM when memory is exhausted; this is probably the
-result of the kernel trying to fit the allocation somewhere that
-crosses into the kernel range or below mmap_min_addr. in any case it's
-a conformance bug, so work around it. for now, only handle the case of
-anonymous mappings with no requested address; in other cases EPERM may
-be a legitimate error.
-
-this indirectly fixes the possibility of malloc failing with the wrong
-errno value.
----
- src/mman/mmap.c | 9 +++++++--
- 1 file changed, 7 insertions(+), 2 deletions(-)
-
-diff --git a/src/mman/mmap.c b/src/mman/mmap.c
-index 19caadbd..15924033 100644
---- a/src/mman/mmap.c
-+++ b/src/mman/mmap.c
-@@ -14,6 +14,7 @@ weak_alias(dummy, __vm_wait);
-
- void *__mmap(void *start, size_t len, int prot, int flags, int fd, off_t off)
- {
-+ long ret;
- if (off & OFF_MASK) {
- errno = EINVAL;
- return MAP_FAILED;
-@@ -26,10 +27,14 @@ void *__mmap(void *start, size_t len, int prot, int flags, int fd, off_t off)
- __vm_wait();
- }
- #ifdef SYS_mmap2
-- return (void *)syscall(SYS_mmap2, start, len, prot, flags, fd, off/UNIT);
-+ ret = __syscall(SYS_mmap2, start, len, prot, flags, fd, off/UNIT);
- #else
-- return (void *)syscall(SYS_mmap, start, len, prot, flags, fd, off);
-+ ret = __syscall(SYS_mmap, start, len, prot, flags, fd, off);
- #endif
-+ /* Fixup incorrect EPERM from kernel. */
-+ if (ret == -EPERM && !start && (flags&MAP_ANON) && !(flags&MAP_FIXED))
-+ ret = -ENOMEM;
-+ return (void *)__syscall_ret(ret);
- }
-
- weak_alias(__mmap, mmap);
---
-2.13.3
-
diff --git a/main/musl/0070-powerpc-64-fix-MAP_NORESERVE-and-MAP_LOCKED-in-mman..patch b/main/musl/0070-powerpc-64-fix-MAP_NORESERVE-and-MAP_LOCKED-in-mman..patch
deleted file mode 100644
index 8c6a8507a3..0000000000
--- a/main/musl/0070-powerpc-64-fix-MAP_NORESERVE-and-MAP_LOCKED-in-mman..patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From c10bc61508dc52b8315084e628f36a6c3c2dabb1 Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Sun, 10 Sep 2017 13:34:54 +0200
-Subject: [PATCH 28/30] powerpc{64}: fix MAP_NORESERVE and MAP_LOCKED in mman.h
-
-MAP_{NORESERVE,LOCKED} have different values on powerpc than in generic.
----
- arch/powerpc/bits/mman.h | 7 ++++++-
- arch/powerpc64/bits/mman.h | 5 +++++
- 2 files changed, 11 insertions(+), 1 deletion(-)
-
-diff --git a/arch/powerpc/bits/mman.h b/arch/powerpc/bits/mman.h
-index b6a15a12..95ec4358 100644
---- a/arch/powerpc/bits/mman.h
-+++ b/arch/powerpc/bits/mman.h
-@@ -1,4 +1,9 @@
--#define PROT_SAO 0x10
-+#define PROT_SAO 0x10
-+
-+#undef MAP_NORESERVE
-+#define MAP_NORESERVE 0x40
-+#undef MAP_LOCKED
-+#define MAP_LOCKED 0x80
-
- #undef MCL_CURRENT
- #define MCL_CURRENT 0x2000
-diff --git a/arch/powerpc64/bits/mman.h b/arch/powerpc64/bits/mman.h
-index f5974f82..95ec4358 100644
---- a/arch/powerpc64/bits/mman.h
-+++ b/arch/powerpc64/bits/mman.h
-@@ -1,5 +1,10 @@
- #define PROT_SAO 0x10
-
-+#undef MAP_NORESERVE
-+#define MAP_NORESERVE 0x40
-+#undef MAP_LOCKED
-+#define MAP_LOCKED 0x80
-+
- #undef MCL_CURRENT
- #define MCL_CURRENT 0x2000
- #undef MCL_FUTURE
---
-2.13.3
-
diff --git a/main/musl/0071-fix-use-of-memset-without-declaration-in-sched.h-cpu.patch b/main/musl/0071-fix-use-of-memset-without-declaration-in-sched.h-cpu.patch
deleted file mode 100644
index 2701b282d3..0000000000
--- a/main/musl/0071-fix-use-of-memset-without-declaration-in-sched.h-cpu.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 48be5b6313d7b827acf555769e93b389fa9f6307 Mon Sep 17 00:00:00 2001
-From: Rich Felker <dalias@aerifal.cx>
-Date: Thu, 28 Sep 2017 12:57:06 -0400
-Subject: [PATCH 29/30] fix use of memset without declaration in sched.h cpu
- set macros
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-patch by Jörg Krause.
----
- include/sched.h | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/include/sched.h b/include/sched.h
-index d1cccb70..05d40b1e 100644
---- a/include/sched.h
-+++ b/include/sched.h
-@@ -72,6 +72,7 @@ int setns(int, int);
-
- void *memcpy(void *__restrict, const void *__restrict, size_t);
- int memcmp(const void *, const void *, size_t);
-+void *memset (void *, int, size_t);
- void *calloc(size_t, size_t);
- void free(void *);
-
---
-2.13.3
-
diff --git a/main/musl/2001-thread-do-not-attempt-to-join-detached-threads-in-pt.patch b/main/musl/2001-thread-do-not-attempt-to-join-detached-threads-in-pt.patch
deleted file mode 100644
index f376c929af..0000000000
--- a/main/musl/2001-thread-do-not-attempt-to-join-detached-threads-in-pt.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From bda7e30e6bf5e20269a08775574c9d75b27c4387 Mon Sep 17 00:00:00 2001
-From: William Pitcock <nenolod@dereferenced.org>
-Date: Tue, 1 Aug 2017 23:08:49 +0000
-Subject: [PATCH] thread: do not attempt to join detached threads in
- pthread_join()
-
-A thread which is detached releases it's resources and TCB upon thread termination.
-Therefore a thread which is detached is not joinable as any underlying futex will not
-be incremented, resulting in a deadlock. Accordingly, POSIX defines calling
-pthread_join() on a detached thread as undefined behaviour.
-
-We attempt, where possible, to detect attempts to join detached threads and crash
-instead, to bring the undefined behaviour to the programmer's attention.
----
- src/thread/pthread_join.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/src/thread/pthread_join.c b/src/thread/pthread_join.c
-index 52111489..b7175c09 100644
---- a/src/thread/pthread_join.c
-+++ b/src/thread/pthread_join.c
-@@ -11,6 +11,7 @@ int __pthread_timedjoin_np(pthread_t t, void **res, const struct timespec *at)
- __pthread_testcancel();
- __pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &cs);
- if (cs == PTHREAD_CANCEL_ENABLE) __pthread_setcancelstate(cs, 0);
-+ if (t->detached) a_crash();
- while ((tmp = t->tid) && r != ETIMEDOUT && r != EINVAL)
- r = __timedwait_cp(&t->tid, tmp, CLOCK_REALTIME, at, 0);
- __pthread_setcancelstate(cs, 0);
---
-2.13.3
-
diff --git a/main/musl/3001-s390x-add-bits-hwcap.h.patch b/main/musl/3001-s390x-add-bits-hwcap.h.patch
deleted file mode 100644
index cde9978944..0000000000
--- a/main/musl/3001-s390x-add-bits-hwcap.h.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From 84a4677797d5c6cfae949f963aafd2fb3260d67a Mon Sep 17 00:00:00 2001
-From: Szabolcs Nagy <nsz@port70.net>
-Date: Tue, 29 Aug 2017 19:46:46 +0200
-Subject: [PATCH] s390x: add bits/hwcap.h
-
-based on linux arch/s390/include/asm/elf.h
-(these macros should be exported into uapi, but they are not)
----
- arch/s390x/bits/hwcap.h | 15 +++++++++++++++
- 1 file changed, 15 insertions(+)
- create mode 100644 arch/s390x/bits/hwcap.h
-
-diff --git a/arch/s390x/bits/hwcap.h b/arch/s390x/bits/hwcap.h
-new file mode 100644
-index 00000000..ecc6ce1f
---- /dev/null
-+++ b/arch/s390x/bits/hwcap.h
-@@ -0,0 +1,15 @@
-+#define HWCAP_S390_ESAN3 1
-+#define HWCAP_S390_ZARCH 2
-+#define HWCAP_S390_STFLE 4
-+#define HWCAP_S390_MSA 8
-+#define HWCAP_S390_LDISP 16
-+#define HWCAP_S390_EIMM 32
-+#define HWCAP_S390_DFP 64
-+#define HWCAP_S390_HPAGE 128
-+#define HWCAP_S390_ETF3EH 256
-+#define HWCAP_S390_HIGH_GPRS 512
-+#define HWCAP_S390_TE 1024
-+#define HWCAP_S390_VXRS 2048
-+#define HWCAP_S390_VXRS_BCD 4096
-+#define HWCAP_S390_VXRS_EXT 8192
-+#define HWCAP_S390_GS 16384
---
-2.14.1
-
diff --git a/main/musl/APKBUILD b/main/musl/APKBUILD
index 398087b72f..bafdf61646 100644
--- a/main/musl/APKBUILD
+++ b/main/musl/APKBUILD
@@ -1,8 +1,8 @@
# Contributor: William Pitcock <nenolod@dereferenced.org>
# Maintainer: Timo Teräs <timo.teras@iki.fi>
pkgname=musl
-pkgver=1.1.16
-pkgrel=22
+pkgver=1.1.17
+pkgrel=0
pkgdesc="the musl c library (libc) implementation"
url="http://www.musl-libc.org/"
arch="all"
@@ -17,83 +17,10 @@ nolibc) ;;
*) subpackages="$subpackages $pkgname-utils";;
esac
source="http://www.musl-libc.org/releases/musl-$pkgver.tar.gz
- 0001-fix-strftime-y-for-negative-years.patch
- 0002-make-globfree-safe-after-failed-glob-from-over-lengt.patch
- 0003-reduce-impact-of-REG_-namespace-pollution-in-x86-_64.patch
- 0004-fix-getopt-_long-clobbering-of-optopt-on-success.patch
- 0005-treat-base-1-as-an-error-in-strtol-family-functions.patch
- 0006-fix-crash-from-corrupted-tls-module-list-after-faile.patch
- 0007-fix-bindtextdomain-logic-error-deactivating-other-do.patch
- 0008-fix-use-of-uninitialized-pointer-in-gettext-core.patch
- 0009-avoid-unbounded-strlen-in-gettext-functions.patch
- 0010-s390x-implement-dlsym.patch
- 0011-fix-build-regression-in-arm-atomics-asm-with-new-bin.patch
- 0012-allow-page-size-to-vary-on-arm.patch
- 0013-fix-lsearch-and-lfind-to-pass-key-as-first-arg-to-th.patch
- 0014-fix-ld-behavior-dependent-crash-in-ppc64-ldso-startu.patch
- 0015-treat-STB_WEAK-and-STB_GNU_UNIQUE-like-STB_GLOBAL-in.patch
- 0016-rework-ldso-handling-of-global-symbol-table-for-cons.patch
- 0017-reorder-addend-handling-before-symbol-lookup-in-relo.patch
- 0018-emulate-lazy-relocation-as-deferrable-relocation.patch
- 0019-fix-free-of-uninitialized-buffer-pointer-on-error-in.patch
- 0020-in-static-dl_iterate_phdr-fix-use-of-possibly-uninit.patch
- 0021-fix-possible-fd-leak-unrestored-cancellation-state-o.patch
- 0022-fix-wide-scanf-s-use-of-a-compound-literal-past-its-.patch
- 0023-fix-one-byte-overflow-in-legacy-getpass-function.patch
- 0024-avoid-loading-of-multiple-libc-versions-via-explicit.patch
- 0025-remove-unused-refcnt-field-for-shared-libraries.patch
- 0026-fix-threshold-constants-in-j0f-y0f-j1f-y1f.patch
- 0027-precalculate-gnu-hash-rather-than-doing-it-lazily-in.patch
- 0028-s390x-fix-fpreg_t-and-remove-unused-per_struct.patch
- 0029-fix-POSIX-format-TZ-dst-transition-times-for-souther.patch
- 0030-fix-dlopen-dlsym-regression-opening-libs-already-loa.patch
- 0031-s390x-provide-a-working-sigcontext-struct-definition.patch
- 0032-fix-support-for-dl_iterate_phdr-in-static-pie-binaries.patch
- 0033-fix-scalbn-when-result-is-in-the-subnormal-range.patch
- 0034-fix-regression-in-support-for-resolv.conf-attempts-o.patch
- 0035-make-ttyname-_r-return-ENODEV-rather-than-ENOENT.patch
- 0036-implement-new-posix_spawn-flag-POSIX_SPAWN_SETSID.patch
- 0037-add-no-op-POSIX_SPAWN_USEVFORK-to-spawn.h.patch
- 0038-have-posix_spawnattr_setflags-check-for-supported-fl.patch
- 0039-fix-iconv-conversions-to-legacy-8bit-encodings.patch
- 0040-fix-fchown-fallback-on-arches-without-chown-2.patch
- 0041-towupper-towlower-fast-path-for-ascii-chars.patch
- 0042-fix-glob-failure-to-match-plain-to-root-directory.patch
- 0043-catopen-set-errno-to-EOPNOTSUPP.patch
- 0044-getdate-correctly-specify-error-number.patch
- 0045-handle-mremap-failure-in-realloc-of-mmap-serviced-al.patch
- 0046-handle-localtime-errors-in-ctime.patch
- 0047-set-errno-when-getpw-_r-getgr-_r-and-getspnam_r-fail.patch
- 0048-handle-errors-from-localtime_r-in-ctime_r.patch
- 0049-fix-iconv-conversions-for-iso88592-iso885916.patch
- 0050-fix-regression-in-getspnam-_r-error-code-for-insuffi.patch
- 0051-fix-arm-run-time-abi-string-functions.patch
- 0052-ldso-avoid-spurious-possible-erroneous-work-for-libs.patch
- 0053-fix-regression-in-dlopen-promotion-from-RTLD_LOCAL-t.patch
- 0054-allow-specifying-argv-0-when-invoking-a-program-via-.patch
- 0055-reapply-va_arg-hacks-removal-to-wprintf.patch
- 0056-fix-undefined-behavior-in-free.patch
- 0057-fix-missing-volatile-qualifier-on-lock-in-__get_loca.patch
- 0058-ppc64-fix-setjmp-longjmp-handling-of-TOC-pointer.patch
- 0059-fix-erroneous-stop-before-input-limit-in-mbsnrtowcs-.patch
- 0060-fix-erroneous-acceptance-of-f4-9x-xx-xx-code-sequenc.patch
- 0061-fix-OOB-reads-in-Xbyte_memmem.patch
- 0063-fix-undefined-behavior-in-memset-due-to-missing-sequ.patch
- 0064-handle-whitespace-before-in-scanf.patch
- 0065-make-syscall.h-consistent-with-linux.patch
- 0066-fix-signal-masking-race-in-pthread_create-with-prior.patch
- 0067-don-t-treat-numeric-port-strings-as-servent-records-.patch
- 0068-fix-glob-descent-into-.-and-.-with-GLOB_PERIOD.patch
- 0069-work-around-incorrect-EPERM-from-mmap-syscall.patch
- 0070-powerpc-64-fix-MAP_NORESERVE-and-MAP_LOCKED-in-mman..patch
- 0071-fix-use-of-memset-without-declaration-in-sched.h-cpu.patch
1000-implement-strftime-GNU-extension-padding-specifiers-.patch
2000-pthread-internals-increase-DEFAULT_GUARD_SIZE-to-2-p.patch
- 2001-thread-do-not-attempt-to-join-detached-threads-in-pt.patch
- 3001-s390x-add-bits-hwcap.h.patch
3002-stdio-implement-fopencookie-3.patch
- 0001-add-_NL_LOCALE_NAME-extension-to-nl_langinfo.patch
ldconfig
__stack_chk_fail_local.c
@@ -216,83 +143,10 @@ compat() {
done
}
-sha512sums="47c00e50b7605102fb4aebe1f9ba9db94d26fac64805f6d744c9c557a05b8a58dff7f9558ff7c8d66b5d7c43740cdc2dd79448bacac47f1414e6ada99c210140 musl-1.1.16.tar.gz
-74e95ab3a74513e7a0513e004c376d4055eca0e21162e717dfcab249302a9060d3ac3eb88b562dea14b71b475b4dd2f703e355e2f5050b58891a848c5093c5f6 0001-fix-strftime-y-for-negative-years.patch
-04805970e7dc11f84a86df49688f3b7670933860192e99637e189494c261e49b3cce1d80019d69341452062df03d5a349450015076c947296ac4a0d40e5789f4 0002-make-globfree-safe-after-failed-glob-from-over-lengt.patch
-61a4f48055aa88cb5f40dd1ea9cc032e372896d7be530f25f17edba3d01706c233bf58a79bddf8952fb6b5d1481f04fac6dd619f4609251874f5a2e1f668f4a0 0003-reduce-impact-of-REG_-namespace-pollution-in-x86-_64.patch
-ea103de2721926111510116dedb10e2320715fd20563a342c1dd30f3d1e68049990924b2cf4d03fd9d481ae9488f0e49da5373a79bcec4a8d8c357c64a24751b 0004-fix-getopt-_long-clobbering-of-optopt-on-success.patch
-df96c4bd5ff9c197c8aa599948b69716587837de0f298d3adec56077b073e71a49a3c3345e0508cf8a4ed636e3171495bbbdc35435bd8e343c546436f6348359 0005-treat-base-1-as-an-error-in-strtol-family-functions.patch
-4dc5cdcab11dee6b62fcb81401a816341e1d802a99e46b072c51575a2c25933354540fe22ae06dcdc85eb9a3cbf7256e7c43aab0e75843846551f9e18bfc39c2 0006-fix-crash-from-corrupted-tls-module-list-after-faile.patch
-2184c81e97b78ed7c9e0d41200560420c9e60a8ec297d2e2055c9bf0ee5fdaef475ea6a9bcd4b732d53b453379146a9efb28b7b8aef0726e326fb3da26ba0b8d 0007-fix-bindtextdomain-logic-error-deactivating-other-do.patch
-9c443c0902ed3d38ca2503ce7d4fd6d09d325caf07117833dd03ae999fa2e69ea2bd7b2751f1037eadaa9f13dfaae351841cfbf23301ca2682c98ff3af1a8294 0008-fix-use-of-uninitialized-pointer-in-gettext-core.patch
-fc3fce8a2dc10e1b48ef5d3c57cc1702503a849aa98166b2f25a56f6141340030c87e087b4eef5ccb5e2c3b750205c602c0dced3513031f39d19d1d5a0184506 0009-avoid-unbounded-strlen-in-gettext-functions.patch
-ba0a1e644f3b360e22716333f1125f04130f9fc0a2a0ee4c2cd51a454da5ccced043a510f41088b39ca565787d987331d5730cb87f35b21ad5bb3b85db939a72 0010-s390x-implement-dlsym.patch
-75348cf93be68039aebe37c670981bca04b816fd7ba5846adfe07623592645f6ff2541389a9083fe012cf3472d91eb9d8da47fb31574693557152a34b080e51a 0011-fix-build-regression-in-arm-atomics-asm-with-new-bin.patch
-d73358b5377db7b708dd8fecda8f6bdae007423e853cde86b33ce5078e31761eab3f2169541aca5be8f72a59286db4b866f443a6c2f6565e5852447778fbadac 0012-allow-page-size-to-vary-on-arm.patch
-e3fe35bf310c9d5813553e6762c66764b384a9c2f405e3ba3cea887ff55f6bcd947e55012c5f3e06e16a66d5f289b694ac898fc9b1d4bb0cfb50cf92135e36a3 0013-fix-lsearch-and-lfind-to-pass-key-as-first-arg-to-th.patch
-7a6cd67a5ca246eaedb992f9267bb94b0baccbbd5bb9a6a10a503f623ef052480fc4832da4330b5d3531f239580fdb9e36072f456fe4dd2e9ca6ae6050c55aab 0014-fix-ld-behavior-dependent-crash-in-ppc64-ldso-startu.patch
-48d4fd3510404b2fe934dffb2fc725c6a31e30e33421dc81073673d680d00866890f9c826bf48874845c863db52ebbb015c9e94b45c7a20b6949236f76f81709 0015-treat-STB_WEAK-and-STB_GNU_UNIQUE-like-STB_GLOBAL-in.patch
-41b8ba87082e586393b6c9570b7fc32455832a4a294ca1bb344f9eb72cd971be92cd03e590508cc1cd44fea532ab860690f38daaae665c68864302a20f11a01d 0016-rework-ldso-handling-of-global-symbol-table-for-cons.patch
-cad53ef772bc3ceae7695304df2a202d01a72cd4a707cffa9a7489947c9151ddd72bd2e2672e6508f56ec188973c886a0a99f85d4a4c54306284fe1b241c52db 0017-reorder-addend-handling-before-symbol-lookup-in-relo.patch
-e4935a23787e5eb5df4f1d487c10d63d4d2f34509ba5871c40037229f09057caad0679d12c444d7e7c5c719c2106e1b130921275d2ed3b1b8ffc6c97c9dde67a 0018-emulate-lazy-relocation-as-deferrable-relocation.patch
-0754297d5e2cc9d2244835badb39325b0907604e377ddbabbb865a12429741c71b461ee9f19ebdebc6bd9b6e878919b2bc292b113e1477591171627623dbf557 0019-fix-free-of-uninitialized-buffer-pointer-on-error-in.patch
-0fb792b688bea5024a59645eda680c57c509ad5f6923c8816647644ce5b438f18ef2036b4252ae2993c003e0e192d3a0cfd1f909d5a8c3cd8c21ef1130fca929 0020-in-static-dl_iterate_phdr-fix-use-of-possibly-uninit.patch
-5cb2e43b01d30b9552668508bc4e855c7e90b323c811bf34989eae97b8cfbdccbe50e13bf95cac727314c0077af823eb4666318e53cb2d4584052b2870c36a3b 0021-fix-possible-fd-leak-unrestored-cancellation-state-o.patch
-d8faf157e46f46cf1fbdd8422a1c918834192634f66e54d7cfa88d14a618a8a3c321269b98e2ad33e4059a58b3a23ffd16111011a51f4007c7258befed64bfb5 0022-fix-wide-scanf-s-use-of-a-compound-literal-past-its-.patch
-efabb66abd01dbf73d89933328beffb738d71b227f7d7dd48b02ca0c9b04b554475bde70a814317b7a016c64c60fbaf98bf78c1b50da504a3e23fd175950515a 0023-fix-one-byte-overflow-in-legacy-getpass-function.patch
-b1141d2b5c28d16848dcd8b40182938d634023a4aa0e7f0be567fa7e6c40c03431574e9214949e723a031f90a6c20153ca1a6c21eda3b8ea05de5cebf6b1fe38 0024-avoid-loading-of-multiple-libc-versions-via-explicit.patch
-955882a1a2a3e7211e20527858ca5dc0944b5d44fdacb547e0d4b4bd27fdf63672b95e16faa4b37e9ee4b384e7f33ce394ee556a201be6011630c84ebf64b312 0025-remove-unused-refcnt-field-for-shared-libraries.patch
-dad1ed979898ddaa0a49c601160a948ba229b251307210a14240e4ebf6230b16ffc0138f396fc226942c487e196211964449e7314f83d208ac219a071a4e11b3 0026-fix-threshold-constants-in-j0f-y0f-j1f-y1f.patch
-9b91076729245d4192c01b82700898e8baca0d3db11fdb5f257f88a40d3d59442c30d13434a81e4a067553e28477ceea9edd0960c49da9bba684147dd645a85d 0027-precalculate-gnu-hash-rather-than-doing-it-lazily-in.patch
-0472694cdd5a95b8df9b0e585afc7171ae9138133832ad7c0fadae4ea0a742eaa09a4d4449197ccaaefeae99c3cb7ec784068243a3a2d434429a0455c396e6bb 0028-s390x-fix-fpreg_t-and-remove-unused-per_struct.patch
-33c24b895bcf1b84d90a522328b39d5b0a4aff822d0701f2f9db07a6c44c49bb3a8b16a19150c550b4fe04fad40e9af43fdf5e1fda0201e9779a471088fe9f23 0029-fix-POSIX-format-TZ-dst-transition-times-for-souther.patch
-adcb5b213ebd9fc5d50cc46d4444ed64a4f928a6b4767428d7d720c6a563ba1d4a3173d6546b41379356b155a26eaad652d7b831776cc3f31e942f155db9239d 0030-fix-dlopen-dlsym-regression-opening-libs-already-loa.patch
-5601b5b56b0b2f4703ec4eb628f7eef78a130afc26979fb3d29c459cb168c62c13c3698a779ad7bbea8fb78d5f7cc02d465185a24bf9a06f6764a01fbd41dc04 0031-s390x-provide-a-working-sigcontext-struct-definition.patch
-690daa7f4c7ba0d24e103299406226849ad1314e2f3ea32cc571a6cdf0bac097b24fa3efa228b03ea495d9d437c9dd90eebe7b0268f94b7e19861100f84fa66e 0032-fix-support-for-dl_iterate_phdr-in-static-pie-binaries.patch
-324a933364e20f9ceb390bc6e8a1f5486fb44db5b83147a701be52be8f87b98155810ea2e8b13c433dfc8c326c0ef930f83f434fa61b7103cb055c34c34d1c3f 0033-fix-scalbn-when-result-is-in-the-subnormal-range.patch
-db79ea5c8f6ffa1d60a99320370814fda4c42a20b7e18fee73f27ad76d26ef0380b033c116d7beec7c5f7b061f04fd9f776048d8cebd7381f07bf6ecc3cbc62d 0034-fix-regression-in-support-for-resolv.conf-attempts-o.patch
-af9c68842ae13588a2fbbae0c32a39e34d21fb21fe360457f0964b89dfc845f7579c3b2e50c9a59e816d72388c50702eeb35b8acf70b36664be7abcb8c77b606 0035-make-ttyname-_r-return-ENODEV-rather-than-ENOENT.patch
-e20524ef4acea8c6c0be53dfa65c8d40054637cc5e475b80d81949fc24609714eaba302957a4d6d8c29e0c77153b7631969349f59716fd2eb1144136ae244b6b 0036-implement-new-posix_spawn-flag-POSIX_SPAWN_SETSID.patch
-4fee74a7e7a16fed6e5c3e4d2cee79e0720d8db616b7571318c2ebfa622339724543bc02221a50324521c67845db3f74cbe2c3800efdcab15ed54fbf8bcdeae6 0037-add-no-op-POSIX_SPAWN_USEVFORK-to-spawn.h.patch
-be15b749bec54ef342afa252d7fe46a644d2fcb77336719e57db613036d5f65531a03b17c9c5f92abcffebe45df4116b0adc477cc11533e656ee0fc82908cd76 0038-have-posix_spawnattr_setflags-check-for-supported-fl.patch
-0f0cea53dba8a9ecbd493ce94fe17a22f814f3a35dbbb0a40749b926f78f5cec29d39d2dd3e803a9006e7a2b52f93917d6b19230457932c2681e4c395d752715 0039-fix-iconv-conversions-to-legacy-8bit-encodings.patch
-9c71b7382cfe7a4480671b4e3bc18db79e68935ae271f0b6d43cd46d0ae87b059322592a0ca96f9e95779c57953708f1891e588e1b17d4b73f286a2d45ee1fd4 0040-fix-fchown-fallback-on-arches-without-chown-2.patch
-11bde485e070cdbca2f7c1a441152f608dad1273fb8a3c3206e02e81308806e9bb9ff5a50e50a00486d4d69c65d9eda6b9a1ad4897e828241b8c07acaaf869ea 0041-towupper-towlower-fast-path-for-ascii-chars.patch
-d0e11ff77cfbe1473ae90497180fa6c8972a8acdaafdb732ce42da5762cf0f4ed5fd9a60b0bb19009ca27b5d301257ef5ad6af0a6af487a2dfea57ea881321dd 0042-fix-glob-failure-to-match-plain-to-root-directory.patch
-8719e563b48458bcadfa7e8ffad1e6ad808d99af837437ea055d4a7d684742e0e2ff6b730fe4bf63efc81a0802952cfe53394578188b6bf9fc63c5bfa20db83e 0043-catopen-set-errno-to-EOPNOTSUPP.patch
-343d4177e8059461a1df93c6517fe6a4b3ad140653ff173458062714b512d58d45050e03087e375d986552ea825cbca1f77542fc934e35dc1c51d056268029f5 0044-getdate-correctly-specify-error-number.patch
-a8bc306ca7109f3e2a81fde2ef0d9468428551eb47a4b083c17c7659dac1bca126a8330ce3cc580db79e2eb89bbc299c16878ecf17988cdc9f72ff489d2f415d 0045-handle-mremap-failure-in-realloc-of-mmap-serviced-al.patch
-c6c97ccc7b5a88a6e32ab8bb0cd35ae4689c144fd8b0f40e880061d374e5a71365066f89263d181affcd83613e2d92602a6adbf3ab2893c4dc88f667320a1f26 0046-handle-localtime-errors-in-ctime.patch
-b3e00f1d83314736d2c7b4bee59bc1055fdbc2bb4ce75b62a293c99abeb372afc1c5e73c4d878bf1d865964daf93e2e413890c60e0be6c72982c257d067c4b73 0047-set-errno-when-getpw-_r-getgr-_r-and-getspnam_r-fail.patch
-fc2c08156e755a9e178ede1642673b1f1ba06be467ff607fc3f9ea9052ddb2fa8d0ff425fd764aa7f4fc9bbd6ae0db86ad95c128e4f0da0a901980b449efa659 0048-handle-errors-from-localtime_r-in-ctime_r.patch
-053f5a09494dc117ae83ff801241fa71f1401303c53587bb01c2e7367a8149912c74dbe52373fc19f82eef9df41091e33faab5728598f99d7c9bb655701e331c 0049-fix-iconv-conversions-for-iso88592-iso885916.patch
-0fb668eb4df132bd779d534b86ff3858914261352af2fa4e2b04c83eca88bed5cd440648ce6b245196cbe2446a427618615756c61281d998a4a04713c09d7806 0050-fix-regression-in-getspnam-_r-error-code-for-insuffi.patch
-a53c952ab63e5aae56a152de489cf3eb65ab0a1abf466960d7b9d091e665c6f7e705859e61fc16c6c05b2720d75bc6e094c8407e56e98fbf25c8e1cf11369870 0051-fix-arm-run-time-abi-string-functions.patch
-a2af359d64cff4eb37b35a1d4f4c20f4e80132b3f3c844335ab7f971cfb2f2e160dd8c16a9098cfc5cf69cf5b224f9ae1688a84f7e3870ba6956f5062e595b14 0052-ldso-avoid-spurious-possible-erroneous-work-for-libs.patch
-a42d23a218683eaf5b2bf8d7badbc8e0d146b4a4ac06c9f71cd516071b22e3b0055239912ed02bc1207aa4205a3c25c170164aa1cc1f8ac2ba0b821324a42745 0053-fix-regression-in-dlopen-promotion-from-RTLD_LOCAL-t.patch
-8ac7bd79a341a1a436c2c1ccffdad376f489105503fe02cce14834cd389e1a6669cb299532b05b47b7ce3cd515eb808c8fc98a6b2894b522a7c6d82eaa93511c 0054-allow-specifying-argv-0-when-invoking-a-program-via-.patch
-ea68e0c88430b65b5a61e4cbc6e6f477b383d34de89f21d59da50a05912f11a07b55de48b75cf4de1b278b8b25afacbc105ab4748525f2c91b6219364f453f09 0055-reapply-va_arg-hacks-removal-to-wprintf.patch
-dde4bb6c877d4fdf976e3ffea5d0a4a48f365708c488ceeaa4dcc29296820517aebbfa3b0527d74ddb64bf6cdbac04624ba9043b884ac4cd770a848f4d0e1f88 0056-fix-undefined-behavior-in-free.patch
-6e0a65d4023b4d2b0a971f1dbb5017fe7aedf7c663c0f9971841a4739758826c323cd0856a1591cfd874df35e8b96f1248eda029a9cd56987c36178a32b1f0ee 0057-fix-missing-volatile-qualifier-on-lock-in-__get_loca.patch
-3fd640b606279eec9ee7551ca39903d3a9a91f30e5a78dbcc0e0a59fd7edec25dcafd24f50dc0f1065209b402c3f12720ed0180b49ff641dbd54bd83989f1dc9 0058-ppc64-fix-setjmp-longjmp-handling-of-TOC-pointer.patch
-4c3456e2539ac68ffc775bba5dca259f1ed2bc64a1b6824041223be118dc45968a85f07328f98b281e5d8254c363eaecafc745ccf3ac45b715f32071575916bd 0059-fix-erroneous-stop-before-input-limit-in-mbsnrtowcs-.patch
-4e42b8e7107ecad7abc1a580516b13c424c4b1cb21585539194486fe12e5b00ffad7986791aacf9b752580b5043d60acbe27092dd814dd4eaabdcff1a5c96266 0060-fix-erroneous-acceptance-of-f4-9x-xx-xx-code-sequenc.patch
-7e2cded73db0de17dd677352ac9770b4aab91f92ac1cdb50480e3a1cda1675e9028a19765b46e11e5fa860106e0c0a504073769a26112d467aa68b190f2d3806 0061-fix-OOB-reads-in-Xbyte_memmem.patch
-3a7f24c28e2eb5441753a6f245228607ff548de0d5aeaf4ce9107b982a5d2e827ae1ce0c60c465eb1d8ef95e0fda94cb31e0d01406217e5432b809bf6f5cc86f 0063-fix-undefined-behavior-in-memset-due-to-missing-sequ.patch
-2584506923d9e90bde6e58fa0a4030cd4c6ed6f1ef111c94c6a31a6a2ebd7514840484e2104a1584dacba9d17739de54a6281d92aad6a2c3ad93ab23495f374e 0064-handle-whitespace-before-in-scanf.patch
-745771bb87549f5ed52332214f0750ca741edd0aef84853e51c7e6e361ebe6bc354c0da6bfad74427fcc95b445ca7d887c771132465bc3515b362b4fdc66595a 0065-make-syscall.h-consistent-with-linux.patch
-07acf30dc8c2f221074d19798516ab7b79efeed307c6d26da7713e308133ec315c6f92d61fb25fe590c9be7810e461758902784370b3f725f8392d5d1750c762 0066-fix-signal-masking-race-in-pthread_create-with-prior.patch
-c50fab58e47c62252aa0e79a5c839e9b58a30b1f5d612a79cccc6d86a3fec25acf96be544141efdb20de24d25f870a7bb45527322b111678a9829e77428e7253 0067-don-t-treat-numeric-port-strings-as-servent-records-.patch
-e3de301bd48b7778e5370dee2945be6c78f6e50f9e5f18626c24635ec69115dacf4774a3da20afbeee01e95f0b4294d9d7761c3302949801efa8b7e34116d1f2 0068-fix-glob-descent-into-.-and-.-with-GLOB_PERIOD.patch
-46bed09ccded1680229dcf1dd851aca09363100481902bd85bc8f32dfc473968cbb06fa55d8221b2564684684c98fbe1a3ada503d3429c3cae9a1953a0f8c85d 0069-work-around-incorrect-EPERM-from-mmap-syscall.patch
-efb4b07f0c42c8ba2ca25bb9e76b312be1288e6d84c13a24e281dc343bd0bd3f24ee2b8b632500d1214473dfab81efdcb03de09014bc305ba09305402f2bc795 0070-powerpc-64-fix-MAP_NORESERVE-and-MAP_LOCKED-in-mman..patch
-4eee35c8030ab6b4b29e89cf250fe9853bc886edc3593320969a834a21e0a1ca225e3435c203c2d7de207c855063aabf635e464c94267110abb6509f289301ea 0071-fix-use-of-memset-without-declaration-in-sched.h-cpu.patch
+sha512sums="bc99c7d58d64116c03e68fe77141a1f2938e0c01ba027937587a060d435b4b00b8b1f18c63fb8ed445ef36f377974e02a7b4821c793e4292041e31e66f145428 musl-1.1.17.tar.gz
7e4c703e57a3564cd3ee1d5334b806cbe654355179ba55d4d25361dfc555eb4a7d081d80d64fdaff8476949afd04558d278b124d1fb108080beaa5ba2f8ce2b9 1000-implement-strftime-GNU-extension-padding-specifiers-.patch
2c8e1dde1834238097b2ee8a7bfb53471a0d9cff4a5e38b55f048b567deff1cdd47c170d0578a67b1a039f95a6c5fbb8cff369c75b6a3e4d7ed171e8e86ebb8c 2000-pthread-internals-increase-DEFAULT_GUARD_SIZE-to-2-p.patch
-76330dfff60b2a8703ddc38f378995334ab0fa56e31e499937a4b4dfd8ff4a0bf1f8108174e8f863810de5cc28ff4c50656b886ee468605072bc55310a077624 2001-thread-do-not-attempt-to-join-detached-threads-in-pt.patch
-9c87849e6a58f393aaf4fa7dca31a010a369d41b2f24cdde6af0303df0436e2ef2ca5b767b5584b93f5c9c98e200ac2a972688b8ce2838a5ff9b746982085bcb 3001-s390x-add-bits-hwcap.h.patch
0053e16cbac968b50dee98e3b36d29a497aaca6d9d0e120556273c9d0cd8360310eb7b7ab3c1e416217210fdd071e98268eaca54f3a0e9a22408ed8701dc54c1 3002-stdio-implement-fopencookie-3.patch
-d725bb4990c5b2cdb88f6ecbe1f63895b29717c0ae3af60181588dd41cb10cd201f2faaade26f1abd31b568964a327131dad6f928717d953f44d7ef625ea8955 0001-add-_NL_LOCALE_NAME-extension-to-nl_langinfo.patch
8d3a2d5315fc56fee7da9abb8b89bb38c6046c33d154c10d168fb35bfde6b0cf9f13042a3bceee34daf091bc409d699223735dcf19f382eeee1f6be34154f26f ldconfig
062bb49fa54839010acd4af113e20f7263dde1c8a2ca359b5fb2661ef9ed9d84a0f7c3bc10c25dcfa10bb3c5a4874588dff636ac43d5dbb3d748d75400756d0b __stack_chk_fail_local.c
0d80f37b34a35e3d14b012257c50862dfeb9d2c81139ea2dfa101d981d093b009b9fa450ba27a708ac59377a48626971dfc58e20a3799084a65777a0c32cbc7d getconf.c