summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 953bd0f)
raw | patch | inline | side by side (parent: 953bd0f)
author | Bruno Prémont <bonbons@linux-vserver.org> | |
Sun, 5 Oct 2008 12:09:08 +0000 (14:09 +0200) | ||
committer | Florian Forster <octo@huhu.verplant.org> | |
Mon, 6 Oct 2008 12:52:24 +0000 (14:52 +0200) |
The patch below adds check in AC_PLUGIN() that verifies if the
dependencies are met for any enabled plugin.
In case some dependency is missing (default is disabled and enabled
is selected) configure will fail after dumping summary so all
dependency issues are visible in a single configure pass.
A later addition would be to list requirements (dependencies, OS/Kernel
restrictions) for all plugins in an easily accessible location (e.g.
INSTALL file)
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
dependencies are met for any enabled plugin.
In case some dependency is missing (default is disabled and enabled
is selected) configure will fail after dumping summary so all
dependency issues are visible in a single configure pass.
A later addition would be to list requirements (dependencies, OS/Kernel
restrictions) for all plugins in an easily accessible location (e.g.
INSTALL file)
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
configure.in | patch | blob | history |
diff --git a/configure.in b/configure.in
index 8ca5d6913b0ee47507a64e666faa091a252517c2..88b13daa861d0cddd0307d5321d3764e755a4d53 100644 (file)
--- a/configure.in
+++ b/configure.in
enable_plugin="no"
fi
])
- if test "x$enable_plugin" = "xyes"
+ if test "x$enable_plugin" = "xyes" && test "x$2" = "xyes"
then
AC_DEFINE([HAVE_PLUGIN_]my_toupper([$1]), 1, [Define to 1 if the $1 plugin is enabled.])
+ else
+ dependency_error="yes"
+ test "x$enable_plugin" = "xyes" && enable_plugin="failed (missing dependency)"
fi
AM_CONDITIONAL([BUILD_PLUGIN_]my_toupper([$1]), test "x$enable_plugin" = "xyes")
enable_$1="$enable_plugin"
AC_COLLECTD([daemon], [disable], [feature], [daemon mode])
AC_COLLECTD([getifaddrs],[enable], [feature], [getifaddrs under Linux])
+dependency_error="no"
plugin_ascent="no"
plugin_battery="no"
plugin_cpu="no"
xmms . . . . . . . $enable_xmms
EOF
+
+if test "x$dependency_error" = "xyes"; then
+ AC_MSG_ERROR("Some plugins are missing dependencies - see above summary for details")
+fi