$OpenBSD: patch-src_xine-engine_demux_c,v 1.4 2018/02/10 15:29:24 ajacoutot Exp $

Make use of clock_gettime() on OpenBSD. Until we have per-process
timers and can enable _POSIX_TIMERS in unistd.h.

Index: src/xine-engine/demux.c
--- src/xine-engine/demux.c.orig
+++ src/xine-engine/demux.c
@@ -131,7 +131,7 @@ static struct timespec _x_compute_interval(unsigned in
   ui.QuadPart  += millisecs * 10000;
   ts.tv_sec = ui.QuadPart / 10000000;
   ts.tv_sec = (ui.QuadPart % 10000000)*100;
-#elif _POSIX_TIMERS > 0
+#elif _POSIX_TIMERS > 0 || defined(__OpenBSD__)
   clock_gettime(CLOCK_REALTIME, &ts);
   uint64_t ttimer = (uint64_t)ts.tv_sec*1000 + ts.tv_nsec/1000000 + millisecs;
   ts.tv_sec = ttimer/1000;
