mirror of
https://github.com/4jcraft/4jcraft.git
synced 2026-06-05 19:42:55 +00:00
fix: prevent zlib Byte typedef clash with project class Byte under clang
This commit is contained in:
parent
379d7d9ee5
commit
57ed1aab14
|
|
@ -1,7 +1,13 @@
|
|||
#include "../../Build/stdafx.h"
|
||||
#include "Compression.h"
|
||||
#if defined __ORBIS__ || defined __PS3__ || defined _DURANGO || defined _WIN64 || defined __linux__
|
||||
// zconf.h defines "typedef unsigned char Byte" which conflicts with the
|
||||
// project's "class Byte" from BasicTypeContainers.h (via stdafx.h).
|
||||
// Rename zlib's Byte to zlib_Byte before the include so the typedef lands
|
||||
// under that alias; Bytef (= Byte FAR) will resolve to zlib_Byte as well.
|
||||
#define Byte zlib_Byte
|
||||
#include <zlib.h>
|
||||
#undef Byte
|
||||
#endif
|
||||
|
||||
#if defined __PSVITA__
|
||||
|
|
|
|||
Loading…
Reference in a new issue