Do not force Z_CONST for C++.
authorMark Adler <madler@alumni.caltech.edu>
Sun, 14 Apr 2013 17:31:31 +0000 (10:31 -0700)
committerMark Adler <madler@alumni.caltech.edu>
Sun, 28 Apr 2013 22:57:11 +0000 (15:57 -0700)
Forcing Z_CONST resulted in an issue when compiling Firefox.  Now
if someone wants to compile zlib as C++ code (which it isn't), now
they will need to #define Z_CONST themselves.

zconf.h
zconf.h.cmakein
zconf.h.in

diff --git a/zconf.h b/zconf.h
index 7a9d8f21b54e6f405c15dea9c43fc56611fb0b28..9987a775530c0393e7c27b73b1e854b946d5ee47 100644 (file)
--- a/zconf.h
+++ b/zconf.h
 #  endif
 #endif
 
-#if ( defined(ZLIB_CONST) || defined(__cplusplus) ) && !defined(z_const)
+#if defined(ZLIB_CONST) && !defined(z_const)
 #  define z_const const
 #else
 #  define z_const
index 10e445f216f20dba6dba085560888ca0e3768b6b..043019cda1db5ec2ca6a7c82acce4d559e9787d0 100644 (file)
 #  endif
 #endif
 
-#if ( defined(ZLIB_CONST) || defined(__cplusplus) ) && !defined(z_const)
+#if defined(ZLIB_CONST) && !defined(z_const)
 #  define z_const const
 #else
 #  define z_const
index 7a9d8f21b54e6f405c15dea9c43fc56611fb0b28..9987a775530c0393e7c27b73b1e854b946d5ee47 100644 (file)
 #  endif
 #endif
 
-#if ( defined(ZLIB_CONST) || defined(__cplusplus) ) && !defined(z_const)
+#if defined(ZLIB_CONST) && !defined(z_const)
 #  define z_const const
 #else
 #  define z_const