diff options
author | delphij <delphij@FreeBSD.org> | 2010-04-20 21:14:30 +0000 |
---|---|---|
committer | delphij <delphij@FreeBSD.org> | 2010-04-20 21:14:30 +0000 |
commit | e4b26ec67a953a97b5d3a15de185f83a578af117 (patch) | |
tree | c8dc092f22c2647488f759e7f9990fc5073df17d /lib/libz/zutil.h | |
parent | dc4a42cb4b6509185498a72943ae7973a596144f (diff) | |
download | FreeBSD-src-e4b26ec67a953a97b5d3a15de185f83a578af117.zip FreeBSD-src-e4b26ec67a953a97b5d3a15de185f83a578af117.tar.gz |
MFV: zlib 1.2.5.
Diffstat (limited to 'lib/libz/zutil.h')
-rw-r--r-- | lib/libz/zutil.h | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/lib/libz/zutil.h b/lib/libz/zutil.h index a250088..258fa88 100644 --- a/lib/libz/zutil.h +++ b/lib/libz/zutil.h @@ -13,7 +13,12 @@ #ifndef ZUTIL_H #define ZUTIL_H -#define ZLIB_INTERNAL +#if ((__GNUC__-0) * 10 + __GNUC_MINOR__-0 >= 33) && !defined(NO_VIZ) +# define ZLIB_INTERNAL __attribute__((visibility ("hidden"))) +#else +# define ZLIB_INTERNAL +#endif + #include "zlib.h" #ifdef STDC @@ -231,16 +236,16 @@ extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ # define zmemzero(dest, len) memset(dest, 0, len) # endif #else - extern void zmemcpy OF((Bytef* dest, const Bytef* source, uInt len)); - extern int zmemcmp OF((const Bytef* s1, const Bytef* s2, uInt len)); - extern void zmemzero OF((Bytef* dest, uInt len)); + void ZLIB_INTERNAL zmemcpy OF((Bytef* dest, const Bytef* source, uInt len)); + int ZLIB_INTERNAL zmemcmp OF((const Bytef* s1, const Bytef* s2, uInt len)); + void ZLIB_INTERNAL zmemzero OF((Bytef* dest, uInt len)); #endif /* Diagnostic functions */ #ifdef DEBUG # include <stdio.h> - extern int z_verbose; - extern void z_error OF((char *m)); + extern int ZLIB_INTERNAL z_verbose; + extern void ZLIB_INTERNAL z_error OF((char *m)); # define Assert(cond,msg) {if(!(cond)) z_error(msg);} # define Trace(x) {if (z_verbose>=0) fprintf x ;} # define Tracev(x) {if (z_verbose>0) fprintf x ;} @@ -257,8 +262,9 @@ extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ #endif -voidpf zcalloc OF((voidpf opaque, unsigned items, unsigned size)); -void zcfree OF((voidpf opaque, voidpf ptr)); +voidpf ZLIB_INTERNAL zcalloc OF((voidpf opaque, unsigned items, + unsigned size)); +void ZLIB_INTERNAL zcfree OF((voidpf opaque, voidpf ptr)); #define ZALLOC(strm, items, size) \ (*((strm)->zalloc))((strm)->opaque, (items), (size)) |