blob: 6a958b3aaf5a40eb4161d1a1ba6eb20fda73b032 [file] [log] [blame]
From 13585fbbe83eb177b13d86c2d6f11ff41a68d07e Mon Sep 17 00:00:00 2001
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Date: Tue, 10 Nov 2020 18:20:24 +0100
Subject: [PATCH] configure.ac: fix cross-compilation
Use AC_COMPILE_IFELSE as AC_RUN_IFELSE raises a build failure when
cross-compiling
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
[Retrieved from:
https://github.com/rpm-software-management/rpm/commit/13585fbbe83eb177b13d86c2d6f11ff41a68d07e]
---
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index 38d3c286a..a83016449 100644
--- a/configure.ac
+++ b/configure.ac
@@ -175,11 +175,11 @@ AS_IF([test "x$ac_cv_prog_c_openmp" != x &&
old_CFLAGS=$CFLAGS
CFLAGS="$CFLAGS $OPENMP_CFLAGS"
AC_MSG_CHECKING([OpenMP is at least version 4.5])
- AC_RUN_IFELSE(
+ AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM(
[#include <omp.h>],
[#if _OPENMP < 201511
- exit(1);
+ #error
#endif
]
)],