Commit dc5b00ca authored by Keith Preston's avatar Keith Preston

system changes

parent ffcf77ed
......@@ -94,7 +94,7 @@ geoclue_map_class_init (GeoclueMapClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
signals[GET_MAP_FINISHED] =
......
......@@ -92,7 +92,7 @@ geoclue_position_class_init (GeocluePositionClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
......
......@@ -110,7 +110,7 @@ geoclue_geocode_class_init (GeoclueGeocodeClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
if (klass->connection == NULL)
......
......@@ -147,7 +147,7 @@ geoclue_map_class_init (GeoclueMapClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
signals[GET_MAP_FINISHED] =
g_signal_new ("get_map_finished",
......
......@@ -148,7 +148,7 @@ geoclue_position_class_init (GeocluePositionClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
signals[CURRENT_POSITION_CHANGED] =
g_signal_new ("current_position_changed",
......
......@@ -528,7 +528,7 @@ geoclue_position_class_init (GeocluePositionClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
signals[CURRENT_POSITION_CHANGED] =
g_signal_new ("current_position_changed",
......
......@@ -130,7 +130,7 @@ geoclue_position_class_init (GeocluePositionClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
signals[CURRENT_POSITION_CHANGED] =
g_signal_new ("current_position_changed",
......
......@@ -589,7 +589,7 @@ geoclue_position_class_init (GeocluePositionClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
signals[CURRENT_POSITION_CHANGED] =
g_signal_new ("current_position_changed",
......
......@@ -36,8 +36,22 @@ AC_ARG_ENABLE(panel-applet,
AC_ARG_ENABLE(system-bus,
[AC_HELP_STRING([--enable-system-bus],
[Use the system bus instead of session bus])],
enable_system_bus="$enableval",
enable_system_bus=no)
AM_CONDITIONAL(USE_SYSTEM_BUS, test x$enable_system_bus = xyes)
if test x$enable_system_bus = xyes; then
AC_DEFINE(GEOCLUE_DBUS_BUS, DBUS_BUS_SYSTEM, Use the system bus)
else
AC_DEFINE(GEOCLUE_DBUS_BUS, GEOCLUE_DBUS_BUS, Use the session bus)
fi
DBUS_SYSTEM_POLICY_DIR=`pkg-config dbus-1 --variable=sysconfdir`/dbus-1/system.d
AC_SUBST(DBUS_SYSTEM_POLICY_DIR)
PKG_CHECK_MODULES(DEPS, gconf-2.0 dbus-glib-1 gtk+-2.0)
PKG_CHECK_MODULES(DEPS, gconf-2.0 dbus-glib-1 gtk+-2.0 gthread-2.0)
AC_SUBST(DEPS_CFLAGS)
AC_SUBST(DEPS_LIBS)
......
......@@ -100,7 +100,7 @@ GEOCLUE_FIND_RETURNCODE geoclue_find_service_provider(char** name)
GEOCLUE_FIND_RETURNCODE geoclue_find_init_specific(char* service, char* path)
{
GError* error = NULL;
geoclue_find_connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
geoclue_find_connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
if (geoclue_find_connection == NULL)
{
g_printerr ("Failed to open connection to bus: %s\n", error->message);
......@@ -137,7 +137,7 @@ GEOCLUE_FIND_RETURNCODE geoclue_find_init_specific(char* service, char* path)
GEOCLUE_FIND_RETURNCODE geoclue_find_init()
{
GError* error = NULL;
geoclue_find_connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
geoclue_find_connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
if (geoclue_find_connection == NULL)
{
g_printerr ("Failed to open connection to bus: %s\n", error->message);
......@@ -216,7 +216,7 @@ GEOCLUE_FIND_RETURNCODE geoclue_find_get_all_providers(char*** OUT_service, char
GError* error = NULL;
if (geoclue_find_connection == NULL)
{
geoclue_find_connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
geoclue_find_connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
}
DBusGProxy* master = dbus_g_proxy_new_for_name (geoclue_find_connection,
......
......@@ -179,7 +179,7 @@ geoclueserver_master_class_init (GeoclueMasterClass *klass)
{
GError *error = NULL;
klass->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
klass->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
......
......@@ -82,7 +82,7 @@ GEOCLUE_GEOCODE_RETURNCODE geoclue_geocode_service_provider(char** name)
GEOCLUE_GEOCODE_RETURNCODE geoclue_geocode_init()
{
GError* error = NULL;
geoclue_geocode_connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
geoclue_geocode_connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
if (geoclue_geocode_connection == NULL)
{
g_printerr ("Failed to open connection to bus: %s\n", error->message);
......
......@@ -100,7 +100,7 @@ GEOCLUE_MAP_RETURNCODE geoclue_map_service_provider(char** name)
GEOCLUE_MAP_RETURNCODE geoclue_map_init_specific(char* service, char* path)
{
GError* error = NULL;
geoclue_map_connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
geoclue_map_connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
if (geoclue_map_connection == NULL)
{
g_printerr ("GEOCLUE_MAP failed to open connection to bus: %s\n", error->message);
......@@ -137,7 +137,7 @@ GEOCLUE_MAP_RETURNCODE geoclue_map_get_all_providers(char*** OUT_service, char**
if (geoclue_map_connection == NULL)
{
geoclue_map_connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
geoclue_map_connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
}
......@@ -163,7 +163,7 @@ GEOCLUE_MAP_RETURNCODE geoclue_map_get_all_providers(char*** OUT_service, char**
GEOCLUE_MAP_RETURNCODE geoclue_map_init()
{
GError* error = NULL;
geoclue_map_connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
geoclue_map_connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
if (geoclue_map_connection == NULL)
{
g_printerr ("GEOCLUE_MAP failed to open connection to bus: %s\n", error->message);
......
......@@ -71,7 +71,7 @@ position_returncode geoclue_position_init( position_provider* provider )
if(!provider->connection)
{
GError* error = NULL;
provider->connection = dbus_g_bus_get (DBUS_BUS_SESSION, &error);
provider->connection = dbus_g_bus_get (GEOCLUE_DBUS_BUS, &error);
if (!provider->connection)
{
g_printerr ("Failed to open connection to bus: %s\n", error->message);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment