From 74b768ba7a59fb5ae46be778f5274285757efd3e Mon Sep 17 00:00:00 2001 From: Frank Warmerdam Date: Thu, 30 Mar 2006 14:35:09 +0000 Subject: bug 1145: avoid warnings on VC8. git-svn-id: http://svn.osgeo.org/metacrs/proj/trunk@1329 4e78687f-474d-0410-85f9-8d5e500ac6b2 --- ChangeLog | 7 +++++++ src/cs2cs.c | 6 ++++-- src/gen_cheb.c | 2 +- src/p_series.c | 2 +- src/pj_strerrno.c | 3 ++- src/projects.h | 12 ++++++++++++ 6 files changed, 27 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8ee0d36f..6909da0a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2006-03-30 Frank Warmerdam + + * projects.h, cs2cs.c, pj_strerrno.c, p_series.c, gen_cheb.c: Added + _CRT_SECURE_NO_DEPRECATE declaration for VC8+, and ensure projects.h + gets included first where needed. Avoids loud warnings on VC8. + http://bugzilla.remotesensing.org/show_bug.cgi?id=1145 + 2006-03-29 Frank Warmerdam * pj_krovak.c: Removed MessageBox() DEBUG stuff. diff --git a/src/cs2cs.c b/src/cs2cs.c index e94e71a8..abf62c30 100644 --- a/src/cs2cs.c +++ b/src/cs2cs.c @@ -29,6 +29,9 @@ ****************************************************************************** * * $Log$ + * Revision 1.9 2006/03/30 14:35:09 fwarmerdam + * bug 1145: avoid warnings on VC8. + * * Revision 1.8 2004/10/28 16:05:37 fwarmerdam * avoid using global variables from DLL * @@ -54,13 +57,12 @@ * New * */ - +#include "projects.h" #include #include #include #include #include -#include "projects.h" #include "emess.h" #define MAX_LINE 200 diff --git a/src/gen_cheb.c b/src/gen_cheb.c index e85305d8..92c7b9fd 100644 --- a/src/gen_cheb.c +++ b/src/gen_cheb.c @@ -3,10 +3,10 @@ static const char SCCSID[]="@(#)gen_cheb.c 4.9 95/09/23 GIE REL"; #endif #define PJ_LIB__ +#include "projects.h" #include #include #include -#include #include "emess.h" #ifndef COEF_LINE_MAX #define COEF_LINE_MAX 60 diff --git a/src/p_series.c b/src/p_series.c index 7c16a23d..a2b531df 100644 --- a/src/p_series.c +++ b/src/p_series.c @@ -2,9 +2,9 @@ #ifndef lint static const char SCCSID[]="@(#)p_series.c 4.6 95/08/19 GIE REL"; #endif +#include "projects.h" #include #include -#include #define NF 20 /* length of final format string */ #define CUT 60 /* check length of line */ void diff --git a/src/pj_strerrno.c b/src/pj_strerrno.c index 98b03405..4157ada0 100644 --- a/src/pj_strerrno.c +++ b/src/pj_strerrno.c @@ -2,10 +2,11 @@ #ifndef lint static const char SCCSID[]="@(#)pj_strerrno.c 4.12 94/05/25 GIE REL"; #endif +#include "projects.h" #include #include #include -#include + static char * pj_err_list[] = { "no arguments in initialization list", /* -1 */ diff --git a/src/projects.h b/src/projects.h index 28a4d7da..042fcd36 100644 --- a/src/projects.h +++ b/src/projects.h @@ -28,6 +28,9 @@ ****************************************************************************** * * $Log$ + * Revision 1.22 2006/03/30 14:35:09 fwarmerdam + * bug 1145: avoid warnings on VC8. + * * Revision 1.21 2004/10/28 16:08:13 fwarmerdam * added pj_get_*_ref() accessors * @@ -86,6 +89,15 @@ #ifndef PROJECTS_H #define PROJECTS_H +#ifdef _MSC_VER +# ifndef _CRT_SECURE_NO_DEPRECATE +# define _CRT_SECURE_NO_DEPRECATE +# endif +# ifndef _CRT_NONSTDC_NO_DEPRECATE +# define _CRT_NONSTDC_NO_DEPRECATE +# endif +#endif + /* standard inclusions */ #include #include -- cgit v1.2.3