From Piotr Gwiazdowski, "So there's config setting OSG_DISABLE_MSVC_WARNINGS which should

disable pragmas that turn off specific warnings for MSVC.
Unfortunately it's presence is only checked in osg/Export header,
making other Export headers disable warnings no matter what, which is
kind of incoherent.

My fix adds #include <osg/Config> to every Export header. I've also
unified checking whether to disable warnings to current osg/Export
way:
#if defined(_MSC_VER) && defined(OSG_DISABLE_MSVC_WARNINGS).

Attachment contains all changed Export files in their original locations."
This commit is contained in:
Robert Osfield
2011-03-09 14:15:04 +00:00
parent b91741b421
commit d3d0859b4c
14 changed files with 42 additions and 14 deletions

View File

@@ -15,7 +15,9 @@
#ifndef OSGANIMATION_EXPORT_
#define OSGANIMATION_EXPORT_ 1
#if defined(_MSC_VER)
#include<osg/Config>
#if defined(_MSC_VER) && defined(OSG_DISABLE_MSVC_WARNINGS)
#pragma warning( disable : 4244 )
#pragma warning( disable : 4251 )
#pragma warning( disable : 4267 )