From 0e12c56a972320a608bbb8c31b7726674f000bb1 Mon Sep 17 00:00:00 2001 From: aavit Date: Tue, 5 Apr 2011 11:25:59 +0200 Subject: Really avoid compiler warnings on Windows --- src/3rdparty/libjpeg/jinclude.h | 4 ++++ src/3rdparty/libpng/pngpriv.h | 4 ++++ src/3rdparty/zlib/gzguts.h | 5 +++++ src/3rdparty/zlib/zconf.h | 2 -- 4 files changed, 13 insertions(+), 2 deletions(-) diff --git a/src/3rdparty/libjpeg/jinclude.h b/src/3rdparty/libjpeg/jinclude.h index 0a4f151..a61939d 100644 --- a/src/3rdparty/libjpeg/jinclude.h +++ b/src/3rdparty/libjpeg/jinclude.h @@ -20,6 +20,10 @@ #include "jconfig.h" /* auto configuration options */ #define JCONFIG_INCLUDED /* so that jpeglib.h doesn't do it again */ +#ifdef _MSC_VER +# define _CRT_SECURE_NO_DEPRECATE +#endif + /* * We need the NULL macro and size_t typedef. * On an ANSI-conforming system it is sufficient to include . diff --git a/src/3rdparty/libpng/pngpriv.h b/src/3rdparty/libpng/pngpriv.h index 45a622b..9b90f26 100644 --- a/src/3rdparty/libpng/pngpriv.h +++ b/src/3rdparty/libpng/pngpriv.h @@ -25,6 +25,10 @@ #ifndef PNGPRIV_H #define PNGPRIV_H +#ifdef _MSC_VER +# define _CRT_SECURE_NO_DEPRECATE +#endif + /* This is required for the definition of abort(), used as a last ditch * error handler when all else fails. */ diff --git a/src/3rdparty/zlib/gzguts.h b/src/3rdparty/zlib/gzguts.h index 60b493e..347af46 100644 --- a/src/3rdparty/zlib/gzguts.h +++ b/src/3rdparty/zlib/gzguts.h @@ -3,6 +3,11 @@ * For conditions of distribution and use, see copyright notice in zlib.h */ +#ifdef _MSC_VER +# define _CRT_SECURE_NO_DEPRECATE +# define _CRT_NONSTDC_NO_DEPRECATE +#endif + #ifdef _LARGEFILE64_SOURCE # ifndef _LARGEFILE_SOURCE # define _LARGEFILE_SOURCE 1 diff --git a/src/3rdparty/zlib/zconf.h b/src/3rdparty/zlib/zconf.h index a92eb36..0105ca4 100644 --- a/src/3rdparty/zlib/zconf.h +++ b/src/3rdparty/zlib/zconf.h @@ -271,8 +271,6 @@ #endif #if defined(WINDOWS) || defined(WIN32) -# define _CRT_SECURE_NO_DEPRECATE -# define _CRT_NONSTDC_NO_DEPRECATE /* If building or using zlib as a DLL, define ZLIB_DLL. * This is not mandatory, but it offers a little performance increase. */ -- cgit v0.12