diff options
Diffstat (limited to 'src/3rdparty/zlib/qtpatches.diff')
-rw-r--r-- | src/3rdparty/zlib/qtpatches.diff | 136 |
1 files changed, 52 insertions, 84 deletions
diff --git a/src/3rdparty/zlib/qtpatches.diff b/src/3rdparty/zlib/qtpatches.diff index 98a7b2c205..28be579dc9 100644 --- a/src/3rdparty/zlib/qtpatches.diff +++ b/src/3rdparty/zlib/qtpatches.diff @@ -1,58 +1,23 @@ -diff -ruN orig/ChangeLog src/ChangeLog ---- orig/ChangeLog 2017-08-03 08:25:11.347386101 +0200 -+++ src/ChangeLog 2017-08-03 08:25:21.477268439 +0200 +diff --git a/src/ChangeLog b/src/ChangeLog +index b801a1031ec..686283a2aec 100644 +--- a/src/ChangeLog ++++ b/src/ChangeLog @@ -1,6 +1,10 @@ ChangeLog file for zlib -+Changes in 1.2.11 (Qt) (28 Jul 2017) ++Changes in 1.3.1 (Qt) (23 Jan 2024) +- This is a stripped down copy of zlib that contains patches to + make it compile as part of Qt. See also "qtpatches.diff". + - Changes in 1.2.11 (15 Jan 2017) - - Fix deflate stored bug when pulling last block from window - - Permit immediate deflateParams changes before any deflate input -diff -ruN orig/gzguts.h src/gzguts.h ---- orig/gzguts.h 2017-08-03 08:25:11.347386101 +0200 -+++ src/gzguts.h 2017-08-03 08:25:21.477268439 +0200 -@@ -3,6 +3,15 @@ - * For conditions of distribution and use, see copyright notice in zlib.h - */ - -+#ifdef _MSC_VER -+# ifndef _CRT_SECURE_NO_DEPRECATE -+# define _CRT_SECURE_NO_DEPRECATE -+# endif -+# ifndef _CRT_NONSTDC_NO_DEPRECATE -+# define _CRT_NONSTDC_NO_DEPRECATE -+# endif -+// disable warnings like '=': conversion from 'size_t' to 'unsigned int', possible loss of data -+# pragma warning(disable: 4267) -+#endif -+ - #ifdef _LARGEFILE64_SOURCE - # ifndef _LARGEFILE_SOURCE - # define _LARGEFILE_SOURCE 1 -@@ -12,6 +23,15 @@ - # endif - #endif - -+#ifndef QT_BOOTSTRAPPED -+# include <qconfig.h> -+#endif -+ -+#ifdef QT_VISIBILITY_AVAILABLE -+#define HAVE_HIDDEN -+#endif -+ -+ - #ifdef HAVE_HIDDEN - # define ZLIB_INTERNAL __attribute__((visibility ("hidden"))) - #else -diff -ruN orig/README src/README ---- orig/README 2017-08-03 08:25:11.347386101 +0200 -+++ src/README 2017-08-03 08:25:21.477268439 +0200 -@@ -6,6 +6,9 @@ + Changes in 1.3.1 (22 Jan 2024) + - Reject overflows of zip header fields in minizip + - Fix bug in inflateSync() for data held in bit buffer +diff --git a/src/README b/src/README +index c5f917540b6..af6b4f32bf5 100644 +--- a/src/README ++++ b/src/README +@@ -6,6 +6,9 @@ thread safe. The data format used by the zlib library is described by RFCs http://tools.ietf.org/html/rfc1950 (zlib format), rfc1951 (deflate format) and rfc1952 (gzip format). @@ -62,9 +27,27 @@ diff -ruN orig/README src/README All functions of the compression library are documented in the file zlib.h (volunteer to write man pages welcome, contact zlib@gzip.org). A usage example of the library is given in the file test/example.c which also tests that -diff -ruN orig/zconf.h src/zconf.h ---- orig/zconf.h 2017-08-03 08:25:11.347386101 +0200 -+++ src/zconf.h 2017-08-03 08:25:21.477268439 +0200 +diff --git a/src/gzguts.h b/src/gzguts.h +index eba72085bb7..5bf6b7d4813 100644 +--- a/src/gzguts.h ++++ b/src/gzguts.h +@@ -3,6 +3,12 @@ + * For conditions of distribution and use, see copyright notice in zlib.h + */ + ++#include <qconfig.h> ++ ++#ifdef QT_VISIBILITY_AVAILABLE ++#define HAVE_HIDDEN ++#endif ++ + #ifdef _LARGEFILE64_SOURCE + # ifndef _LARGEFILE_SOURCE + # define _LARGEFILE_SOURCE 1 +diff --git a/src/zconf.h b/src/zconf.h +index 62adc8d8431..4e14507a22d 100644 +--- a/src/zconf.h ++++ b/src/zconf.h @@ -8,6 +8,9 @@ #ifndef ZCONF_H #define ZCONF_H @@ -75,7 +58,7 @@ diff -ruN orig/zconf.h src/zconf.h /* * If you *really* need a unique prefix for all types and library functions, * compile with -DZ_PREFIX. The "standard" zlib should be compiled without it. -@@ -136,6 +139,7 @@ +@@ -139,6 +142,7 @@ # endif # define zlibCompileFlags z_zlibCompileFlags # define zlibVersion z_zlibVersion @@ -83,7 +66,7 @@ diff -ruN orig/zconf.h src/zconf.h /* all zlib typedefs in zlib.h and zconf.h */ # define Byte z_Byte -@@ -431,7 +435,7 @@ +@@ -433,7 +437,7 @@ typedef uLong FAR uLongf; typedef unsigned long z_crc_t; #endif @@ -92,10 +75,11 @@ diff -ruN orig/zconf.h src/zconf.h # define Z_HAVE_UNISTD_H #endif -diff -ruN orig/zlib.h src/zlib.h ---- orig/zlib.h 2017-08-03 08:25:11.347386101 +0200 -+++ src/zlib.h 2017-08-03 08:25:21.480601733 +0200 -@@ -33,12 +33,16 @@ +diff --git a/src/zlib.h b/src/zlib.h +index 8d4b932eaf6..2cff72ee865 100644 +--- a/src/zlib.h ++++ b/src/zlib.h +@@ -33,11 +33,15 @@ #include "zconf.h" @@ -107,45 +91,29 @@ diff -ruN orig/zlib.h src/zlib.h extern "C" { #endif --#define ZLIB_VERSION "1.2.11" --#define ZLIB_VERNUM 0x12b0 -+#define ZLIB_VERSION "1.2.11 (Qt)" -+#define ZLIB_VERNUM 0x12b0f +-#define ZLIB_VERSION "1.3.1" ++#define ZLIB_VERSION "1.3.1 (Qt)" + #define ZLIB_VERNUM 0x1310 #define ZLIB_VER_MAJOR 1 - #define ZLIB_VER_MINOR 2 - #define ZLIB_VER_REVISION 11 -diff -ruN orig/zutil.h src/zutil.h ---- orig/zutil.h 2017-08-03 08:25:11.347386101 +0200 -+++ src/zutil.h 2017-08-03 08:30:04.490657570 +0200 -@@ -13,6 +13,15 @@ + #define ZLIB_VER_MINOR 3 +diff --git a/src/zutil.h b/src/zutil.h +index 48dd7febae6..71dd616ab8d 100644 +--- a/src/zutil.h ++++ b/src/zutil.h +@@ -13,6 +13,12 @@ #ifndef ZUTIL_H #define ZUTIL_H -+#ifndef QT_BOOTSTRAPPED -+# include <qconfig.h> -+#endif ++#include <qconfig.h> + +#ifdef QT_VISIBILITY_AVAILABLE +#define HAVE_HIDDEN +#endif + -+ #ifdef HAVE_HIDDEN # define ZLIB_INTERNAL __attribute__((visibility ("hidden"))) #else -@@ -136,6 +145,11 @@ - # if defined(__MWERKS__) && __dest_os != __be_os && __dest_os != __win32_os - # include <unix.h> /* for fdopen */ - # else -+// We need to include stdio.h here because zlib.h will include TargetConditionals.h -+// This will define TARGET_OS_MAC that leads to this check. -+// Since zutil.h will include gzguts.h and gzguts.h includes stdio.h -+// AFTER check for fdopen we need to include stdio.h directly -+# include <stdio.h> - # ifndef fdopen - # define fdopen(fd,mode) NULL /* No fdopen() */ - # endif -@@ -159,7 +173,7 @@ +@@ -157,7 +163,7 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ # define OS_CODE 18 #endif |