])# FP_PROG_CONTEXT_DIFF
-# FP_DECL_ALTZONE
-# ---------------
-# Defines HAVE_DECL_ALTZONE to 1 if declared, 0 otherwise.
-#
-# Used by base package.
-AC_DEFUN([FP_DECL_ALTZONE],
-[AC_REQUIRE([AC_HEADER_TIME])dnl
-AC_CHECK_HEADERS([sys/time.h])
-AC_CHECK_DECLS([altzone], [], [],[#if TIME_WITH_SYS_TIME
-# include <sys/time.h>
-# include <time.h>
-#else
-# if HAVE_SYS_TIME_H
-# include <sys/time.h>
-# else
-# include <time.h>
-# endif
-#endif])
-])# FP_DECL_ALTZONE
-
-
# FP_COMPUTE_INT(EXPRESSION, VARIABLE, INCLUDES, IF-FAILS)
# --------------------------------------------------------
# Assign VARIABLE the value of the compile-time EXPRESSION using INCLUDES for
fi;
changequote([, ])dnl
])
-FP_COMPARE_VERSIONS([$fptools_cv_happy_version],[-lt],[1.15],
- [AC_MSG_ERROR([Happy version 1.15 or later is required to compile GHC.])])[]dnl
+if test ! -f compiler/parser/Parser.hs || test ! -f compiler/main/ParsePkgConf.hs || test ! -f compiler/cmm/CmmParse.hs || test ! -f compiler/parser/ParserCore.hs
+then
+ FP_COMPARE_VERSIONS([$fptools_cv_happy_version],[-lt],[1.15],
+ [AC_MSG_ERROR([Happy version 1.15 or later is required to compile GHC.])])[]dnl
+fi
HappyVersion=$fptools_cv_happy_version;
AC_SUBST(HappyVersion)
])
dnl
dnl Check for Alex and version. If we're building GHC, then we need
-dnl at least Alex version 2.0. If there's no installed Alex, we look
-dnl for a alex source tree and point the build system at that instead.
+dnl at least Alex version 2.0.1.
dnl
AC_DEFUN([FPTOOLS_ALEX],
[
fi;
changequote([, ])dnl
])
-FP_COMPARE_VERSIONS([$fptools_cv_alex_version],[-lt],[2.0],
- [AC_MSG_ERROR([Alex version 2.0 or later is required to compile GHC.])])[]dnl
+if test ! -f compiler/cmm/CmmLex.hs || test ! -f compiler/parser/Lexer.hs
+then
+ FP_COMPARE_VERSIONS([$fptools_cv_alex_version],[-lt],[2.0.1],
+ [AC_MSG_ERROR([Alex version 2.0.1 or later is required to compile GHC.])])[]dnl
+fi
AlexVersion=$fptools_cv_alex_version;
AC_SUBST(AlexVersion)
])