Module: xenomai-3
Branch: master
Commit: b2a30b28d44b50e9df6615c316e328cb54d083b0
URL:    
http://git.xenomai.org/?p=xenomai-3.git;a=commit;h=b2a30b28d44b50e9df6615c316e328cb54d083b0

Author: Philippe Gerum <r...@xenomai.org>
Date:   Sun Apr  2 11:09:21 2017 +0200

build: replace deprecated AC_TRY_COMPILE()

---

 configure.ac |   15 ++++-----------
 1 file changed, 4 insertions(+), 11 deletions(-)

diff --git a/configure.ac b/configure.ac
index 37b15a0..26a0d5b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -483,17 +483,10 @@ AC_MSG_RESULT(${CONFIG_XENO_VALGRIND_API:-no})
 
 if test \! x$CONFIG_XENO_VALGRIND_API = x ; then
    AC_MSG_CHECKING([whether GCC emits sane code for Valgrind calls])
-   AC_CACHE_VAL(ac_cv_valgrind_client,
-   AC_LANG_SAVE
-   AC_LANG_C
-   save_CFLAGS="$CFLAGS"
-   CFLAGS="-O0"
-   [AC_TRY_COMPILE([#include <valgrind/valgrind.h>],
-   [return RUNNING_ON_VALGRIND;],
-   [ac_cv_valgrind_client=yes],
-   [ac_cv_valgrind_client="no (DISABLING)"])]
-   CFLAGS="$save_CFLAGS"
-   AC_LANG_RESTORE)
+   AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <valgrind/valgrind.h>]],
+                                     [[return RUNNING_ON_VALGRIND;]])],
+                                     [ac_cv_valgrind_client=yes],
+                                     [ac_cv_valgrind_client="no (DISABLING)"])
    if [[ \! "$ac_cv_valgrind_client" = yes ]]; then
       unset CONFIG_XENO_VALGRIND_API
    fi


_______________________________________________
Xenomai-git mailing list
Xenomai-git@xenomai.org
https://xenomai.org/mailman/listinfo/xenomai-git

Reply via email to