blob: ce0e2699e4409e5feb9809949416a3e89bdb4ef6 [file] [log] [blame]
Brian Gaeke4940c572004-02-08 07:44:48 +00001#!/bin/sh
2die () {
3 echo "$@" 1>&2
4 exit 1
5}
Reid Spencerd00b82e2004-12-22 05:56:41 +00006outfile=configure
7configfile=configure.ac
Reid Spencer6843e382004-10-08 05:33:35 +00008test -d autoconf && test -f autoconf/$configfile && cd autoconf
9test -f $configfile || die "Can't find 'autoconf' dir; please cd into it first"
Reid Spencerb03adb82004-09-19 22:14:24 +000010autoconf --version | egrep '2\.59' > /dev/null
11if test $? -ne 0 ; then
12 die "Your autoconf was not detected as being 2.59"
13fi
Reid Spencer6843e382004-10-08 05:33:35 +000014aclocal --version | egrep '1\.9\.2' > /dev/null
Reid Spencerb03adb82004-09-19 22:14:24 +000015if test $? -ne 0 ; then
Reid Spencer6bc488b2004-10-13 00:18:58 +000016 die "Your aclocal was not detected as being 1.9.2"
Reid Spencerb03adb82004-09-19 22:14:24 +000017fi
18autoheader --version | egrep '2\.59' > /dev/null
19if test $? -ne 0 ; then
20 die "Your autoheader was not detected as being 2.59"
21fi
Reid Spencer6bc488b2004-10-13 00:18:58 +000022libtool --version | grep '1\.5\.10' > /dev/null
Reid Spencerb03adb82004-09-19 22:14:24 +000023if test $? -ne 0 ; then
24 die "Your libtool was not detected as being 1.5.10"
Brian Gaeke4940c572004-02-08 07:44:48 +000025fi
Reid Spencer8eacb0c2004-09-19 22:30:53 +000026echo ""
27echo "### NOTE: ############################################################"
Reid Spencer5d6c4a52004-09-21 17:13:23 +000028echo "### If you get *any* warnings from autoconf below you MUST fix the"
29echo "### scripts in the m4 directory because there are future forward"
Reid Spencer8eacb0c2004-09-19 22:30:53 +000030echo "### compatibility or platform support issues at risk. Please do NOT"
Reid Spencer6843e382004-10-08 05:33:35 +000031echo "### commit any configure script that was generated with warnings"
32echo "### present. You should get just three 'Regenerating..' lines."
Reid Spencer8eacb0c2004-09-19 22:30:53 +000033echo "######################################################################"
34echo ""
Reid Spencer6bc488b2004-10-13 00:18:58 +000035echo "Regenerating aclocal.m4 with aclocal 1.9.2"
Reid Spencerdcd38752004-09-07 16:00:48 +000036cwd=`pwd`
Reid Spencerb03adb82004-09-19 22:14:24 +000037aclocal --force -I $cwd/m4 || die "aclocal failed"
Reid Spencer6843e382004-10-08 05:33:35 +000038echo "Regenerating configure with autoconf 2.59"
39autoconf --force --warnings=all -o ../$outfile $configfile || die "autoconf failed"
Brian Gaeke4940c572004-02-08 07:44:48 +000040cd ..
Reid Spencer6843e382004-10-08 05:33:35 +000041echo "Regenerating config.h.in with autoheader 2.59"
Reid Spencerabec8f92004-10-27 23:03:44 +000042autoheader --warnings=all -I autoconf -I autoconf/m4 autoconf/$configfile || die "autoheader failed"
Brian Gaeke4940c572004-02-08 07:44:48 +000043exit 0