aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.7
diff options
context:
space:
mode:
authorAndrew Hsieh <andrewhsieh@google.com>2012-12-28 18:37:49 +0800
committerAndrew Hsieh <andrewhsieh@google.com>2012-12-29 03:08:18 +0800
commitbd342f0491128ad15e6ea4ff241e243b753137c9 (patch)
tree1b9f4abf1706ab5c8e8a90a6d239dc5f1498cf42 /gcc-4.7
parentb6e375800c9a2f02a732cbdf5e87a860c3d954e1 (diff)
downloadtoolchain_gcc-bd342f0491128ad15e6ea4ff241e243b753137c9.tar.gz
toolchain_gcc-bd342f0491128ad15e6ea4ff241e243b753137c9.tar.bz2
toolchain_gcc-bd342f0491128ad15e6ea4ff241e243b753137c9.zip
Enable _GLIBCXX_USE_CLOCK_MONOTONIC in libstdc++
This is needed to provide "steady_clock" (or monotonic_clock in GCC 4.6/4.4.3) in <chrono> See http://code.google.com/p/android/issues/detail?id=39680 Change-Id: I0c31704971dc15751ce936f563de7c42a4e645a6
Diffstat (limited to 'gcc-4.7')
-rw-r--r--gcc-4.7/libstdc++-v3/acinclude.m42
-rwxr-xr-xgcc-4.7/libstdc++-v3/configure2
2 files changed, 2 insertions, 2 deletions
diff --git a/gcc-4.7/libstdc++-v3/acinclude.m4 b/gcc-4.7/libstdc++-v3/acinclude.m4
index 319e32784..c94810f0d 100644
--- a/gcc-4.7/libstdc++-v3/acinclude.m4
+++ b/gcc-4.7/libstdc++-v3/acinclude.m4
@@ -1197,7 +1197,7 @@ AC_DEFUN([GLIBCXX_ENABLE_LIBSTDCXX_TIME], [
[#include <unistd.h>
#include <time.h>
],
- [#if _POSIX_TIMERS > 0 && defined(_POSIX_MONOTONIC_CLOCK)
+ [#if _POSIX_TIMERS > 0 && (defined(_POSIX_MONOTONIC_CLOCK) || defined(__ANDROID__))
timespec tp;
#endif
clock_gettime(CLOCK_MONOTONIC, &tp);
diff --git a/gcc-4.7/libstdc++-v3/configure b/gcc-4.7/libstdc++-v3/configure
index aea3acc33..1c2d5ecac 100755
--- a/gcc-4.7/libstdc++-v3/configure
+++ b/gcc-4.7/libstdc++-v3/configure
@@ -19774,7 +19774,7 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
int
main ()
{
-#if _POSIX_TIMERS > 0 && defined(_POSIX_MONOTONIC_CLOCK)
+#if _POSIX_TIMERS > 0 && (defined(_POSIX_MONOTONIC_CLOCK) || defined(__ANDROID__))
timespec tp;
#endif
clock_gettime(CLOCK_MONOTONIC, &tp);