aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoredman007 <edman007@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>2009-11-21 18:19:09 +0000
committeredman007 <edman007@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>2009-11-21 18:19:09 +0000
commit973fbdac9163ba98bd5358b9f24bf6f5d5844e34 (patch)
tree9371b9e1495795d0cc430de93f09d6b3de912b0f
parent42d2deefb2977d1ef5e437eb5263f7796002a13d (diff)
downloadlcd4linux-973fbdac9163ba98bd5358b9f24bf6f5d5844e34.tar.gz
Fix the dbus/pkg-config confgure (Now the configure script will probably require pkg-config to be installed)
Defines to compile the dbus plugin are now properly set git-svn-id: https://ssl.bulix.org/svn/lcd4linux/trunk@1069 3ae390bd-cb1e-0410-b409-cd5a39f66f1f
-rw-r--r--configure.in1
-rw-r--r--plugins.m413
2 files changed, 12 insertions, 2 deletions
diff --git a/configure.in b/configure.in
index ef69b35..b1c4b8c 100644
--- a/configure.in
+++ b/configure.in
@@ -39,6 +39,7 @@ AC_PROG_CPP
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PROG_MAKE_SET
+PKG_PROG_PKG_CONFIG
# dmalloc
AM_WITH_DMALLOC
diff --git a/plugins.m4 b/plugins.m4
index 2e211a3..009e28b 100644
--- a/plugins.m4
+++ b/plugins.m4
@@ -249,12 +249,21 @@ fi
#DBus
if test "$PLUGIN_DBUS" = "yes"; then
- PKG_CHECK_MODULES(DBUS, dbus-1, dbus-1 >= 1.0, HAVE_DBUS="yes", HAVE_DBUS="no")
- if test "x$HAVE_DBUS" != "xyes"; then
+ PKG_CHECK_MODULES(DBUS, dbus-1 >= 1.0.0, HAVE_DBUS="yes", HAVE_DBUS="no")
+ if test "x$HAVE_DBUS" == "xyes"; then
PLUGINS="$PLUGINS plugin_dbus.o"
PLUGINLIBS="$PLUGINLIBS $DBUS_LIBS"
CPPFLAGS="$CPPFLAGS $DBUS_CFLAGS"
AC_DEFINE(PLUGIN_DBUS,1,[dbus plugin])
+
+ DBUS_VERSION=$($PKG_CONFIG --modversion dbus-1)
+ DBUS_VERSION_MAJOR=$(echo $DBUS_VERSION | cut -d . -f 1)
+ DBUS_VERSION_MINOR=$(echo $DBUS_VERSION | cut -d . -f 2)
+ DBUS_VERSION_MICRO=$(echo $DBUS_VERSION | cut -d . -f 3)
+
+ AC_DEFINE_UNQUOTED(DBUS_VERSION_MAJOR, $DBUS_VERSION_MAJOR, [DBus Major Version])
+ AC_DEFINE_UNQUOTED(DBUS_VERSION_MINOR, $DBUS_VERSION_MINOR, [DBus Minor Version])
+ AC_DEFINE_UNQUOTED(DBUS_VERSION_MICRO, $DBUS_VERSION_MICRO, [DBus Micro Version])
else
AC_MSG_WARN(dbus-1 not found check that PKG_CONFIG_PATH is set correctly: dbus plugin disabled)
fi