From 1727aa33b31ddb9949a6f050b33454861649c246 Mon Sep 17 00:00:00 2001 From: Dave Abrahams Date: Wed, 28 Jan 2004 22:52:26 +0000 Subject: [PATCH] merged from HEAD [SVN r22028] --- include/boost/python/type_id.hpp | 5 ++- src/converter/type_id.cpp | 15 +++++-- test/Jamfile | 71 ++++++++++++++------------------ 3 files changed, 45 insertions(+), 46 deletions(-) diff --git a/include/boost/python/type_id.hpp b/include/boost/python/type_id.hpp index e76a9cb9..b7df191c 100755 --- a/include/boost/python/type_id.hpp +++ b/include/boost/python/type_id.hpp @@ -17,8 +17,9 @@ # include # ifndef BOOST_PYTHON_HAVE_GCC_CP_DEMANGLE -# if defined(__GNUC__) \ - && ((__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1))) +# if defined(__GNUC__) \ + && ((__GNUC__ > 3) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1))) \ + && !defined(__EDG_VERSION__) # define BOOST_PYTHON_HAVE_GCC_CP_DEMANGLE # endif # endif diff --git a/src/converter/type_id.cpp b/src/converter/type_id.cpp index 528c5129..4d86f87f 100644 --- a/src/converter/type_id.cpp +++ b/src/converter/type_id.cpp @@ -13,7 +13,7 @@ #include #include -#if !defined(__GNUC__) || __GNUC__ >= 3 || __SGI_STL_PORT +#if !defined(__GNUC__) || __GNUC__ >= 3 || __SGI_STL_PORT || __EDG_VERSION__ # include #else # include @@ -33,10 +33,19 @@ namespace boost { namespace python { # if __GNUC__ < 3 namespace cxxabi = :: ; -# else +extern "C" char* __cxa_demangle(char const*, char*, std::size_t*, int*); +# else + namespace cxxabi = ::abi; // GCC 3.1 and later + +# if __GNUC__ == 3 && __GNUC_MINOR__ == 0 +namespace abi +{ + extern "C" char* __cxa_demangle(char const*, char*, std::size_t*, int*); +} +# endif # endif -# endif +# endif namespace { diff --git a/test/Jamfile b/test/Jamfile index 99a717bd..e53db7cb 100644 --- a/test/Jamfile +++ b/test/Jamfile @@ -21,10 +21,13 @@ rule turn-off-intel-debug-symbols ( toolset variant : properties * ) } return $(properties) ; } - -local UNIT_TEST_PROPERTIES = $(PYTHON_PROPERTIES) BOOST_PYTHON_SUPPRESS_REGISTRY_INITIALIZATION - [ difference $(PYTHON_PROPERTIES) : BOOST_PYTHON_DYNAMIC_LIB ] BOOST_PYTHON_STATIC_LIB ; +template py-unit-test + : + : $(PYTHON_PROPERTIES) BOOST_PYTHON_SUPPRESS_REGISTRY_INITIALIZATION + [ difference $(PYTHON_PROPERTIES) : BOOST_PYTHON_DYNAMIC_LIB ] BOOST_PYTHON_STATIC_LIB + ; + # Convenience rule makes declaring tests faster rule bpl-test ( name ? : files * : requirements * ) { @@ -61,16 +64,17 @@ rule bpl-test ( name ? : files * : requirements * ) m = $(m)_ext ; } } - extension $(m) : $(f) ../build/boost_python : $(requirements) ; + extension $(m) : $(f)