add a dist target to jam
[supertux.git] / autogen.sh
1 #!/bin/sh
2
3 # Correct working directory?
4 if test ! -f configure.ac ; then
5   echo "*** Please invoke this script from directory containing configure.ac."
6   exit 1
7 fi
8
9 autoheader
10 libtoolize --force
11 aclocal -I mk/autoconf
12
13 # generate Jamconfig.in
14 autoconf --trace=AC_SUBST \
15   | sed -e 's/configure.ac:[0-9]*:AC_SUBST:\([^:]*\).*/\1 ?= "@\1@" ;/g' \
16   > Jamconfig.in
17 sed -e 's/.*BACKSLASH.*//' -i Jamconfig.in
18 echo 'INSTALL ?= "@INSTALL@" ;' >> Jamconfig.in
19 echo 'JAMCONFIG_READ = yes ;' >> Jamconfig.in
20
21 # we need a minimum of automake 1.6 and automake 1.8 seems to be buggy
22 # this doesn't seem to work well
23 # see AUTOMAKE_OPTIONS in Makefile.am
24 export WANT_AUTOMAKE=1.6
25
26 automake --copy --add-missing
27 autoconf
28