1*cb63e24eSchristos# DEJAGNU_CHECK_VERSION DEJAGNU_CHECK_VERSION 2*cb63e24eSchristos# -------------------------------------------------------------- 3*cb63e24eSchristos# Test whether there is an incompatibility between DejaGnu and GCC versions. 4*cb63e24eSchristos# Older versions ( <= 1.5.1 ) of dejagnu.h use GNU inline semantics improperly. 5*cb63e24eSchristos# The issue presents itself as link-time errors complaining about undefined 6*cb63e24eSchristos# references to 'pass' and 'fail'. 7*cb63e24eSchristosAC_DEFUN([DEJAGNU_CHECK_VERSION], 8*cb63e24eSchristos[ 9*cb63e24eSchristos AC_MSG_CHECKING([for incompatibility between DejaGnu and GCC]) 10*cb63e24eSchristos AC_MSG_RESULT([$ac_cv_dejagnu_compat]) 11*cb63e24eSchristos 12*cb63e24eSchristos AC_TRY_LINK([#include <dejagnu.h>], 13*cb63e24eSchristos [pass ("test foo"); 14*cb63e24eSchristos return 0;], 15*cb63e24eSchristos [ac_cv_dejagnu_compat=yes], 16*cb63e24eSchristos [ac_cv_dejagnu_compat=no]) 17*cb63e24eSchristos AC_MSG_RESULT([$ac_cv_dejagnu_compat]) 18*cb63e24eSchristos 19*cb63e24eSchristos if test "$ac_cv_dejagnu_compat}" = no ; then 20*cb63e24eSchristos AC_MSG_RESULT([detected incompatibility between dejagnu version and gcc]) 21*cb63e24eSchristos fi 22*cb63e24eSchristos]) 23