Fix building and testing libc++ with GCC.
The changes in src/exception.cpp and cmake/Modules/HandleLibCXXABI.cmake fix a bug when building libc++ with GCC. Because GCC does not support __has_include we need to explicitly tell it that we are building against libc++abi via the preprocessor definition `LIBCXX_BUILDING_LIBCXXABI`. The changes in include/ratio are to work around CWG defect 1712 (constexpr variable template declarations). GCC 4.8 and before has not adopted the resolution to this defect. The changes in include/exception work around an issue where is_final is used without it being defined in type_traits. git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@237767 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -29,7 +29,7 @@
|
||||
#define __terminate_handler __cxxabiapple::__cxa_terminate_handler
|
||||
#define __unexpected_handler __cxxabiapple::__cxa_unexpected_handler
|
||||
#endif // _LIBCPPABI_VERSION
|
||||
#elif defined(LIBCXXRT) || __has_include(<cxxabi.h>)
|
||||
#elif defined(LIBCXXRT) || defined(LIBCXX_BUILDING_LIBCXXABI) || __has_include(<cxxabi.h>)
|
||||
#include <cxxabi.h>
|
||||
using namespace __cxxabiv1;
|
||||
#if defined(LIBCXXRT) || defined(_LIBCPPABI_VERSION)
|
||||
|
Reference in New Issue
Block a user