X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=aclocal.m4;h=a280ecb4293a243829e887798a76091ada9e78d9;hb=845db8182942e006a9164e41e9839adb39f24268;hp=eac0625c1d2df5dab921d103cd5173d6133a8196;hpb=907d2e9d423a243cac5bc8ea421442de2a54b41b;p=ghc-hetmet.git diff --git a/aclocal.m4 b/aclocal.m4 index eac0625..a280ecb 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -134,43 +134,6 @@ m4_popdef([fp_Cache])[]dnl ])# FP_CHECK_ALIGNMENT -# FP_CHECK_CONST(EXPRESSION, [INCLUDES = DEFAULT-INCLUDES], [VALUE-IF-FAIL = -1]) -# ------------------------------------------------------------------------------- -# Defines CONST_EXPRESSION to the value of the compile-time EXPRESSION, using -# INCLUDES. If the value cannot be determined, use VALUE-IF-FAIL. -AC_DEFUN([FP_CHECK_CONST], -[AS_VAR_PUSHDEF([fp_Cache], [fp_cv_const_$1])[]dnl -AC_CACHE_CHECK([value of $1], fp_Cache, -[FP_COMPUTE_INT([$1], fp_check_const_result, [AC_INCLUDES_DEFAULT([$2])], - [fp_check_const_result=m4_default([$3], ['-1'])]) -AS_VAR_SET(fp_Cache, [$fp_check_const_result])])[]dnl -AC_DEFINE_UNQUOTED(AS_TR_CPP([CONST_$1]), AS_VAR_GET(fp_Cache), [The value of $1.])[]dnl -AS_VAR_POPDEF([fp_Cache])[]dnl -])# FP_CHECK_CONST - - -# FP_CHECK_CONSTS_TEMPLATE(EXPRESSION...) -# --------------------------------------- -# autoheader helper for FP_CHECK_CONSTS -m4_define([FP_CHECK_CONSTS_TEMPLATE], -[AC_FOREACH([fp_Const], [$1], - [AH_TEMPLATE(AS_TR_CPP(CONST_[]fp_Const), - [The value of ]fp_Const[.])])[]dnl -])# FP_CHECK_CONSTS_TEMPLATE - - -# FP_CHECK_CONSTS(EXPRESSION..., [INCLUDES = DEFAULT-INCLUDES], [VALUE-IF-FAIL = -1]) -# ----------------------------------------------------------------------------------- -# List version of FP_CHECK_CONST -AC_DEFUN(FP_CHECK_CONSTS, -[FP_CHECK_CONSTS_TEMPLATE([$1])dnl -for fp_const_name in $1 -do -FP_CHECK_CONST([$fp_const_name], [$2], [$3]) -done -])# FP_CHECK_CONSTS - - # FP_LEADING_UNDERSCORE # --------------------- # Test for determining whether symbol names have a leading underscore. We assume @@ -694,6 +657,19 @@ ifelse($#, [1], [dnl ])dnl +AC_DEFUN(FPTOOLS_GHC_HAS_READLINE, +[AC_CACHE_CHECK([whether ghc has readline package], [fptools_ghc_has_readline], +[if "${GhcPkgCmd-ghc-pkg}" --show-package readline >/dev/null 2>&1; then + fptools_ghc_has_readline='yes'; + GhcHasReadline='YES'; + else + fptools_ghc_has_readline='no'; + GhcHasReadline='NO'; + fi + AC_SUBST(GhcHasReadline) +]) +]) + dnl ** Map an arithmetic C type to a Haskell type. dnl Based on autconf's AC_CHECK_SIZEOF. @@ -1208,22 +1184,4 @@ AC_SUBST([GLUT_CFLAGS]) AC_SUBST([GLUT_LIBS]) ])# FP_CHECK_GLUT - -# FP_EMPTY_STRUCTS -# ---------------- -# Define output variable SUPPORTS_EMPTY_STRUCTS if empty structs are accepted by -# CC. -dnl -AC_DEFUN(FP_EMPTY_STRUCTS, -[AC_CACHE_CHECK(empty struct support, fp_cv_empty_structs, -[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[typedef struct { /* empty */ } StgFoo;]], -[[int i;]])], -[fp_cv_empty_structs=yes], -[fp_cv_empty_structs=no])]) -if test x"$fp_cv_empty_structs" = xyes; then - AC_DEFINE([SUPPORTS_EMPTY_STRUCTS], [1], [Define to 1 if C compiler supports declaration of empty structure types.]) -fi -]) - - # LocalWords: fi