diff --git a/include/boost/config/platform/win32.hpp b/include/boost/config/platform/win32.hpp index 548bff28..9344818f 100644 --- a/include/boost/config/platform/win32.hpp +++ b/include/boost/config/platform/win32.hpp @@ -1,6 +1,7 @@ // (C) Copyright John Maddock 2001 - 2003. // (C) Copyright Bill Kempf 2001. // (C) Copyright Aleksey Gurtovoy 2003. +// (C) Copyright Rene Rivera 2005. // Use, modification and distribution are subject to the // Boost Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) @@ -11,6 +12,11 @@ #define BOOST_PLATFORM "Win32" +// Get the information about the MinGW runtime, i.e. __MINGW32_*VERSION. +#if defined(__MINGW32__) +# include <_mingw.h> +#endif + #if defined(__GNUC__) && !defined(BOOST_NO_SWPRINTF) # define BOOST_NO_SWPRINTF #endif @@ -19,9 +25,11 @@ # define BOOST_HAS_DECLSPEC #endif -#if defined(__MINGW32__) && ((__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 2))) +#if defined(__MINGW32__) && ((__MINGW32_MAJOR_VERSION > 2) || ((__MINGW32_MAJOR_VERSION == 2) && (__MINGW32_MINOR_VERSION >= 0))) # define BOOST_HAS_STDINT_H # define __STDC_LIMIT_MACROS +# define BOOST_HAS_DIRENT_H +# define BOOST_HAS_UNISTD_H #endif //