From: Iain Sandoe Date: Sat, 11 Apr 2015 19:58:48 +0100 Subject: [PATCH] Fix up thread constexpr for GCC where the PPC port can't do long long constexpr. --- libcxx-5.0.1.src/include/thread | 6 ++++++ 1 file changed, 6 insertions(+) diff --git libcxx-5.0.1.src/include/include/thread libcxx-5.0.1.src/include/thread index 022021c..7a4d692 100644 --- libcxx-5.0.1.src/include/thread +++ libcxx-5.0.1.src/include/thread @@ -443,7 +443,13 @@ sleep_for(const chrono::duration<_Rep, _Period>& __d) using namespace chrono; if (__d > duration<_Rep, _Period>::zero()) { +#if ! defined (__clang__) && __APPLE__ && (__ppc__ || __ppc64__) + // We can't test for __GNUC__ since clang also defines that. + _LIBCPP_CONSTEXPR duration _Max = duration(ULLONG_MAX/1000000000ULL) ; + //nanoseconds::max(); .. long double const folding is broken :( +#else _LIBCPP_CONSTEXPR duration _Max = nanoseconds::max(); +#endif nanoseconds __ns; if (__d < _Max) { -- 2.8.1