Skip to content
Snippets Groups Projects
Commit 454deed8 authored by pierre-luc's avatar pierre-luc
Browse files

[#1869] Conditional compilation that checks if

dbus_g_proxy_set_default_timeout is present (since version 0.75).
parent d0a5d89a
No related branches found
No related tags found
No related merge requests found
...@@ -46,6 +46,8 @@ fi ...@@ -46,6 +46,8 @@ fi
AC_SUBST(LIBSEXY_CFLAGS) AC_SUBST(LIBSEXY_CFLAGS)
AC_SUBST(LIBSEXY_LIBS) AC_SUBST(LIBSEXY_LIBS)
PKG_CHECK_MODULES(DBUSGLIB, dbus-glib-1 >= 0.75, HAVE_DBUS_G_PROXY_SET_DEFAULT_TIMEOUT=true, HAVE_DBUS_G_PROXY_SET_DEFAULT_TIMEOUT=false);
PKG_CHECK_MODULES(DEPS, \ PKG_CHECK_MODULES(DEPS, \
dbus-glib-1 >= 0.35 \ dbus-glib-1 >= 0.35 \
libnotify >= 0.4 \ libnotify >= 0.4 \
......
...@@ -18,6 +18,7 @@ ...@@ -18,6 +18,7 @@
* along with this program; if not, write to the Free Software * along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/ */
#include <config.h>
#include <calltab.h> #include <calltab.h>
#include <callmanager-glue.h> #include <callmanager-glue.h>
...@@ -393,9 +394,11 @@ dbus_connect () ...@@ -393,9 +394,11 @@ dbus_connect ()
"errorAlert", G_CALLBACK(error_alert), NULL, NULL); "errorAlert", G_CALLBACK(error_alert), NULL, NULL);
/* Defines a default timeout for the proxies */ /* Defines a default timeout for the proxies */
#if HAVE_DBUS_G_PROXY_SET_DEFAULT_TIMEOUT
dbus_g_proxy_set_default_timeout(callManagerProxy, DEFAULT_DBUS_TIMEOUT); dbus_g_proxy_set_default_timeout(callManagerProxy, DEFAULT_DBUS_TIMEOUT);
dbus_g_proxy_set_default_timeout(instanceProxy, DEFAULT_DBUS_TIMEOUT); dbus_g_proxy_set_default_timeout(instanceProxy, DEFAULT_DBUS_TIMEOUT);
dbus_g_proxy_set_default_timeout(configurationManagerProxy, DEFAULT_DBUS_TIMEOUT); dbus_g_proxy_set_default_timeout(configurationManagerProxy, DEFAULT_DBUS_TIMEOUT);
#endif
return TRUE; return TRUE;
} }
......
...@@ -31,7 +31,6 @@ ...@@ -31,7 +31,6 @@
#include <sys/poll.h> #include <sys/poll.h>
#include <sys/time.h> #include <sys/time.h>
#include <unistd.h> #include <unistd.h>
#include <cstdio>
#include <dbus/dbus.h> #include <dbus/dbus.h>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment