summaryrefslogtreecommitdiff
path: root/archivers
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2016-10-04 14:37:03 +0000
committerwiz <wiz@pkgsrc.org>2016-10-04 14:37:03 +0000
commitf00e0636f65c5ba19363513bcbf8ae2fae642140 (patch)
tree45d6bc0e3dda4831b4bb92c4703eab8f6322e94f /archivers
parentbe57d68b56bbcf7838d3b1db21f8d9ec9737c3f0 (diff)
downloadpkgsrc-f00e0636f65c5ba19363513bcbf8ae2fae642140.tar.gz
Updated zstd to 1.1.0.
v1.1.0 New : contrib/pzstd, parallel version of zstd, by Nick Terrell added : NetBSD install target (#338) Improved : speed for batches of small files Improved : speed of zlib wrapper, by Przemyslaw Skibinski Changed : libzstd on Windows supports legacy formats, by Christophe Chevalier Fixed : CLI -d output to stdout by default when input is stdin (#322) Fixed : CLI correctly detects console on Mac OS-X Fixed : CLI supports recursive mode `-r` on Mac OS-X Fixed : Legacy decoders use unified error codes, reported by benrg (#341), fixed by Przemyslaw Skibinski Fixed : compatibility with OpenBSD, reported by Juan Francisco Cantero Hurtado (#319) Fixed : compatibility with Hurd, by Przemyslaw Skibinski (#365) Fixed : zstd-pgo, reported by octoploid (#329)
Diffstat (limited to 'archivers')
-rw-r--r--archivers/zstd/Makefile4
-rw-r--r--archivers/zstd/distinfo15
-rw-r--r--archivers/zstd/patches/patch-Makefile16
-rw-r--r--archivers/zstd/patches/patch-lib_Makefile16
-rw-r--r--archivers/zstd/patches/patch-programs_Makefile16
-rw-r--r--archivers/zstd/patches/patch-tests_zbufftest.c121
-rw-r--r--archivers/zstd/patches/patch-tests_zstreamtest.c129
7 files changed, 7 insertions, 310 deletions
diff --git a/archivers/zstd/Makefile b/archivers/zstd/Makefile
index a5b61ae50b2..d5e8934a183 100644
--- a/archivers/zstd/Makefile
+++ b/archivers/zstd/Makefile
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.1 2016/09/04 12:36:59 wiz Exp $
+# $NetBSD: Makefile,v 1.2 2016/10/04 14:37:03 wiz Exp $
-DISTNAME= zstd-1.0.0
+DISTNAME= zstd-1.1.0
CATEGORIES= archivers
MASTER_SITES= ${MASTER_SITE_GITHUB:=facebook/}
GITHUB_TAG= v${PKGVERSION_NOREV}
diff --git a/archivers/zstd/distinfo b/archivers/zstd/distinfo
index 6097cd4e10f..8786ce8546f 100644
--- a/archivers/zstd/distinfo
+++ b/archivers/zstd/distinfo
@@ -1,11 +1,6 @@
-$NetBSD: distinfo,v 1.2 2016/09/04 12:40:24 wiz Exp $
+$NetBSD: distinfo,v 1.3 2016/10/04 14:37:03 wiz Exp $
-SHA1 (zstd-1.0.0.tar.gz) = 4865e52b308fccbf8cabf704f63cadbeccb1b6d9
-RMD160 (zstd-1.0.0.tar.gz) = 37abd266b75dc62eea83e75f6868bfd7dc53a648
-SHA512 (zstd-1.0.0.tar.gz) = ba7b1c993656fa220dd8d4c8cd6b7999b0d7b59b4290d7767063f6c4bfbb81e04b9d9890dea4d223d48082ab253159209d6187dc7b42cafc28ebc738bfa17ace
-Size (zstd-1.0.0.tar.gz) = 593430 bytes
-SHA1 (patch-Makefile) = 97523cca23ded18c52c0d9ee8b21ab956beb38bb
-SHA1 (patch-lib_Makefile) = afca61a2f8aac8da9fe06f7d5b20e50197922b53
-SHA1 (patch-programs_Makefile) = 010a0840b3b49968e2f100ad2201ebdd8d922f02
-SHA1 (patch-tests_zbufftest.c) = 68a796958aea6256ecd5ac18fc4c96d753ebbec2
-SHA1 (patch-tests_zstreamtest.c) = 31c0d6c661cc21119871d1ad3650d9842cbd59c1
+SHA1 (zstd-1.1.0.tar.gz) = 6c24a604cf71a961d4172cbced6b10470d1b416e
+RMD160 (zstd-1.1.0.tar.gz) = 05787448173f6fe61e5b5a3e957e05fd1bd7f912
+SHA512 (zstd-1.1.0.tar.gz) = 9fe72081d333b58d5c8f27f13bd01ab0d729984215b75690282770aa769aab6879b88177aa2b45d8ce2869bf1b360f3a828ca00aa3646a7cc57285a4e167d71f
+Size (zstd-1.1.0.tar.gz) = 716327 bytes
diff --git a/archivers/zstd/patches/patch-Makefile b/archivers/zstd/patches/patch-Makefile
deleted file mode 100644
index 20f11ba0890..00000000000
--- a/archivers/zstd/patches/patch-Makefile
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-Makefile,v 1.2 2016/09/04 12:40:24 wiz Exp $
-
-Enable install target for NetBSD.
-https://github.com/facebook/zstd/pull/338
-
---- Makefile.orig 2016-09-04 12:01:55.355932317 +0000
-+++ Makefile
-@@ -51,7 +51,7 @@ clean:
- #----------------------------------------------------------------------------------
- #make install is validated only for Linux, OSX, kFreeBSD, Hurd and some BSD targets
- #----------------------------------------------------------------------------------
--ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD DragonFly))
-+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD DragonFly NetBSD))
- HOST_OS = POSIX
- install:
- $(MAKE) -C $(ZSTDDIR) $@
diff --git a/archivers/zstd/patches/patch-lib_Makefile b/archivers/zstd/patches/patch-lib_Makefile
deleted file mode 100644
index 2387da77a0b..00000000000
--- a/archivers/zstd/patches/patch-lib_Makefile
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-lib_Makefile,v 1.2 2016/09/04 12:40:24 wiz Exp $
-
-Enable install target for NetBSD.
-https://github.com/facebook/zstd/pull/338
-
---- lib/Makefile.orig 2016-08-31 16:09:10.000000000 +0000
-+++ lib/Makefile
-@@ -78,7 +78,7 @@ clean:
-
- #------------------------------------------------------------------------
- #make install is validated only for Linux, OSX, kFreeBSD, Hurd and some BSD targets
--ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD DragonFly))
-+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU FreeBSD DragonFly NetBSD))
-
- libzstd.pc:
- libzstd.pc: libzstd.pc.in
diff --git a/archivers/zstd/patches/patch-programs_Makefile b/archivers/zstd/patches/patch-programs_Makefile
deleted file mode 100644
index 66497154ee0..00000000000
--- a/archivers/zstd/patches/patch-programs_Makefile
+++ /dev/null
@@ -1,16 +0,0 @@
-$NetBSD: patch-programs_Makefile,v 1.2 2016/09/04 12:40:24 wiz Exp $
-
-Enable install target for NetBSD.
-https://github.com/facebook/zstd/pull/338
-
---- programs/Makefile.orig 2016-08-31 16:09:10.000000000 +0000
-+++ programs/Makefile
-@@ -125,7 +125,7 @@ clean:
- #----------------------------------------------------------------------------------
- #make install is validated only for Linux, OSX, kFreeBSD, Hurd and some BSD targets
- #----------------------------------------------------------------------------------
--ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD DragonFly))
-+ifneq (,$(filter $(shell uname),Linux Darwin GNU/kFreeBSD GNU OpenBSD FreeBSD DragonFly NetBSD))
- install: zstd
- @echo Installing binaries
- @install -d -m 755 $(DESTDIR)$(BINDIR)/ $(DESTDIR)$(MANDIR)/
diff --git a/archivers/zstd/patches/patch-tests_zbufftest.c b/archivers/zstd/patches/patch-tests_zbufftest.c
deleted file mode 100644
index 6675e084000..00000000000
--- a/archivers/zstd/patches/patch-tests_zbufftest.c
+++ /dev/null
@@ -1,121 +0,0 @@
-$NetBSD: patch-tests_zbufftest.c,v 1.1 2016/09/04 12:36:59 wiz Exp $
-
-https://github.com/facebook/zstd/commit/5153a084f3065229bdcc689dd0cb2d90396b51c2
-
---- tests/zbufftest.c.orig 2016-08-31 16:09:10.000000000 +0000
-+++ tests/zbufftest.c
-@@ -23,7 +23,7 @@
- **************************************/
- #include <stdlib.h> /* free */
- #include <stdio.h> /* fgets, sscanf */
--#include <sys/timeb.h> /* timeb */
-+#include <time.h> /* clock_t, clock() */
- #include <string.h> /* strcmp */
- #include "mem.h"
- #define ZSTD_STATIC_LINKING_ONLY /* ZSTD_maxCLevel */
-@@ -58,13 +58,13 @@ static const U32 prime2 = 2246822519U;
- static U32 g_displayLevel = 2;
-
- #define DISPLAYUPDATE(l, ...) if (g_displayLevel>=l) { \
-- if ((FUZ_GetMilliSpan(g_displayTime) > g_refreshRate) || (g_displayLevel>=4)) \
-- { g_displayTime = FUZ_GetMilliStart(); DISPLAY(__VA_ARGS__); \
-+ if ((FUZ_GetClockSpan(g_displayClock) > g_refreshRate) || (g_displayLevel>=4)) \
-+ { g_displayClock = clock(); DISPLAY(__VA_ARGS__); \
- if (g_displayLevel>=4) fflush(stdout); } }
--static const U32 g_refreshRate = 150;
--static U32 g_displayTime = 0;
-+static const clock_t g_refreshRate = CLOCKS_PER_SEC * 15 / 100;
-+static clock_t g_displayClock = 0;
-
--static U32 g_testTime = 0;
-+static clock_t g_clockTime = 0;
-
-
- /*-*******************************************************
-@@ -72,23 +72,9 @@ static U32 g_testTime = 0;
- *********************************************************/
- #define MAX(a,b) ((a)>(b)?(a):(b))
-
--static U32 FUZ_GetMilliStart(void)
-+static clock_t FUZ_GetClockSpan(clock_t clockStart)
- {
-- struct timeb tb;
-- U32 nCount;
-- ftime( &tb );
-- nCount = (U32) (((tb.time & 0xFFFFF) * 1000) + tb.millitm);
-- return nCount;
--}
--
--
--static U32 FUZ_GetMilliSpan(U32 nTimeStart)
--{
-- U32 const nCurrent = FUZ_GetMilliStart();
-- U32 nSpan = nCurrent - nTimeStart;
-- if (nTimeStart > nCurrent)
-- nSpan += 0x100000 * 1000;
-- return nSpan;
-+ return clock() - clockStart; /* works even when overflow. Max span ~ 30 mn */
- }
-
- /*! FUZ_rand() :
-@@ -291,7 +277,7 @@ static int fuzzerTests(U32 seed, U32 nbT
- U32 coreSeed = seed;
- ZBUFF_CCtx* zc;
- ZBUFF_DCtx* zd;
-- U32 startTime = FUZ_GetMilliStart();
-+ clock_t startClock = clock();
-
- /* allocations */
- zc = ZBUFF_createCCtx();
-@@ -321,7 +307,7 @@ static int fuzzerTests(U32 seed, U32 nbT
- FUZ_rand(&coreSeed);
-
- /* test loop */
-- for ( ; (testNb <= nbTests) || (FUZ_GetMilliSpan(startTime) < g_testTime) ; testNb++ ) {
-+ for ( ; (testNb <= nbTests) || (FUZ_GetClockSpan(startClock) < g_clockTime) ; testNb++ ) {
- U32 lseed;
- const BYTE* srcBuffer;
- const BYTE* dict;
-@@ -543,7 +529,7 @@ int main(int argc, const char** argv)
-
- case 'i':
- argument++;
-- nbTests=0; g_testTime=0;
-+ nbTests=0; g_clockTime=0;
- while ((*argument>='0') && (*argument<='9')) {
- nbTests *= 10;
- nbTests += *argument - '0';
-@@ -553,15 +539,15 @@ int main(int argc, const char** argv)
-
- case 'T':
- argument++;
-- nbTests=0; g_testTime=0;
-+ nbTests=0; g_clockTime=0;
- while ((*argument>='0') && (*argument<='9')) {
-- g_testTime *= 10;
-- g_testTime += *argument - '0';
-+ g_clockTime *= 10;
-+ g_clockTime += *argument - '0';
- argument++;
- }
-- if (*argument=='m') g_testTime *=60, argument++;
-+ if (*argument=='m') g_clockTime *=60, argument++;
- if (*argument=='n') argument++;
-- g_testTime *= 1000;
-+ g_clockTime *= CLOCKS_PER_SEC;
- break;
-
- case 's':
-@@ -605,7 +591,11 @@ int main(int argc, const char** argv)
- /* Get Seed */
- DISPLAY("Starting zstd_buffered tester (%i-bits, %s)\n", (int)(sizeof(size_t)*8), ZSTD_VERSION_STRING);
-
-- if (!seedset) seed = FUZ_GetMilliStart() % 10000;
-+ if (!seedset) {
-+ time_t const t = time(NULL);
-+ U32 const h = XXH32(&t, sizeof(t), 1);
-+ seed = h % 10000;
-+ }
- DISPLAY("Seed = %u\n", seed);
- if (proba!=FUZ_COMPRESSIBILITY_DEFAULT) DISPLAY("Compressibility : %i%%\n", proba);
-
diff --git a/archivers/zstd/patches/patch-tests_zstreamtest.c b/archivers/zstd/patches/patch-tests_zstreamtest.c
deleted file mode 100644
index c04c9bf552f..00000000000
--- a/archivers/zstd/patches/patch-tests_zstreamtest.c
+++ /dev/null
@@ -1,129 +0,0 @@
-$NetBSD: patch-tests_zstreamtest.c,v 1.1 2016/09/04 12:36:59 wiz Exp $
-
-https://github.com/facebook/zstd/commit/ef9999f0b9762003f96a3e5bddb7e60dace458bc
-
---- tests/zstreamtest.c.orig 2016-08-31 16:09:10.000000000 +0000
-+++ tests/zstreamtest.c
-@@ -23,13 +23,13 @@
- **************************************/
- #include <stdlib.h> /* free */
- #include <stdio.h> /* fgets, sscanf */
--#include <sys/timeb.h> /* timeb */
-+#include <time.h> /* clock_t, clock() */
- #include <string.h> /* strcmp */
- #include "mem.h"
--#define ZSTD_STATIC_LINKING_ONLY /* ZSTD_maxCLevel */
-+#define ZSTD_STATIC_LINKING_ONLY /* ZSTD_maxCLevel, ZSTD_customMem */
- #include "zstd.h" /* ZSTD_compressBound */
- #include "datagen.h" /* RDG_genBuffer */
--#define XXH_STATIC_LINKING_ONLY
-+#define XXH_STATIC_LINKING_ONLY /* XXH64_state_t */
- #include "xxhash.h" /* XXH64_* */
-
-
-@@ -55,13 +55,13 @@ static const U32 prime2 = 2246822519U;
- static U32 g_displayLevel = 2;
-
- #define DISPLAYUPDATE(l, ...) if (g_displayLevel>=l) { \
-- if ((FUZ_GetMilliSpan(g_displayTime) > g_refreshRate) || (g_displayLevel>=4)) \
-- { g_displayTime = FUZ_GetMilliStart(); DISPLAY(__VA_ARGS__); \
-+ if ((FUZ_GetClockSpan(g_displayClock) > g_refreshRate) || (g_displayLevel>=4)) \
-+ { g_displayClock = clock(); DISPLAY(__VA_ARGS__); \
- if (g_displayLevel>=4) fflush(stdout); } }
--static const U32 g_refreshRate = 150;
--static U32 g_displayTime = 0;
-+static const clock_t g_refreshRate = CLOCKS_PER_SEC * 15 / 100;
-+static clock_t g_displayClock = 0;
-
--static U32 g_testTime = 0;
-+static clock_t g_clockTime = 0;
-
-
- /*-*******************************************************
-@@ -69,22 +69,9 @@ static U32 g_testTime = 0;
- *********************************************************/
- #define MAX(a,b) ((a)>(b)?(a):(b))
-
--static U32 FUZ_GetMilliStart(void)
-+static clock_t FUZ_GetClockSpan(clock_t clockStart)
- {
-- struct timeb tb;
-- U32 nCount;
-- ftime( &tb );
-- nCount = (U32) (((tb.time & 0xFFFFF) * 1000) + tb.millitm);
-- return nCount;
--}
--
--static U32 FUZ_GetMilliSpan(U32 nTimeStart)
--{
-- U32 const nCurrent = FUZ_GetMilliStart();
-- U32 nSpan = nCurrent - nTimeStart;
-- if (nTimeStart > nCurrent)
-- nSpan += 0x100000 * 1000;
-- return nSpan;
-+ return clock() - clockStart; /* works even when overflow. Max span ~ 30 mn */
- }
-
- /*! FUZ_rand() :
-@@ -336,7 +323,7 @@ static int fuzzerTests(U32 seed, U32 nbT
- U32 coreSeed = seed;
- ZSTD_CStream* zc;
- ZSTD_DStream* zd;
-- U32 startTime = FUZ_GetMilliStart();
-+ clock_t startClock = clock();
-
- /* allocations */
- zc = ZSTD_createCStream();
-@@ -366,7 +353,7 @@ static int fuzzerTests(U32 seed, U32 nbT
- FUZ_rand(&coreSeed);
-
- /* test loop */
-- for ( ; (testNb <= nbTests) || (FUZ_GetMilliSpan(startTime) < g_testTime) ; testNb++ ) {
-+ for ( ; (testNb <= nbTests) || (FUZ_GetClockSpan(startClock) < g_clockTime) ; testNb++ ) {
- U32 lseed;
- const BYTE* srcBuffer;
- const BYTE* dict;
-@@ -594,7 +581,7 @@ int main(int argc, const char** argv)
-
- case 'i':
- argument++;
-- nbTests=0; g_testTime=0;
-+ nbTests=0; g_clockTime=0;
- while ((*argument>='0') && (*argument<='9')) {
- nbTests *= 10;
- nbTests += *argument - '0';
-@@ -604,15 +591,15 @@ int main(int argc, const char** argv)
-
- case 'T':
- argument++;
-- nbTests=0; g_testTime=0;
-+ nbTests=0; g_clockTime=0;
- while ((*argument>='0') && (*argument<='9')) {
-- g_testTime *= 10;
-- g_testTime += *argument - '0';
-+ g_clockTime *= 10;
-+ g_clockTime += *argument - '0';
- argument++;
- }
-- if (*argument=='m') g_testTime *=60, argument++;
-+ if (*argument=='m') g_clockTime *=60, argument++;
- if (*argument=='n') argument++;
-- g_testTime *= 1000;
-+ g_clockTime *= CLOCKS_PER_SEC;
- break;
-
- case 's':
-@@ -656,7 +643,12 @@ int main(int argc, const char** argv)
- /* Get Seed */
- DISPLAY("Starting zstream tester (%i-bits, %s)\n", (int)(sizeof(size_t)*8), ZSTD_VERSION_STRING);
-
-- if (!seedset) seed = FUZ_GetMilliStart() % 10000;
-+ if (!seedset) {
-+ time_t const t = time(NULL);
-+ U32 const h = XXH32(&t, sizeof(t), 1);
-+ seed = h % 10000;
-+ }
-+
- DISPLAY("Seed = %u\n", seed);
- if (proba!=FUZ_COMPRESSIBILITY_DEFAULT) DISPLAY("Compressibility : %i%%\n", proba);
-