X-Git-Url: https://git.gag.com/?a=blobdiff_plain;f=autogen;h=2e6bf5a19a32bdc5d0896669215420c6d8d9e74b;hb=a6127998ee6dcab6bb034f6ca985b07804a86f9a;hp=2da35923b644bb8df27e54dd38c7fb15c3c6d628;hpb=1194fb66aa28d9929c3f2bef3cc6c1c3f40a60a4;p=debian%2Famanda diff --git a/autogen b/autogen index 2da3592..2e6bf5a 100755 --- a/autogen +++ b/autogen @@ -1,19 +1,46 @@ #! /bin/sh -# rebuilds files generated by autoconf&automake. -# autoconf 2.13 and automake 1.4 or newer are required -# arguments are forwarded to the autoreconf script. +# cd to the directory we're run from cd `dirname $0` -touch config/config.h.in +# if you change this, please also change it in the root Makefile.am +includes="-I . -I config -I config/gettext-macros -I config/gnulib -I config/amanda -I config/macro-archive" + +# clean up +rm -f aclocal.m4 +rm -rf autom4te*.cache +rm -f configure + +die() { + echo x"${@}" | sed s/^x// + exit 1 +} + +echo "See DEVELOPING for instructions on updating:" +echo " * gettext macros" +echo " * gnulib" +echo " * libtool files" -if test x`ls -1t acinclude.m4 2>/dev/null \ - config/acinclude.m4i config/libtool.m4i | - sed 1q` != x"acinclude.m4"; then - rm -f acinclude.m4 - cat config/acinclude.m4i config/libtool.m4i > acinclude.m4 -fi +echo "..creating file lists" +( cd config + for m4dir in amanda gettext-macros gnulib macro-archive; do + echo "## this file is automatically generated by autogen" > "$m4dir/file-list" + for f in $m4dir/*.m4; do echo "EXTRA_DIST += $f" >> "$m4dir/file-list"; done + done -autoreconf --warning=syntax --force ${1+"$@"} + echo "## this file is automatically generated by autogen" > "automake/file-list" + for f in automake/*.am; do echo "EXTRA_DIST += $f" >> "automake/file-list"; done +) + +echo "..aclocal" +aclocal $includes || die "aclocal failed" + +echo "..autoconf" +autoconf || die "autoconf failed" + +echo "..autoheader" +autoheader || die "autoheader failed" +touch config/config.h.in -exit 0 +echo "..automake" +automake --force --copy --warnings=none || die "automake failed"