From: Denis Vlasenko Date: Sat, 7 Jun 2008 23:43:43 +0000 (-0000) Subject: define CLOCK_MONOTONIC to 1 if it is not defined X-Git-Tag: 1_11_0~107 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=09c0a749a126180a3f64db2171355731fd40a29f;p=oweals%2Fbusybox.git define CLOCK_MONOTONIC to 1 if it is not defined --- diff --git a/libbb/time.c b/libbb/time.c index 3aa0ee318..07c009417 100644 --- a/libbb/time.c +++ b/libbb/time.c @@ -12,6 +12,12 @@ #if ENABLE_MONOTONIC_SYSCALL #include +/* Old glibc (< 2.3.4) does not provide this constant. We use syscall + * directly so this definition is safe. */ +#ifndef CLOCK_MONOTONIC +#define CLOCK_MONOTONIC 1 +#endif + /* libc has incredibly messy way of doing this, * typically requiring -lrt. We just skip all this mess */ unsigned long long monotonic_us(void)