rc: add nasty tizen work around.
authorIscaro <iscaro@profusion.mobi>
Wed, 5 Sep 2012 23:20:59 +0000 (20:20 -0300)
committerIscaro <iscaro@profusion.mobi>
Wed, 5 Sep 2012 23:28:44 +0000 (20:28 -0300)
we've evaluated all the options, but Tizen is completely nuts and will
run the window manager (e17) as root, while the applications are executed
as user "app". Enlightenment will create its session bus for user "root",
but nothing is done regarding "app".

Then for tizen builds we use the system bus, always.

dialer/rc.c
tizen/answer_daemon.c

index 8195543..4a50dd5 100644 (file)
@@ -344,9 +344,19 @@ Eina_Bool rc_init(const char *service)
                return EINA_FALSE;
        }
 
+#ifdef HAVE_TIZEN
+       /* NOTE: Tizen is stupid and does not have a session bus.  at
+        * least not for user "app". Moreover the dialer is started by
+        * user "root" :-(
+        */
+       INF("Running on System bus");
+       bus_conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
+#else
+       INF("Running on Session bus");
        bus_conn = e_dbus_bus_get(DBUS_BUS_SESSION);
+#endif
        if (!bus_conn) {
-               CRITICAL("Could not get DBus System Bus");
+               CRITICAL("Could not get DBus Bus");
                return EINA_FALSE;
        }
 
index 6fac40c..a62c15c 100644 (file)
@@ -276,7 +276,7 @@ static Eina_Bool _dbus_init(Call_Screen *cs)
        DBusMessage *msg;
        char *bus_name = BUS_NAME;
 
-       bus_conn = e_dbus_bus_get(DBUS_BUS_SESSION);
+       bus_conn = e_dbus_bus_get(DBUS_BUS_SYSTEM);
        if (!bus_conn) {
                ERR("Could not fetch the DBus session");
                return EINA_FALSE;