diff options
author | Timo Teräs <timo.teras@iki.fi> | 2016-08-02 11:36:46 +0000 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2016-08-02 11:37:38 +0000 |
commit | 49ae9655c09035515fc753ae302813f7535d7ab9 (patch) | |
tree | babf7c7786e3b4bbeede75d4c38a363e373669ba | |
parent | d33108e2c7d12ebb074dc406677d602020f48b5d (diff) | |
download | aports-49ae9655c09035515fc753ae302813f7535d7ab9.tar.bz2 aports-49ae9655c09035515fc753ae302813f7535d7ab9.tar.xz |
main/musl: cherry-pick upstream fix for asctime
-rw-r--r-- | main/musl/0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch | 40 | ||||
-rw-r--r-- | main/musl/APKBUILD | 6 |
2 files changed, 45 insertions, 1 deletions
diff --git a/main/musl/0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch b/main/musl/0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch new file mode 100644 index 0000000000..0bd1ddb077 --- /dev/null +++ b/main/musl/0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch @@ -0,0 +1,40 @@ +From 6399fa9d29ea83de4735680b77d457bd59606532 Mon Sep 17 00:00:00 2001 +From: Rich Felker <dalias@aerifal.cx> +Date: Thu, 7 Jul 2016 16:51:37 -0400 +Subject: [PATCH] fix asctime day/month names not to vary by locale + +the FIXME comment here was overlooked at the time locale support was +added. +--- + src/time/__asctime.c | 9 ++++----- + 1 file changed, 4 insertions(+), 5 deletions(-) + +diff --git a/src/time/__asctime.c b/src/time/__asctime.c +index e7e7f07..f114dfe 100644 +--- a/src/time/__asctime.c ++++ b/src/time/__asctime.c +@@ -1,17 +1,16 @@ + #include <time.h> + #include <stdio.h> + #include <langinfo.h> ++#include "locale_impl.h" + #include "atomic.h" + +-const char *__nl_langinfo(nl_item); ++const char *__nl_langinfo_l(nl_item, locale_t); + + char *__asctime(const struct tm *restrict tm, char *restrict buf) + { +- /* FIXME: change __nl_langinfo to __nl_langinfo_l with explicit C +- * locale once we have locales */ + if (snprintf(buf, 26, "%.3s %.3s%3d %.2d:%.2d:%.2d %d\n", +- __nl_langinfo(ABDAY_1+tm->tm_wday), +- __nl_langinfo(ABMON_1+tm->tm_mon), ++ __nl_langinfo_l(ABDAY_1+tm->tm_wday, C_LOCALE), ++ __nl_langinfo_l(ABMON_1+tm->tm_mon, C_LOCALE), + tm->tm_mday, tm->tm_hour, + tm->tm_min, tm->tm_sec, + 1900 + tm->tm_year) >= 26) +-- +2.9.1 + diff --git a/main/musl/APKBUILD b/main/musl/APKBUILD index cab3874a96..7b0a77eca1 100644 --- a/main/musl/APKBUILD +++ b/main/musl/APKBUILD @@ -2,7 +2,7 @@ # Maintainer: Timo Teräs <timo.teras@iki.fi> pkgname=musl pkgver=1.1.15 -pkgrel=0 +pkgrel=1 pkgdesc="the musl c library (libc) implementation" url="http://www.musl-libc.org/" arch="all" @@ -13,6 +13,7 @@ makedepends="$depends_dev" subpackages="$pkgname-dev $pkgname-dbg libc6-compat:compat" [ "$BOOTSTRAP" != "nolibc" ] && subpackages="$subpackages $pkgname-utils" source="http://www.musl-libc.org/releases/musl-$pkgver.tar.gz + 0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch ldconfig __stack_chk_fail_local.c @@ -119,18 +120,21 @@ compat() { } md5sums="9590a9d47ee64f220b3c12f7afb864ca musl-1.1.15.tar.gz +c08825383e41e5dbcd3ffdfd2062dd47 0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch 830d01f7821b978df770b06db3790921 ldconfig 0df687757221bbb0fc1aa67f1bd646f9 __stack_chk_fail_local.c 57ef2c63b9ec6a2041694ace97d4ffa2 getconf.c 2b941c4251cac44988a4abfc50e21267 getent.c 45f92f8d59cf84d765de698a9578dbf4 iconv.c" sha256sums="97e447c7ee2a7f613186ec54a93054fe15469fe34d7d323080f7ef38f5ecb0fa musl-1.1.15.tar.gz +d157100aeed5b0866eb6d50288f63f26ea9900f1d4c7b8a1492294c912b5cc19 0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch b4a2c06db38742e8c42c3c9838b285a7d8cdac6c091ff3df5ff9a15f1e41b9c7 ldconfig 299a7d75a09de3e2e11e7fb4acc3182e4a14e868093d2f30938fce9bfcff13da __stack_chk_fail_local.c d87d0cbb3690ae2c5d8cc218349fd8278b93855dd625deaf7ae50e320aad247c getconf.c 68373a55e89ce85c562d941ccf588337d6cc6c9c17689d695f65cd7607134bbe getent.c f79a2930a2e5bb0624321589edf8b889d1e9b603e01e6b7ae214616605b3fdd7 iconv.c" sha512sums="9e923572c0d6bad3dc2d2646d4b0699c10b477ce6300ac6c6224895192a90667f581ddf6eda2ab8c4c16f47bde4bccb03bb90478638d136d9df721430f4d0163 musl-1.1.15.tar.gz +1a74d5f5e0f6f2fe6029ed0f18b4603f80c990f19aa13d83c5d1f40f032b2ffb3819aae13ae1f96415bb08571774eec164e71d09028f2a5db4ae9b77e48cafe7 0001-fix-asctime-day-month-names-not-to-vary-by-locale.patch 8d3a2d5315fc56fee7da9abb8b89bb38c6046c33d154c10d168fb35bfde6b0cf9f13042a3bceee34daf091bc409d699223735dcf19f382eeee1f6be34154f26f ldconfig 062bb49fa54839010acd4af113e20f7263dde1c8a2ca359b5fb2661ef9ed9d84a0f7c3bc10c25dcfa10bb3c5a4874588dff636ac43d5dbb3d748d75400756d0b __stack_chk_fail_local.c 0d80f37b34a35e3d14b012257c50862dfeb9d2c81139ea2dfa101d981d093b009b9fa450ba27a708ac59377a48626971dfc58e20a3799084a65777a0c32cbc7d getconf.c |