Support automake newer than 1.11.
[lxde/lxde-icon-theme.git] / autogen.sh
CommitLineData
10f5140a
HJYP
1#! /bin/sh
2AC_VERSION=
3
4AUTOMAKE=${AUTOMAKE:-automake}
5AM_INSTALLED_VERSION=$($AUTOMAKE --version | sed -e '2,$ d' -e 's/.* \([0-9]*\.[0-9]*\).*/\1/')
6
c490d0f9
AG
7case "$AM_INSTALLED_VERSION" in
8 1.1[0-9])
9 ;;
10 *)
10f5140a 11 echo
c490d0f9 12 echo "You must have automake 1.10 or newer installed to build this."
10f5140a
HJYP
13 echo "Install the appropriate package for your distribution,"
14 echo "or get the source tarball at http://ftp.gnu.org/gnu/automake/"
15 exit 1
c490d0f9
AG
16 ;;
17esac
10f5140a 18
c490d0f9 19set -ex
10f5140a
HJYP
20
21if [ "x${ACLOCAL_DIR}" != "x" ]; then
22 ACLOCAL_ARG=-I ${ACLOCAL_DIR}
23fi
24
25${ACLOCAL:-aclocal$AM_VERSION} ${ACLOCAL_ARG}
26$AUTOMAKE --add-missing --copy --include-deps
27${AUTOCONF:-autoconf$AC_VERSION}
28
29rm -rf autom4te.cache