diff --git a/tests/test-runner/bin/test-runner.py.in b/tests/test-runner/bin/test-runner.py.in index d2b455180a1f..bbabf247c1dc 100755 --- a/tests/test-runner/bin/test-runner.py.in +++ b/tests/test-runner/bin/test-runner.py.in @@ -58,10 +58,12 @@ class timespec(ctypes.Structure): ('tv_nsec', ctypes.c_long) ] + librt = ctypes.CDLL('librt.so.1', use_errno=True) clock_gettime = librt.clock_gettime clock_gettime.argtypes = [ctypes.c_int, ctypes.POINTER(timespec)] + def monotonic_time(): t = timespec() if clock_gettime(CLOCK_MONOTONIC_RAW, ctypes.pointer(t)) != 0: