changeset 31847:39d36c2db68e

zstd: vendor python-zstandard 0.8.1 This contains a fix for compilation on BSDs. #no-check-commit
author Gregory Szorc <gregory.szorc@gmail.com>
date Sat, 08 Apr 2017 14:33:20 -0700
parents 1064a296a2a7
children 7160bdd56b84
files contrib/python-zstandard/NEWS.rst contrib/python-zstandard/c-ext/python-zstandard.h contrib/python-zstandard/zstd.c
diffstat 3 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/contrib/python-zstandard/NEWS.rst	Wed Mar 08 09:03:42 2017 -0500
+++ b/contrib/python-zstandard/NEWS.rst	Sat Apr 08 14:33:20 2017 -0700
@@ -1,6 +1,11 @@
 Version History
 ===============
 
+0.8.1 (released 2017-04-08)
+---------------------------
+
+* Add #includes so compilation on OS X and BSDs works (#20).
+
 0.8.0 (released 2017-03-08)
 ---------------------------
 
--- a/contrib/python-zstandard/c-ext/python-zstandard.h	Wed Mar 08 09:03:42 2017 -0500
+++ b/contrib/python-zstandard/c-ext/python-zstandard.h	Sat Apr 08 14:33:20 2017 -0700
@@ -17,7 +17,7 @@
 #include "zdict.h"
 #include "zstdmt_compress.h"
 
-#define PYTHON_ZSTANDARD_VERSION "0.8.0"
+#define PYTHON_ZSTANDARD_VERSION "0.8.1"
 
 typedef enum {
 	compressorobj_flush_finish,
--- a/contrib/python-zstandard/zstd.c	Wed Mar 08 09:03:42 2017 -0500
+++ b/contrib/python-zstandard/zstd.c	Sat Apr 08 14:33:20 2017 -0700
@@ -11,6 +11,9 @@
 #if defined(_WIN32)
 #define WIN32_LEAN_AND_MEAN
 #include <Windows.h>
+#elif defined(__APPLE__) || defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__)
+#include <sys/types.h>
+#include <sys/sysctl.h>
 #endif
 
 #include "python-zstandard.h"