diff options
author | Gilles Vollant <info@winimage.com> | 2020-05-25 17:49:46 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2020-07-12 18:11:37 +0200 |
commit | e13357b14b7de013043d704dc9c80697e62616c6 (patch) | |
tree | 47146c8bc1645313653e15fdeb8e1f9f8f0e3bff /docs | |
parent | c4026a98979f6ed0f6cf9e544d6544ea3b23464c (diff) | |
download | curl-e13357b14b7de013043d704dc9c80697e62616c6.tar.gz |
content_encoding: add zstd decoding support
include zstd curl patch for Makefile.m32 from vszakats
and include Add CMake support for zstd from Peter Wu
Helped-by: Viktor Szakats
Helped-by: Peter Wu
Closes #5453
Diffstat (limited to 'docs')
-rw-r--r-- | docs/examples/Makefile.m32 | 14 | ||||
-rw-r--r-- | docs/libcurl/curl_version_info.3 | 7 | ||||
-rw-r--r-- | docs/libcurl/opts/CURLOPT_ACCEPT_ENCODING.3 | 10 | ||||
-rw-r--r-- | docs/libcurl/symbols-in-versions | 2 |
4 files changed, 28 insertions, 5 deletions
diff --git a/docs/examples/Makefile.m32 b/docs/examples/Makefile.m32 index d0694cfa3..e8c0d376f 100644 --- a/docs/examples/Makefile.m32 +++ b/docs/examples/Makefile.m32 @@ -24,7 +24,7 @@ # ## Makefile for building curl examples with MingW (GCC-3.2 or later) ## and optionally OpenSSL (1.0.2a), libssh2 (1.5), zlib (1.2.8), librtmp (2.4), -## brotli (1.0.1) +## brotli (1.0.1), zstd (1.4.5) ## ## Usage: mingw32-make -f Makefile.m32 CFG=-feature1[-feature2][-feature3][...] ## Example: mingw32-make -f Makefile.m32 CFG=-zlib-ssl-sspi-winidn @@ -39,6 +39,10 @@ ifndef ZLIB_PATH ZLIB_PATH = ../../../zlib-1.2.8 endif +# Edit the path below to point to the base of your Zstandard sources. +ifndef ZSTD_PATH +ZSTD_PATH = ../../../zstd-1.4.5 +endif # Edit the path below to point to the base of your Brotli sources. ifndef BROTLI_PATH BROTLI_PATH = ../../../brotli-1.0.1 @@ -180,6 +184,9 @@ endif ifeq ($(findstring -zlib,$(CFG)),-zlib) ZLIB = 1 endif +ifeq ($(findstring -zstd,$(CFG)),-zstd) +ZSTD = 1 +endif ifeq ($(findstring -brotli,$(CFG)),-brotli) BROTLI = 1 endif @@ -284,6 +291,11 @@ ifdef ZLIB CFLAGS += -DHAVE_LIBZ -DHAVE_ZLIB_H curl_LDADD += -L"$(ZLIB_PATH)" -lz endif +ifdef ZSTD + INCLUDES += -I"$(ZSTD_PATH)/include" + CFLAGS += -DHAVE_ZSTD + curl_LDADD += -L"$(ZSTD_PATH)/lib" -lzstd +endif ifdef BROTLI INCLUDES += -I"$(BROTLI_PATH)/include" CFLAGS += -DHAVE_BROTLI diff --git a/docs/libcurl/curl_version_info.3 b/docs/libcurl/curl_version_info.3 index 437b9a034..7a6a540ff 100644 --- a/docs/libcurl/curl_version_info.3 +++ b/docs/libcurl/curl_version_info.3 @@ -92,6 +92,11 @@ typedef struct { be NULL */ const char *capath; /* the built-in default CURLOPT_CAPATH, might be NULL */ + /* when 'age' is CURLVERSION_EIGHTH or higher (>= 7.71.0), the members + below exist */ + unsigned int zstd_ver_num; /* Numeric Zstd version + (MAJOR << 24) | (MINOR << 12) | PATCH */ + const char *zstd_version; /* human readable string. */ } curl_version_info_data; .fi @@ -121,6 +126,8 @@ more exact timeouts (even on Windows) and less blocking when using the multi interface. (added in 7.10.7) .IP CURL_VERSION_BROTLI supports HTTP Brotli content encoding using libbrotlidec (Added in 7.57.0) +.IP CURL_VERSION_ZSTD +supports HTTP zstd content encoding using zstd library (Added in 7.72.0) .IP CURL_VERSION_CONV libcurl was built with support for character conversions, as provided by the CURLOPT_CONV_* callbacks. (Added in 7.15.4) diff --git a/docs/libcurl/opts/CURLOPT_ACCEPT_ENCODING.3 b/docs/libcurl/opts/CURLOPT_ACCEPT_ENCODING.3 index abd4734ab..fc8aa4e52 100644 --- a/docs/libcurl/opts/CURLOPT_ACCEPT_ENCODING.3 +++ b/docs/libcurl/opts/CURLOPT_ACCEPT_ENCODING.3 @@ -45,8 +45,9 @@ Alternatively, you can specify exactly the encoding or list of encodings you want in the response. Four encodings are supported: \fIidentity\fP, meaning non-compressed, \fIdeflate\fP which requests the server to compress its response using the zlib algorithm, \fIgzip\fP which requests the gzip -algorithm and (since curl 7.57.0) \fIbr\fP which is brotli. Provide them in -the string as a comma-separated list of accepted encodings, like: +algorithm, (since curl 7.57.0) \fIbr\fP which is brotli and (since curl +7.72.0) \fIzstd\fP which is zstd. Provide them in the string as a +comma-separated list of accepted encodings, like: "br, gzip, deflate". @@ -94,8 +95,9 @@ if(curl) { This option was called CURLOPT_ENCODING before 7.21.6 The specific libcurl you're using must have been built with zlib to be able to -decompress gzip and deflate responses and with the brotli library to -decompress brotli responses. +decompress gzip and deflate responses, with the brotli library to +decompress brotli responses and with the zstd library to decompress zstd +responses. .SH RETURN VALUE Returns CURLE_OK if the option is supported, CURLE_UNKNOWN_OPTION if not, or CURLE_OUT_OF_MEMORY if there was insufficient heap space. diff --git a/docs/libcurl/symbols-in-versions b/docs/libcurl/symbols-in-versions index 36126db09..97224807c 100644 --- a/docs/libcurl/symbols-in-versions +++ b/docs/libcurl/symbols-in-versions @@ -803,6 +803,7 @@ CURLU_NO_DEFAULT_PORT 7.62.0 CURLU_PATH_AS_IS 7.62.0 CURLU_URLDECODE 7.62.0 CURLU_URLENCODE 7.62.0 +CURLVERSION_EIGHTH 7.72.0 CURLVERSION_FIFTH 7.57.0 CURLVERSION_FIRST 7.10 CURLVERSION_FOURTH 7.16.1 @@ -968,6 +969,7 @@ CURL_VERSION_SSL 7.10 CURL_VERSION_SSPI 7.13.2 CURL_VERSION_TLSAUTH_SRP 7.21.4 CURL_VERSION_UNIX_SOCKETS 7.40.0 +CURL_VERSION_ZSTD 7.72.0 CURL_WAIT_POLLIN 7.28.0 CURL_WAIT_POLLOUT 7.28.0 CURL_WAIT_POLLPRI 7.28.0 |