diff --git a/autogen.sh b/autogen.sh index e5c0058..1919d2f 100755 --- a/autogen.sh +++ b/autogen.sh @@ -13,22 +13,49 @@ PKG_NAME="swe-glib" exit 1 } +m4dir=`grep '^AC_CONFIG_MACRO_DIR' configure.ac | sed -n -e 's/AC_CONFIG_MACRO_DIR(\([^()]*\))/\1/p' | sed -e 's/^\[\(.*\)\]$/\1/' | sed -e 1q` +if [ -n "$m4dir" ]; then + m4dir="-I $m4dir" +fi + +echo "Running libtoolize" +libtoolize --force --copy || exit $? + +echo "Running autopoint" +autopoint --force || exit $? + +echo "Running intltoolize" +intltoolize --force --copy --automake || exit $? + GTKDOCIZE=$(which gtkdocize 2>/dev/null) if test -z $GTKDOCIZE; then - echo "You don't have gtk-doc installed, and thus won't be able to generate the documentation." - rm -f gtk-doc.make - cat > gtk-doc.make < gtk-doc.make </dev/null; then + echo "Running autoheader" + autoheader || exit $? + # this prevents automake from thinking config.h.in is out of + # date, since autoheader doesn't touch the file if it doesn't + # change. + test -f config.h.in && touch config.h.in +fi + +echo "Running automake" +automake --gnu --add-missing --copy -Wno-portability || exit $? diff --git a/configure.ac b/configure.ac index 21df532..33192e8 100644 --- a/configure.ac +++ b/configure.ac @@ -40,9 +40,9 @@ AM_GNU_GETTEXT_VERSION([0.17]) LT_INIT AC_CHECK_LIB([m], [atan]) m4_ifdef([GTK_DOC_CHECK], [ - GTK_DOC_CHECK([1.19], [--flavour no-tmpl]) +GTK_DOC_CHECK([1.19], [--flavour no-tmpl]) ],[ - AM_CONDITIONAL([ENABLE_GTK_DOC], false) +AM_CONDITIONAL([ENABLE_GTK_DOC], false) ]) GOBJECT_INTROSPECTION_CHECK([1.0]) PKG_PROG_PKG_CONFIG