[Zlib-devel] Building zlib with C++
Paul Marquess
paul.marquess at ntlworld.com
Tue Aug 29 05:08:27 EDT 2006
The enclosed patch (against 1.2.3.1) makes a few cosmetic changes to the
source to allow zlib to be built with a C++ compiler.
The changes are
1. Use of ANSI C function definitions
I've left the old K&R style function definitions in place and made
the new ANSI C style definitions kick in when the STDC macro
is enabled.
2 Clashes with C++ keywords
There were quite a few instances of a variable called "this" that
clash with the C++ keyword of the same name. I renamed this variable
to "this_"
I've tried the enclosed patch with gcc/g++ 3 & 4 and the Sun C and C++
compiler. All worked fine.
Paul
-------------- next part --------------
A non-text attachment was scrubbed...
Name: zlib.patch.gz
Type: application/x-gzip
Size: 16920 bytes
Desc: not available
URL: <http://madler.net/pipermail/zlib-devel_madler.net/attachments/20060829/cbe723bb/attachment.bin>
More information about the Zlib-devel
mailing list