From e72a7d183ae3aa4b28f8f032c10b4c15e6be7c59 Mon Sep 17 00:00:00 2001 From: Frank Denis Date: Fri, 16 Aug 2019 12:28:42 +0200 Subject: [PATCH] Use AC_LINK_IFELSE instead of _COMPILE_IFELSE for cpuid detection This apparently works around a bug on OpenSuSE on ARM and PPC when LTO is enabled. Still, as documented, LTO shouldn't be used when compiling the library. --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 88259b75..09f100fe 100644 --- a/configure.ac +++ b/configure.ac @@ -694,7 +694,7 @@ AC_SUBST(HAVE_TI_MODE_V) HAVE_CPUID_V=0 AS_IF([test "$enable_asm" != "no"],[ AC_MSG_CHECKING(for cpuid instruction) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[ ]], [[ unsigned int cpu_info[4]; __asm__ __volatile__ ("xchgl %%ebx, %k1; cpuid; xchgl %%ebx, %k1" : "=a" (cpu_info[0]), "=&r" (cpu_info[1]),