From 9378b6fa7b4bc4a9e29e378cdb9bdf1a5d7a8083 Mon Sep 17 00:00:00 2001 From: Sean Bright Date: Tue, 15 Sep 2009 20:03:45 +0000 Subject: Copy bootstrap.sh from asterisk trunk and update to work here. git-svn-id: http://svn.asterisk.org/svn/dahdi/tools/trunk@7138 a0bf4364-ded3-4de4-8d8a-66a801d63aff --- bootstrap.sh | 43 +++++++++++++++++++++++++++++++++---------- 1 file changed, 33 insertions(+), 10 deletions(-) diff --git a/bootstrap.sh b/bootstrap.sh index b26b828..570d66c 100755 --- a/bootstrap.sh +++ b/bootstrap.sh @@ -9,17 +9,40 @@ check_for_app() { fi } -AUTOCONF_VERSION=2.59 -AUTOMAKE_VERSION=1.9 -export AUTOCONF_VERSION -export AUTOMAKE_VERSION +# On FreeBSD and OpenBSD, multiple autoconf/automake versions have different names. +# On linux, envitonment variables tell which one to use. + +uname -s | grep -q BSD +if [ $? = 0 ] ; then # BSD case + case `uname -sr` in + 'FreeBSD 4'*) # FreeBSD 4.x has a different naming + MY_AC_VER=259 + MY_AM_VER=19 + ;; + *) + MY_AC_VER=-2.62 + MY_AM_VER=-1.9 + ;; + esac +else # linux case + MY_AC_VER= + MY_AM_VER= + AUTOCONF_VERSION=2.60 + AUTOMAKE_VERSION=1.9 + export AUTOCONF_VERSION + export AUTOMAKE_VERSION +fi + +check_for_app autoconf${MY_AC_VER} +check_for_app autoheader${MY_AC_VER} +check_for_app automake${MY_AM_VER} +check_for_app aclocal${MY_AM_VER} -check_for_app autoconf -check_for_app automake -check_for_app aclocal echo "Generating the configure script ..." -aclocal 2>/dev/null -autoconf -automake --add-missing --copy 2>/dev/null + +aclocal${MY_AM_VER} +autoconf${MY_AC_VER} +autoheader${MY_AC_VER} +automake${MY_AM_VER} --add-missing --copy 2>/dev/null exit 0 -- cgit v1.2.3