| Index: src/platform/time.cc
|
| diff --git a/src/platform/time.cc b/src/platform/time.cc
|
| index 653eb14bf410409be9ae36820d34a6c581591b11..073ca1e1f4b985d792d9a2894155d7dd93b07831 100644
|
| --- a/src/platform/time.cc
|
| +++ b/src/platform/time.cc
|
| @@ -509,6 +509,15 @@ TimeTicks TimeTicks::HighResNow() {
|
| info.numer / info.denom);
|
| #elif V8_OS_SOLARIS
|
| ticks = (gethrtime() / Time::kNanosecondsPerMicrosecond);
|
| +#elif V8_LIBRT_NOT_AVAILABLE
|
| + // TODO(bmeurer): This is a temporary hack to support cross-compiling
|
| + // Chrome for Android in AOSP. Remove this once AOSP is fixed, also
|
| + // cleanup the tools/gyp/v8.gyp file.
|
| + struct timeval tv;
|
| + int result = gettimeofday(&tv, NULL);
|
| + ASSERT_EQ(0, result);
|
| + USE(result);
|
| + ticks = (tv.tv_sec * Time::kMicrosecondsPerSecond + tv.tv_usec);
|
| #elif V8_OS_POSIX
|
| struct timespec ts;
|
| int result = clock_gettime(CLOCK_MONOTONIC, &ts);
|
|
|