--- configure.ac +++ configure.ac @@ -30,7 +30,10 @@ AC_SUBST(PACKAGE_RELEASE,1) dnl keep A AC_CONFIG_HEADER([config.h]) AC_CONFIG_SRCDIR([backend/epkowa.c]) +dnl Detect old libtool +m4_ifndef([LT_OUTPUT], [ AC_CONFIG_SUBDIRS([libltdl]) +]) AM_INIT_AUTOMAKE([gnu 1.7]) @@ -196,10 +199,10 @@ dnl The somewhat obscure LT_AC_PROG_SED dnl SED environment variable gets set before it's used by the libtool dnl machinery. This works around buggy libtool versions. LT_AC_PROG_SED -AC_LIB_LTDL AC_LIBLTDL_CONVENIENCE AC_LIBTOOL_DLOPEN AC_PROG_LIBTOOL +AC_LIB_LTDL AC_SUBST(LTDLINCL) AC_SUBST(LIBLTDL) --- lib/imgstream.cc +++ lib/imgstream.cc @@ -211,6 +211,17 @@ int selector (const dirent *); imgstream::dl_handle imgstream::find_dlopen (const char *libname) { +// forward compatibility +#ifndef LTDL_SHLIB_EXT +#define LTDL_SHLIB_EXT LT_MODULE_EXT +#endif +#ifndef LTDL_SHLIBPATH_VAR +#define LTDL_SHLIBPATH_VAR LT_MODULE_PATH_VAR +#endif +#ifndef LTDL_SYSSEARCHPATH +#define LTDL_SYSSEARCHPATH LT_DLSEARCH_PATH +#endif + using std::bad_alloc; dl_handle result = NULL;