Re: [Gc] patch for cmake build system and a little warning disabler

Ivan Maidanski ivmai at mail.ru
Tue Oct 21 10:55:18 PDT 2008


Hi!

"Jack Andrews" <jack at sun.com> wrote:
> hi guys,
> 
> while it's not the prettiest tool, cmake generates makefiles
> for different systems.  here's one i wrote for visual c on win.
> it's quite short (compared to NT_THREAD_MAKEFILE) and
> maintainable.
> 
> also a small pragma for some annoying warnings.
> 
> ta, jack.

> Index: gc6.7/include/private/gc_priv.h
> ===================================================================
> --- gc6.7.orig/include/private/gc_priv.h
> +++ gc6.7/include/private/gc_priv.h
> @@ -19,6 +19,10 @@
>   # ifndef GC_PRIVATE_H
>   # define GC_PRIVATE_H
> 
> +#ifdef MSWIN32
> +#pragma warning(disable:4996)
> +#endif
> +
>   #if defined(mips) && defined(SYSTYPE_BSD) && defined(sony_news)
>       /* sony RISC NEWS, NEWSOS 4 */
>   #   define BSD_TIME
> _______________________________________________

This pragma is not needed now with current CVS (or, at least, with all my patches applied). I successfully compile GC lib itself (without tests, at least) for Win32/64 with -W3 (or, even, -W4 -wd4100 -wd4127 -wd4701) without any warnings produced. Other tested compilers (Watcom, MinGW, djgpp, Borland, Cygwin, Lunux/Free GCC x64/amd64, SunOS CC x64/amd64) are quiet too (except for a warning in GC_approx_sp()). For gcc I use "-O2 -fno-strict-aliasing -Wall -Wno-uninitialized".

Bye.



More information about the Gc mailing list