From 029683d9d1b18f336faef64afce711cfc4f3f4d0 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Wed, 17 Apr 2019 23:44:31 +0200 Subject: [PATCH] zstd: Update from 1.3.8 to 1.4.0 --- packages/zstd/build.sh | 4 ++-- packages/zstd/no-timespec_get.patch | 26 ++++++++++++++++++++++++++ 2 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 packages/zstd/no-timespec_get.patch diff --git a/packages/zstd/build.sh b/packages/zstd/build.sh index 90ee11966..1b724ab91 100644 --- a/packages/zstd/build.sh +++ b/packages/zstd/build.sh @@ -1,9 +1,9 @@ TERMUX_PKG_HOMEPAGE=https://github.com/facebook/zstd TERMUX_PKG_DESCRIPTION="Zstandard compression." TERMUX_PKG_LICENSE="GPL-2.0" -TERMUX_PKG_VERSION=1.3.8 +TERMUX_PKG_VERSION=1.4.0 TERMUX_PKG_REVISION=1 -TERMUX_PKG_SHA256=90d902a1282cc4e197a8023b6d6e8d331c1fd1dfe60f7f8e4ee9da40da886dc3 +TERMUX_PKG_SHA256=63be339137d2b683c6d19a9e34f4fb684790e864fee13c7dd40e197a64c705c1 TERMUX_PKG_SRCURL=https://github.com/facebook/zstd/archive/v$TERMUX_PKG_VERSION.tar.gz TERMUX_PKG_BUILD_IN_SRC=yes TERMUX_PKG_DEPENDS="liblzma, zlib" diff --git a/packages/zstd/no-timespec_get.patch b/packages/zstd/no-timespec_get.patch new file mode 100644 index 000000000..45ae42b9b --- /dev/null +++ b/packages/zstd/no-timespec_get.patch @@ -0,0 +1,26 @@ +diff -u -r ../zstd-1.4.0/programs/timefn.c ./programs/timefn.c +--- ../zstd-1.4.0/programs/timefn.c 2019-04-16 22:37:24.000000000 +0000 ++++ ./programs/timefn.c 2019-04-17 20:47:49.592167589 +0000 +@@ -84,7 +84,8 @@ + + + #elif (defined (__STDC_VERSION__) && (__STDC_VERSION__ >= 201112L) /* C11 */) \ +- && defined(TIME_UTC) /* C11 requires timespec_get, but FreeBSD 11 lacks it, while still claiming C11 compliance */ ++ && defined(TIME_UTC) /* C11 requires timespec_get, but FreeBSD 11 lacks it, while still claiming C11 compliance */ \ ++ && !defined(__ANDROID__) + + #include /* abort */ + #include /* perror */ +diff -u -r ../zstd-1.4.0/programs/timefn.h ./programs/timefn.h +--- ../zstd-1.4.0/programs/timefn.h 2019-04-16 22:37:24.000000000 +0000 ++++ ./programs/timefn.h 2019-04-17 20:47:28.716414556 +0000 +@@ -58,7 +58,8 @@ + #define UTIL_TIME_INITIALIZER 0 + + #elif (defined (__STDC_VERSION__) && (__STDC_VERSION__ >= 201112L) /* C11 */) \ +- && defined(TIME_UTC) /* C11 requires timespec_get, but FreeBSD 11 lacks it, while still claiming C11 compliance */ ++ && defined(TIME_UTC) /* C11 requires timespec_get, but FreeBSD 11 lacks it, while still claiming C11 compliance */ \ ++ && !defined(__ANDROID__) + + typedef struct timespec UTIL_time_t; + #define UTIL_TIME_INITIALIZER { 0, 0 }