From 03784a8172e4691d3af8100304513b578d1795c7 Mon Sep 17 00:00:00 2001 From: Markus Frank <markus.frank@cern.ch> Date: Thu, 1 Sep 2016 19:04:14 +0000 Subject: [PATCH] Remove boost warning. --- DDCore/src/parsers/GrammarsV2.h | 1 + DDG4/include/DDG4/IoStreams.h | 10 +++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/DDCore/src/parsers/GrammarsV2.h b/DDCore/src/parsers/GrammarsV2.h index fcbc66f58..d0b85de92 100644 --- a/DDCore/src/parsers/GrammarsV2.h +++ b/DDCore/src/parsers/GrammarsV2.h @@ -32,6 +32,7 @@ //============================================================================== #ifdef __GNUC__ #undef __GNUC__ +// Boost spits out an error if __GNUC__ is defined! #include <boost/spirit/include/qi.hpp> #define __GNUC__ #else diff --git a/DDG4/include/DDG4/IoStreams.h b/DDG4/include/DDG4/IoStreams.h index c18c73a87..2d1ce26be 100644 --- a/DDG4/include/DDG4/IoStreams.h +++ b/DDG4/include/DDG4/IoStreams.h @@ -22,12 +22,20 @@ #pragma GCC diagnostic ignored "-Wshadow" // Code that causes warning goes here #endif +#ifdef __GNUC__ +#undef __GNUC__ +// Boost spits out an error if __GNUC__ is defined! +#include <boost/iostreams/stream.hpp> +#define __GNUC__ +#else +#include <boost/iostreams/stream.hpp> +#endif + // booost iostreams include files #include <boost/iostreams/categories.hpp> #include <boost/iostreams/detail/ios.hpp> #include <boost/iostreams/detail/path.hpp> #include <boost/iostreams/positioning.hpp> -#include <boost/iostreams/stream.hpp> // Forward declarations class TFile; -- GitLab