My projects need to define WIN32_LEAN_AND_MEAN. Unfortunately, they receive
many compilation warnings due to macro redefinition in the following Boost
headers (1.34.1).
boost/iostreams/detail/system_failure.hpp
boost/spirit/iterator/impl/file_iterator.ipp
I understand that I can avoid the need to define WIN32_LEAN_AND_MEAN by
ensuring that Boost headers are always included prior to
I have the same problem and any suggestions on how to solve this would
be much appreciated.
Currently I'm wrapping all boost includes that cause the problem this like:
#pragma warning(push)
#pragma warning(disable: 4005)
#include
My projects need to define WIN32_LEAN_AND_MEAN. Unfortunately, they receive many compilation warnings due to macro redefinition in the following Boost headers (1.34.1).
boost/iostreams/detail/system_failure.hpp boost/spirit/iterator/impl/file_iterator.ipp
I understand that I can avoid the need to define WIN32_LEAN_AND_MEAN by ensuring that Boost headers are always included prior to
. I do not like the idea of include order dependencies, as I am certain that I will come back to bite me down the road. Another option would be to turn the particular warning off; however, I would rather not do this.
Would it be prudent to patch the Boost headers to only define WIN32_LEAN_AND_MEAN if it is not already defined? If not, is there another solution that I am overlooking.
Thanks, Justin _______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
Would it be prudent to patch the Boost headers to only define WIN32_LEAN_AND_MEAN if it is not already defined? If not, is there another solution that I am overlooking.
Ok, I dropped WIN32_LEAN_AND_MEAN from Spirit. I discussed it with Hartmut and neither of us know where that came from. Probably a pre-boost artifact. Regards, -- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net
Great! Thank you for your quick resolution of this problem. I hope the
remaining defines in other library headers also can be removed.
// Anders
On 8/4/07, Joel de Guzman
Would it be prudent to patch the Boost headers to only define WIN32_LEAN_AND_MEAN if it is not already defined? If not, is there another solution that I am overlooking.
Ok, I dropped WIN32_LEAN_AND_MEAN from Spirit. I discussed it with Hartmut and neither of us know where that came from. Probably a pre-boost artifact.
Regards, -- Joel de Guzman http://www.boost-consulting.com http://spirit.sf.net
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
participants (3)
-
Anders Sundman
-
Joel de Guzman
-
KSpam