From df49c60c9671e4a28e636964d744c1f59fb6cb68 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Mon, 12 Jun 2000 15:00:15 +0000 Subject: Merged from 4.5.0-beta3a --- bootstrap | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) (limited to 'bootstrap') diff --git a/bootstrap b/bootstrap index 2672595433..b0af7ca9ec 100755 --- a/bootstrap +++ b/bootstrap @@ -13,6 +13,8 @@ # source tree progname=`basename $0` +top_srcdir=`dirname $0` + verbose=""; quiet="false" mode="generate" @@ -31,9 +33,9 @@ usage() exit 1; } -if test ! -f VERSION; then +if test ! -f $top_srcdir/VERSION; then echo "${progname}:" - echo " Please change directory to RTEMS's toplevel directory" + echo " Installation problem: Can't find file VERSION" exit 1; fi @@ -57,25 +59,31 @@ case $1 in esac done -pwd=`pwd`; - case $mode in generate) - confs=`find $pwd -name 'configure.in' -print` - aclocal_dir=$pwd/aclocal + + case $top_srcdir in + /* ) aclocal_dir=$top_srcdir/aclocal + ;; + *) aclocal_dir=`pwd`/$top_srcdir/aclocal + ;; + esac + + confs=`find . -name 'configure.in' -print` for i in $confs; do dir=`dirname $i`; ( test "$quiet" = "true" || echo "$dir"; cd $dir; aclocal -I $aclocal_dir; autoconf; - test -f Makefile.am && automake $verbose ; test -n "`grep CONFIG_HEADER configure.in`" && autoheader ; + test -f Makefile.am && automake $verbose ; test -f Makefile.am && test -n "`grep 'stamp-h\.in' Makefile.in`" \ && echo timestamp > stamp-h.in ) done ;; + clean) test "$quiet" = "true" || echo "removing automake generated Makefile.in files" files=`find . -name 'Makefile.am' -print | sed -e 's%\.am%\.in%g'` ; -- cgit v1.2.3