diff --git a/autogen.sh b/autogen.sh index 9f3a45aaf..7748a3b10 100644 --- a/autogen.sh +++ b/autogen.sh @@ -3,6 +3,7 @@ # Taken from glib CVS # Change the following to match the versions installed on your system +LIBTOOLIZE=libtoolize AUTOCONF=autoconf AUTOHEADER=autoheader AUTOMAKE=automake @@ -38,6 +39,14 @@ FILE=include/hamlib/rig.h DIE=0 +($LIBTOOLIZE --version) < /dev/null > /dev/null 2>&1 || { + echo + echo "You must have libtool installed to compile $PROJECT." + echo "Download the appropriate package for your distribution," + echo "or get the source tarball at ftp://ftp.gnu.org/pub/gnu/" + DIE=1 +} + ($AUTOCONF --version) < /dev/null > /dev/null 2>&1 || { echo echo "You must have autoconf installed to compile $PROJECT." @@ -78,7 +87,7 @@ $ACLOCAL $ACLOCAL_FLAGS # optionally feature autoheader ($AUTOHEADER --version) < /dev/null > /dev/null 2>&1 && $AUTOHEADER -libtoolize --automake --ltdl +$LIBTOOLIZE -c -i --force $AUTOMAKE -a $am_opt $AUTOCONF cd $ORIGDIR diff --git a/configure.ac b/configure.ac index 08fa903df..a6c4151c6 100644 --- a/configure.ac +++ b/configure.ac @@ -24,7 +24,7 @@ AM_MAINTAINER_MODE ABI_VERSION=2 dnl Pick up the Hamlib macros. -AM_ACLOCAL_INCLUDE(macros) +AM_ACLOCAL_INCLUDE([macros]) AC_DEFINE_UNQUOTED(ABI_VERSION, $ABI_VERSION, [Frontend ABI version]) AC_SUBST(ABI_VERSION) @@ -176,22 +176,10 @@ AC_LIBOBJ(dummy) ## ------------------------ ## ## libtool Initialisation. ## ## ------------------------ ## -dnl Enable building of the convenience library -dnl and set LIBLTDL accordingly -AC_LIBLTDL_CONVENIENCE -dnl Substitute INCLTDL and LIBLTDL in the Makefiles -AC_SUBST([INCLTDL]) -AC_SUBST([LIBLTDL]) +LT_CONFIG_LTDL_DIR([libltdl]) +LT_INIT([dlopen], [win32-dll]) +LTDL_INIT([convenience]) -dnl Check for dlopen support -AC_LIBTOOL_WIN32_DLL -AC_LIBTOOL_DLOPEN -dnl Configure libtool -AC_PROG_LIBTOOL -AC_SUBST([LIBTOOL_DEPS]) -AC_LIB_LTDL -dnl Configure libltdl -AC_CONFIG_SUBDIRS(libltdl) case "$host_os" in darwin* | rhapsody*)