mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[libpng16]Check ZLIB_VERNUM for mismatches, enclose #error in quotes
This commit is contained in:
committed by
Glenn Randers-Pehrson
parent
9afb90f885
commit
122bec17f2
1
ANNOUNCE
1
ANNOUNCE
@@ -71,6 +71,7 @@ Version 1.6.3beta05 [May 8, 2013]
|
|||||||
invalid values.
|
invalid values.
|
||||||
Attempt to detect configuration issues with pngdeflate, which requires
|
Attempt to detect configuration issues with pngdeflate, which requires
|
||||||
both the correct libpng and the correct zlib to function correctly.
|
both the correct libpng and the correct zlib to function correctly.
|
||||||
|
Check ZLIB_VERNUM for mismatches, enclose #error in quotes
|
||||||
|
|
||||||
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
||||||
(subscription required; visit
|
(subscription required; visit
|
||||||
|
|||||||
1
CHANGES
1
CHANGES
@@ -4554,6 +4554,7 @@ Version 1.6.3beta05 [May 8, 2013]
|
|||||||
invalid values.
|
invalid values.
|
||||||
Attempt to detect configuration issues with pngdeflate, which requires
|
Attempt to detect configuration issues with pngdeflate, which requires
|
||||||
both the correct libpng and the correct zlib to function correctly.
|
both the correct libpng and the correct zlib to function correctly.
|
||||||
|
Check ZLIB_VERNUM for mismatches, enclose #error in quotes
|
||||||
|
|
||||||
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
||||||
(subscription required; visit
|
(subscription required; visit
|
||||||
|
|||||||
@@ -26,14 +26,14 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if PNG_LIBPNG_VER < 10603 /* 1.6.3 */
|
#if PNG_LIBPNG_VER < 10603 /* 1.6.3 */
|
||||||
# error pngdeflate will not work with libpng versions prior to 1.6.3
|
# error "pngdeflate will not work with libpng versions prior to 1.6.3"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef PNG_READ_SUPPORTED
|
#ifdef PNG_READ_SUPPORTED
|
||||||
#include <zlib.h>
|
#include <zlib.h>
|
||||||
|
|
||||||
#ifndef PNG_MAXIMUM_INFLATE_WINDOW
|
#ifndef PNG_MAXIMUM_INFLATE_WINDOW
|
||||||
# error pngdeflate not supported in this libpng version
|
# error "pngdeflate not supported in this libpng version"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if PNG_ZLIB_VERNUM >= 0x1240
|
#if PNG_ZLIB_VERNUM >= 0x1240
|
||||||
|
|||||||
18
pngpriv.h
18
pngpriv.h
@@ -694,6 +694,24 @@
|
|||||||
#include "pngstruct.h"
|
#include "pngstruct.h"
|
||||||
#include "pnginfo.h"
|
#include "pnginfo.h"
|
||||||
|
|
||||||
|
/* Validate the include paths - the include path used to generate pnglibconf.h
|
||||||
|
* must match that used in the build, or we must be using pnglibconf.h.prebuilt:
|
||||||
|
*/
|
||||||
|
#if PNG_ZLIB_VERNUM != 0 && PNG_ZLIB_VERNUM != ZLIB_VERNUM
|
||||||
|
# error ZLIB_VERNUM != PNG_ZLIB_VERNUM \
|
||||||
|
"-I (include path) error: see the notes in pngpriv.h"
|
||||||
|
/* This means that when pnglibconf.h was built the copy of zlib.h that it
|
||||||
|
* used is not the same as the one being used here. Because the build of
|
||||||
|
* libpng makes decisions to use inflateInit2 and inflateReset2 based on the
|
||||||
|
* zlib version number and because this affects handling of certain broken
|
||||||
|
* PNG files the -I directives must match.
|
||||||
|
*
|
||||||
|
* The most likely explanation is that you passed a -I in CFLAGS, this will
|
||||||
|
* not work; all the preprocessor directories and in particular all the -I
|
||||||
|
* directives must be in CPPFLAGS.
|
||||||
|
*/
|
||||||
|
#endif
|
||||||
|
|
||||||
/* This is used for 16 bit gamma tables -- only the top level pointers are
|
/* This is used for 16 bit gamma tables -- only the top level pointers are
|
||||||
* const; this could be changed:
|
* const; this could be changed:
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user