6 # Copyright (C) 2008 Francesco Salvestrini
8 # This program is free software; you can redistribute it and/or modify
9 # it under the terms of the GNU General Public License as published by
10 # the Free Software Foundation; either version 2 of the License, or
11 # (at your option) any later version.
13 # This program is distributed in the hope that it will be useful,
14 # but WITHOUT ANY WARRANTY; without even the implied warranty of
15 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 # GNU General Public License for more details.
18 # You should have received a copy of the GNU General Public License along
19 # with this program; if not, write to the Free Software Foundation, Inc.,
20 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
26 # Dump some useful informations
28 echo "$PROGNAME: Dumping build-tools information ..."
29 for tool
in autoheader autoconf libtool libtoolize aclocal automake
; do
30 TOOLVER
=`$tool --version | head -1`
31 echo "$PROGNAME: $TOOLVER"
35 # Remove files left from the previous run
37 echo "$PROGNAME: Removing autotools related files and directories ..."
38 rm -f `find ./ -name "Makefile.in"` ||
exit 1
39 rm -f config.cache aclocal.
m4 config.h.
in configure ||
exit 1
40 rm -f config.guess config.sub ltmain.sh ||
exit 1
41 rm -rf autom4te.cache ||
exit 1
42 rm -rf `find ./ -name ".deps"` ||
exit 1
47 echo "$PROGNAME: Building configure.ac from configure.ac.in"
49 VERSION
=`git tag -l | sort -s -t '.' -k 1,1n -k 2,2n -k 3,3n | tail -n 1`
50 cat configure.ac.
in |
sed -e 's,[@]VERSION[@],'$VERSION',' > configure.ac || \
51 { rm -f configure.ac
; exit 1 ; }
52 chmod a-w configure.ac
57 echo "$PROGNAME: Handling autotools bootstrap ..."
59 echo "$PROGNAME: Running autoreconf ..."
60 aclocal
--force --install -I .
/tools
/autotools
/m4 && \
61 autoreconf
--verbose --force --install -Wall ||
{