From: Derek Foreman Date: Mon, 29 Jun 2015 18:20:34 +0000 (-0500) Subject: compositor/clients: Protect CLOCK_BOOTTIME with ifdefs X-Git-Tag: upstream/5.0.0~1383 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=32838c93a509dbeda717e58279683c63a34a2e07;p=platform%2Fupstream%2Fweston.git compositor/clients: Protect CLOCK_BOOTTIME with ifdefs CLOCK_BOOTTIME is a relatively new* feature that may not actually be present everywhere (I'm looking at you wheezy). Since our use of it is actually only cosmetic, I've just ifdef'd if. * No it isn't. Signed-off-by: Derek Foreman Reviewed-by: Giulio Camuffo --- diff --git a/clients/weston-info.c b/clients/weston-info.c index 89ef8f1..f22781c 100644 --- a/clients/weston-info.c +++ b/clients/weston-info.c @@ -579,7 +579,9 @@ clock_name(clockid_t clk_id) [CLOCK_MONOTONIC_RAW] = "CLOCK_MONOTONIC_RAW", [CLOCK_REALTIME_COARSE] = "CLOCK_REALTIME_COARSE", [CLOCK_MONOTONIC_COARSE] = "CLOCK_MONOTONIC_COARSE", +#ifdef CLOCK_BOOTTIME [CLOCK_BOOTTIME] = "CLOCK_BOOTTIME", +#endif }; if (clk_id < 0 || (unsigned)clk_id >= ARRAY_LENGTH(names)) diff --git a/src/main.c b/src/main.c index 1591018..329db14 100644 --- a/src/main.c +++ b/src/main.c @@ -393,7 +393,9 @@ clock_name(clockid_t clk_id) [CLOCK_MONOTONIC_RAW] = "CLOCK_MONOTONIC_RAW", [CLOCK_REALTIME_COARSE] = "CLOCK_REALTIME_COARSE", [CLOCK_MONOTONIC_COARSE] = "CLOCK_MONOTONIC_COARSE", +#ifdef CLOCK_BOOTTIME [CLOCK_BOOTTIME] = "CLOCK_BOOTTIME", +#endif }; if (clk_id < 0 || (unsigned)clk_id >= ARRAY_LENGTH(names))