From: Jonathan Wakely Date: Sat, 17 Jan 2015 13:48:48 +0000 (+0000) Subject: re PR libstdc++/64638 (Build failure with recent futex changes in libstdc++, likely... X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c6c1bfd99bbe6789b88f59c90c753206ca1cd3fd;p=gcc.git re PR libstdc++/64638 (Build failure with recent futex changes in libstdc++, likely all non-gthreads targets) PR libstdc++/64638 * include/bits/atomic_futex.h: Use appropriate config macros for availability of std::mutex, std::condition and std::chrono. From-SVN: r219799 --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 63aa21bb124..e0bfa814bd3 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,9 @@ +2015-01-17 Jonathan Wakely + + PR libstdc++/64638 + * include/bits/atomic_futex.h: Use appropriate config macros for + availability of std::mutex, std::condition and std::chrono. + 2015-01-17 Ville Voutilainen Jonathan Wakely diff --git a/libstdc++-v3/include/bits/atomic_futex.h b/libstdc++-v3/include/bits/atomic_futex.h index 9a418d8a00b..2673604e995 100644 --- a/libstdc++-v3/include/bits/atomic_futex.h +++ b/libstdc++-v3/include/bits/atomic_futex.h @@ -48,6 +48,7 @@ namespace std _GLIBCXX_VISIBILITY(default) { _GLIBCXX_BEGIN_NAMESPACE_VERSION +#if defined(_GLIBCXX_HAS_GTHREADS) && defined(_GLIBCXX_USE_C99_STDINT_TR1) #if defined(_GLIBCXX_HAVE_LINUX_FUTEX) struct __atomic_futex_unsigned_base { @@ -209,7 +210,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION }; -#else +#else // !_GLIBCXX_HAVE_LINUX_FUTEX // If futexes are not available, use a mutex and a condvar to wait. // Because we access the data only within critical sections, all accesses @@ -280,7 +281,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION }; -#endif +#endif // _GLIBCXX_HAVE_LINUX_FUTEX +#endif // _GLIBCXX_HAS_GTHREADS && _GLIBCXX_USE_C99_STDINT_TR1 _GLIBCXX_END_NAMESPACE_VERSION } // namespace std