diff --git a/include/boost/python/detail/prefix.hpp b/include/boost/python/detail/prefix.hpp index f65ccbad..8b34ed77 100755 --- a/include/boost/python/detail/prefix.hpp +++ b/include/boost/python/detail/prefix.hpp @@ -10,11 +10,6 @@ // Unfortunately, Boost.Python needs to #include first, at // least... but this gets us as close as possible. -# include -# if defined(_SGI_COMPILER_VERSION) && _SGI_COMPILER_VERSION == 741 -# undef _POSIX_C_SOURCE -# undef _XOPEN_SOURCE -# endif # include # include diff --git a/include/boost/python/detail/wrap_python.hpp b/include/boost/python/detail/wrap_python.hpp index 795e8b8b..4921578f 100644 --- a/include/boost/python/detail/wrap_python.hpp +++ b/include/boost/python/detail/wrap_python.hpp @@ -20,6 +20,19 @@ // 04 Mar 01 Rolled in some changes from the Dragon fork (Dave Abrahams) // 01 Mar 01 define PyObject_INIT() for Python 1.x (Dave Abrahams) +#ifdef _DEBUG +# ifndef BOOST_DEBUG_PYTHON +# undef _DEBUG // Don't let Python force the debug library just because we're debugging. +# define DEBUG_UNDEFINED_FROM_WRAP_PYTHON_H +# endif +#endif + +# include +# if defined(_SGI_COMPILER_VERSION) && _SGI_COMPILER_VERSION == 741 +# undef _POSIX_C_SOURCE +# undef _XOPEN_SOURCE +# endif + // // Python's LongObject.h helpfully #defines ULONGLONG_MAX for us, // which confuses Boost's config @@ -44,13 +57,6 @@ #error Python 2.2 or higher is required for this version of Boost.Python. #endif -#ifdef _DEBUG -# ifndef BOOST_DEBUG_PYTHON -# undef _DEBUG // Don't let Python force the debug library just because we're debugging. -# define DEBUG_UNDEFINED_FROM_WRAP_PYTHON_H -# endif -#endif - // // Some things we need in order to get Python.h to work with compilers other // than MSVC on Win32