summaryrefslogtreecommitdiff
path: root/build/buildcheck.sh
diff options
context:
space:
mode:
authorfoobar <sniper@php.net>2002-10-27 19:47:34 +0000
committerfoobar <sniper@php.net>2002-10-27 19:47:34 +0000
commita7e87d2485c08bd52dd3ec1e9215d70b7ddc0086 (patch)
tree7607f6e9c6a1477cf0ef94e24126a05ba2c7bd7b /build/buildcheck.sh
parent939de5b8d34cc9123ec3b56418ada3c7da4cc06a (diff)
downloadphp-git-a7e87d2485c08bd52dd3ec1e9215d70b7ddc0086.tar.gz
We have to require bison version <= 1.30 >= 1.75 since any versions between are broken..
Diffstat (limited to 'build/buildcheck.sh')
-rwxr-xr-xbuild/buildcheck.sh21
1 files changed, 20 insertions, 1 deletions
diff --git a/build/buildcheck.sh b/build/buildcheck.sh
index d3f267c580..0fe90b01c3 100755
--- a/build/buildcheck.sh
+++ b/build/buildcheck.sh
@@ -16,7 +16,7 @@
# | Sascha Schumann <sascha@schumann.cx> |
# +----------------------------------------------------------------------+
#
-# $Id: buildcheck.sh,v 1.19 2002-07-21 13:09:07 sas Exp $
+# $Id: buildcheck.sh,v 1.20 2002-10-27 19:47:34 sniper Exp $
#
echo "buildconf: checking installation..."
@@ -70,6 +70,25 @@ else
echo "buildconf: automake version $am_version (ok)"
fi
+# Bison <= 1.30 or >= 1.75 required (1.35, 1.50 have some bugs)
+bison_version=`bison --version| grep 'GNU Bison' | cut -d ' ' -f 4`
+bison_version_clean=`echo $bison_version|sed -e 's/-p[0-9]*$//'`
+if test "$bison_version" = ""; then
+echo "buildconf: bison not found."
+echo " You need bison version <= 1.30 >= 1.75 installed"
+echo " to build PHP from CVS."
+exit 1
+fi
+IFS=.; set $bison_version_clean; IFS=' '
+if test "$1" = "1" -a "$2" -le "30" || test "$1" = "1" -a "$2" -ge "75"; then
+echo "buildconf: bison version $bison_version (ok)"
+else
+echo "buildconf: bison version $bison_version found."
+echo " You need bison version <= 1.30 >= 1.75 installed"
+echo " to build PHP from CVS."
+exit 1
+fi
+
# libtool 1.4 or newer
# Prefer glibtool over libtool for Mac OS X compatibility
libtool=`which glibtool 2> /dev/null`