bootstrap   [plain text]

#! /bin/sh

# helps bootstrapping libtool, when checked out from CVS
# requires GNU autoconf and GNU automake

find . \( -name autom4te.cache -o -name libtool \) -print | xargs rm -r

: ${ACLOCAL=aclocal}
: ${AUTOMAKE=automake}
: ${AUTOCONF=autoconf}
: ${AUTOHEADER=autoheader}

rm -f acinclude.m4
ln -s libtool.m4 acinclude.m4
# fake the libtool scripts
touch libtoolize
$AUTOMAKE --gnu --add-missing --copy

for sub in libltdl demo depdemo mdemo cdemo; do
  cd $sub
  rm -f acinclude.m4 Makefile
  cat ../libtool.m4 > acinclude.m4
  test "$sub" = libltdl && cat ../ltdl.m4 >> acinclude.m4
  test "$sub" = libltdl && $AUTOHEADER
  $AUTOMAKE --gnits --add-missing
  cd ..

rm -f libtoolize Makefile

exit 0