summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f331f99)
raw | patch | inline | side by side (parent: f331f99)
author | Sebastian Harl <sh@tokkee.org> | |
Wed, 13 May 2009 09:43:36 +0000 (09:43 +0000) | ||
committer | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Fri, 22 May 2009 15:39:47 +0000 (17:39 +0200) |
The macro LT_PACKAGE_VERSION (which appeared in libtool 2.2) is used to check
weather we're using libtool 2.2.
weather we're using libtool 2.2.
Makefile.am | patch | blob | history | |
configure.in | patch | blob | history |
diff --git a/Makefile.am b/Makefile.am
index b52b0e9309da9fe889237f70034039e231b18928..9e3feac406f152d79e8a0df5ff3fc47367137012 100644 (file)
--- a/Makefile.am
+++ b/Makefile.am
+ACLOCAL_AMFLAGS = -I libltdl/m4
+
SUBDIRS = libltdl src bindings
INCLUDES = $(LTDLINCL)
diff --git a/configure.in b/configure.in
index 2d3d80305a2fa5178e825bedad3b6a3476d929d7..0fd6e78d352edb2600428191e6548a8cbbaddacc 100644 (file)
--- a/configure.in
+++ b/configure.in
AC_INIT(collectd, m4_esyscmd(./version-gen.sh))
AC_CONFIG_SRCDIR(src/collectd.c)
AC_CONFIG_HEADERS(src/config.h)
+
+m4_ifdef([LT_PACKAGE_VERSION],
+ # libtool >= 2.2
+ [
+ LT_CONFIG_LTDL_DIR([libltdl])
+ LT_INIT([dlopen])
+ LTDL_INIT([convenience])
+ ]
+,
+ # libtool <= 1.5
+ [
+ AC_LIBLTDL_CONVENIENCE
+ AC_SUBST(LTDLINCL)
+ AC_SUBST(LIBLTDL)
+ AC_LIBTOOL_DLOPEN
+ AC_CONFIG_SUBDIRS(libltdl)
+ ]
+)
+
AM_INIT_AUTOMAKE(dist-bzip2)
AC_LANG(C)
AM_PROG_CC_C_O
AM_CONDITIONAL(COMPILER_IS_GCC, test "x$GCC" = "xyes")
-dnl configure libtool
AC_DISABLE_STATIC
-AC_LIBLTDL_CONVENIENCE
-AC_SUBST(LTDLINCL)
-AC_SUBST(LIBLTDL)
-AC_LIBTOOL_DLOPEN
AC_PROG_LIBTOOL
AC_PROG_LEX
AC_PROG_YACC
PKG_PROG_PKG_CONFIG
-AC_CONFIG_SUBDIRS(libltdl)
AC_MSG_CHECKING([for kernel type ($host_os)])
case $host_os in