Topics

#define ZLIB_WINAPI? #define


Wayne Wooten
 

I noticed when trying to build OpenEXR 1.7.0 on Windows, that:

#define ZLIB_WINAPI

has been added to those files that #include <zlib.h>

It took me a couple of hours to determine why the EXR libraries
could not resolve the symbols in the standard builds of zlib on
Windows. By default zlib on Windows is not built with the WINAPI
attributes and will not link against code that defines ZLIB_WINAPI.

I'd argue that ZLIB_WINAPI should not be defined because code
that does this then requires a special build of zlib (that has been built
with the ZLIB_WINAPI turned on.)

Thanks!
--Wayne