X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=aclocal.m4;h=4b750ef3f2982d12963b450997ad9b28e74c595d;hp=c7002b171fff836b62867b37fe4e85587848dd9c;hb=6f66d02c9654fc037db0582857acdcc15e0fd1d3;hpb=4c452d125983172e55075c457b745289afd72d0e diff --git a/aclocal.m4 b/aclocal.m4 index c7002b1..4b750ef 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1494,6 +1494,21 @@ case "$1" in esac ]) +# BOOTSTRAPPING_GHC_INFO_FIELD +# -------------------------------- +# If the bootstrapping compiler is >= 7.1, then set the variable +# $1 to the value of the ghc --info field $2. Otherwise, set it to +# $3. +AC_DEFUN([BOOTSTRAPPING_GHC_INFO_FIELD],[ +if test $GhcCanonVersion -ge 701 +then + $1=`"$WithGhc" --info | grep "^ ,(\"$2\"," | sed -e 's/.*","//' -e 's/")$//'` +else + $1=$3 +fi +AC_SUBST($1) +]) + # LIBRARY_VERSION(lib) # -------------------------------- # Gets the version number of a library.