moved warning to error pragmas to their own file to not force 'good

2002-01-05  Hans Breuer  <hans@breuer.org>

	* glibconfig.h.win32.in
	  msvc_recommended_pragmas.h (new file) : moved warning to
	error pragmas to their own file to not force 'good practice'
	programming in downstream libs and apps. Instead the new header
	will be used by -FImsvc_recommended_pragmas.h in gnome/cvs
	makefile.msc
	* */makefile.msc.in : use -FImsvc_recommended_pragmas.h
This commit is contained in:
Hans Breuer 2002-01-05 18:54:59 +00:00 committed by Hans Breuer
parent 7e92a2b325
commit abc754faca
6 changed files with 32 additions and 31 deletions

View File

@ -7,7 +7,7 @@ TOP = ..\..
################################################################ ################################################################
INCLUDES = -I . -I .. INCLUDES = -FImsvc_recommended_pragmas.h -I . -I ..
DEFINES = -DHAVE_CONFIG_H -DGLIB_COMPILATION -DG_LOG_DOMAIN=\"GLib\" -DG_ENABLE_DEBUG DEFINES = -DHAVE_CONFIG_H -DGLIB_COMPILATION -DG_LOG_DOMAIN=\"GLib\" -DG_ENABLE_DEBUG
DEPCFLAGS = -Zm400 $(INTL_CFLAGS) $(LIBICONV_CFLAGS) $(DIRENT_CFLAGS) DEPCFLAGS = -Zm400 $(INTL_CFLAGS) $(LIBICONV_CFLAGS) $(DIRENT_CFLAGS)

View File

@ -9,33 +9,6 @@
#include <glib/gmacros.h> #include <glib/gmacros.h>
#ifdef _MSC_VER
/* Make MSVC more pedantic, this is a recommended pragma list
* from _Win32_Programming_ by Rector and Newcomer.
*/
#pragma warning(error:4002)
#pragma warning(error:4003)
#pragma warning(1:4010)
#pragma warning(error:4013)
#pragma warning(1:4016)
#pragma warning(error:4020)
#pragma warning(error:4021)
#pragma warning(error:4027)
#pragma warning(error:4029)
#pragma warning(error:4033)
#pragma warning(error:4035)
#pragma warning(error:4045)
#pragma warning(error:4047)
#pragma warning(error:4049)
#pragma warning(error:4053)
#pragma warning(error:4071)
#pragma warning(disable:4101)
#pragma warning(error:4150)
#pragma warning(disable:4244) /* No possible loss of data warnings */
#pragma warning(disable:4305) /* No truncation from int to char warnings */
#endif /* _MSC_VER */
#include <limits.h> #include <limits.h>
#include <float.h> #include <float.h>

View File

@ -7,7 +7,7 @@ TOP = ..\..
################################################################ ################################################################
INCLUDES = -I .. -I . -I ..\glib INCLUDES = -FImsvc_recommended_pragmas.h -I .. -I . -I ..\glib
DEFINES = -DHAVE_CONFIG_H -DG_LOG_DOMAIN=\"GModule\" DEFINES = -DHAVE_CONFIG_H -DG_LOG_DOMAIN=\"GModule\"
all : \ all : \

View File

@ -9,7 +9,7 @@ TOP = ..\..
################################################################ ################################################################
INCLUDES = -I .. -I . -I ..\glib INCLUDES = -FImsvc_recommended_pragmas.h -I .. -I . -I ..\glib
DEFINES = -DHAVE_CONFIG_H -DG_LOG_DOMAIN=\"GThread\" DEFINES = -DHAVE_CONFIG_H -DG_LOG_DOMAIN=\"GThread\"
all : \ all : \
libgthread-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@-@LT_CURRENT_MINUS_AGE@.dll libgthread-@GLIB_MAJOR_VERSION@.@GLIB_MINOR_VERSION@-@LT_CURRENT_MINUS_AGE@.dll

View File

@ -0,0 +1,28 @@
#ifndef _MSC_VER
#pragma error "This header is for Microsoft VC only."
#endif /* _MSC_VER */
/* Make MSVC more pedantic, this is a recommended pragma list
* from _Win32_Programming_ by Rector and Newcomer.
*/
#pragma warning(error:4002) /* too many actual parameters for macro */
#pragma warning(error:4003) /* not enough actual parameters for macro */
#pragma warning(1:4010) /* single-line comment contains line-continuation character */
#pragma warning(error:4013) /* 'function' undefined; assuming extern returning int */
#pragma warning(1:4016) /* no function return type; using int as default */
#pragma warning(error:4020) /* too many actual parameters */
#pragma warning(error:4021) /* too few actual parameters */
#pragma warning(error:4027) /* function declared without formal parameter list */
#pragma warning(error:4029) /* declared formal parameter list different from definition */
#pragma warning(error:4033) /* 'function' must return a value */
#pragma warning(error:4035) /* 'function' : no return value */
#pragma warning(error:4045) /* array bounds overflow */
#pragma warning(error:4047) /* different levels of indirection */
#pragma warning(error:4049) /* terminating line number emission */
#pragma warning(error:4053) /* An expression of type void was used as an operand */
#pragma warning(error:4071) /* no function prototype given */
#pragma warning(disable:4101) /* unreferenced local variable */
#pragma warning(error:4150)
#pragma warning(disable:4244) /* No possible loss of data warnings */
#pragma warning(disable:4305) /* No truncation from int to char warnings */

View File

@ -7,7 +7,7 @@ TOP = ..\..
################################################################ ################################################################
INCLUDES = -I .. -I ..\glib -I ..\gmodule INCLUDES = -FImsvc_recommended_pragmas.h -I .. -I ..\glib -I ..\gmodule
DEFINES = -DHAVE_CONFIG_H DEFINES = -DHAVE_CONFIG_H
NONAUTOMATIC_TESTS = \ NONAUTOMATIC_TESTS = \