1 # add_str_const(name, value)
3 PSI_CONSTS="{PSI_T_STRING, \"string\", \"psi\\\\$1\", $2, PSI_T_QUOTED_STRING}, $PSI_CONSTS"
5 # add_int_const(name, value)
7 PSI_CONSTS="{PSI_T_INT, \"int\", \"psi\\\\$1\", \"$2\", PSI_T_NUMBER}, $PSI_CONSTS"
9 dnl PSI_CONST(const name, type)
11 AC_CACHE_CHECK(value of $1, psi_cv_const_$1, [
15 if test "$cross_compiling" = "yes"
17 AC_TRY_CPP(PSI_INCLUDES $1, psi_const_val=`eval "$ac_try|tail -n1"`, psi_const_val=)
19 PSI_COMPUTE_STR(psi_const_val, $1, PSI_INCLUDES)
23 AC_COMPUTE_INT(psi_const_val, $1, PSI_INCLUDES)
26 psi_cv_const_$1=$psi_const_val
28 if test "$psi_cv_const_$1"
32 add_str_const "$1" "$psi_cv_const_$1"
35 add_int_const "$1" "$psi_cv_const_$1"