From ad3da47dbe3d0f40bd8dcc5d3dd51c95cebb9f38 Mon Sep 17 00:00:00 2001 From: yann-morin-1998 Date: Mon, 9 Oct 2017 11:52:44 +0200 Subject: [PATCH] configure: fix CLOCK_MONOTONIC check for cross-compilation (#269) In cross-compilation, we can't run test programs, so configure just bails out. Since there is no cache variable (e.g. ac_cv_blabla, we can't even provide the correct result. But in thise case, we don't really need to run to start with; we just need to check if the toolchain headers know about CLOCK_MONOTONIC. Signed-off-by: "Yann E. MORIN" --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 22630ba..2d745d8 100644 --- a/configure.ac +++ b/configure.ac @@ -183,7 +183,7 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM( ) AC_MSG_CHECKING(for a working clock_getres(CLOCK_MONOTONIC, &ts)) -AC_RUN_IFELSE([AC_LANG_PROGRAM( +AC_COMPILE_IFELSE([AC_LANG_PROGRAM( [[#include ]], [[struct timespec ts; if(clock_getres(CLOCK_MONOTONIC, &ts)) return -1;]])], [