summaryrefslogtreecommitdiff
path: root/autoconf
diff options
context:
space:
mode:
authorJohn Criswell <criswell@uiuc.edu>2003-08-25 16:49:54 +0000
committerJohn Criswell <criswell@uiuc.edu>2003-08-25 16:49:54 +0000
commitde00db210c739353c61539250796e328c7564e3e (patch)
tree280e63b52ea6494d4f4b23d5b64f683a3ab136e7 /autoconf
parentaa8a847c6260483fcdbbfc20093775dd6542f8d6 (diff)
downloadllvm-de00db210c739353c61539250796e328c7564e3e.tar.gz
llvm-de00db210c739353c61539250796e328c7564e3e.tar.bz2
llvm-de00db210c739353c61539250796e328c7564e3e.tar.xz
Added code to check for python and qmtest.
Added code that verifies that GCC is version 3.0 or higher. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8141 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'autoconf')
-rw-r--r--autoconf/configure.ac32
1 files changed, 32 insertions, 0 deletions
diff --git a/autoconf/configure.ac b/autoconf/configure.ac
index 310d3dfeaa..450f50d48d 100644
--- a/autoconf/configure.ac
+++ b/autoconf/configure.ac
@@ -93,6 +93,13 @@ then
AC_MSG_ERROR([g++ required but not found])
fi
+dnl Verify that GCC is version 3.0 or higher
+gccmajor=`$CC --version | head -n 1 | awk '{print $NF;}' | cut -d. -f1`
+if test "$gccmajor" -lt "3"
+then
+ AC_MSG_ERROR([gcc 3.x required])
+fi
+
dnl Check for GNU Make. We use its extensions to, so don't build without it
CHECK_GNU_MAKE
if test -z "$_cv_gnu_make_command"
@@ -108,6 +115,7 @@ dnl Check for libtool
AC_PROG_LIBTOOL
dnl Check for our special programs
+AC_PATH_PROG(RPWD,[pwd])
AC_PATH_PROG(AR,[ar])
AC_PATH_PROG(SED,[sed])
AC_PATH_PROG(RM,[rm])
@@ -118,6 +126,26 @@ AC_PATH_PROG(MV,[mv])
AC_PATH_PROG(DOT,[dot])
AC_PATH_PROG(ETAGS,[etags])
AC_PATH_PROG(PURIFY,[purify])
+AC_PATH_PROG(PYTHON,[python])
+AC_PATH_PROG(QMTEST,[qmtest])
+
+dnl Verify that the version of python available is high enough for qmtest
+pyversion=`$PYTHON -V 2>&1 | cut -d\ -f2`
+pymajor=`echo $pyversion | cut -d. -f1`
+pyminor=`echo $pyversion | cut -d. -f2`
+
+if test "$pymajor" -ge "2"
+then
+ if test "$pymajor" -eq "2"
+ then
+ if test "$pyminor" -lt "2"
+ then
+ AC_MSG_ERROR([Python 2.2 or greater required])
+ fi
+ fi
+else
+ AC_MSG_ERROR([Python 2.2 or greater required])
+fi
dnl Verify that the source directory is valid
AC_CONFIG_SRCDIR(["Makefile.config.in"])
@@ -326,6 +354,10 @@ fi
AC_ARG_WITH(objroot,AC_HELP_STRING([--with-objroot],[Location where object files should be placed (default is .)]),AC_SUBST(OBJROOT,[$withval]))
dnl **************************************************************************
+dnl * Configure other software packages (via AC_CONFIG_SUBDIRS)
+dnl **************************************************************************
+
+dnl **************************************************************************
dnl * Create the output files
dnl **************************************************************************
AC_OUTPUT(Makefile.config)