Re: is dbus-uuidgen --ensure ok in an install script?

2008-09-03 Thread Faheem Pervez
Hi,

I don't think this will help your problem described in your reply but
instead of using dbus-uuidgen, you can use run-standalone.sh name of
program instead.

Maybe a su - user -c 'name of program' may work.

On Tue, Sep 2, 2008 at 7:49 PM, Brad Midgley [EMAIL PROTECTED] wrote:

 Hey

 I have an issue that goes away after running dbus-uuidgen --ensure.
 Is this safe enough to put in a post-install script?

 I'm writing a daemon that needs to be able to keep the tablet awake
 (long story).

 osso_initialize will complete if run from the terminal as user but
 will fail and abort if I sudo gainroot first or if it's run as an
 init.d service. I do seteuid() so we're running as user before making
 the call but it doesn't help. The error message is:

 initializing osso
 process 1669: D-Bus library appears to be incorrectly set up; failed
 to read machine uuid: Failed to open /var/lib/dbus/machine-id:No
 such file or directory
 See the manual page for dbus-uuidgen to correct this issue.

 Should this be filed as a maemo bug?

 --
 Brad
 ___
 maemo-developers mailing list
 maemo-developers@maemo.org
 https://lists.maemo.org/mailman/listinfo/maemo-developers

___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: is dbus-uuidgen --ensure ok in an install script?

2008-09-03 Thread Brad Midgley
Faheem

 I don't think this will help your problem described in your reply but
 instead of using dbus-uuidgen, you can use run-standalone.sh name of
 program instead.

 Maybe a su - user -c 'name of program' may work.

fwiw, both the dbus-uuidgen and run-standalone.sh approaches result in
an execution where osso_initialize returns null.

so actually su - works. It even makes the gps icon appear properly
in the system tray after it's powered up. I'll have to replicate that
programatically since a simple seteuid() obviously doesn't cut it and
I need some root behavior in early execution. Maybe it's something in
the environment.

thanks
-- 
Brad
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


is dbus-uuidgen --ensure ok in an install script?

2008-09-02 Thread Brad Midgley
Hey

I have an issue that goes away after running dbus-uuidgen --ensure.
Is this safe enough to put in a post-install script?

I'm writing a daemon that needs to be able to keep the tablet awake
(long story).

osso_initialize will complete if run from the terminal as user but
will fail and abort if I sudo gainroot first or if it's run as an
init.d service. I do seteuid() so we're running as user before making
the call but it doesn't help. The error message is:

initializing osso
process 1669: D-Bus library appears to be incorrectly set up; failed
to read machine uuid: Failed to open /var/lib/dbus/machine-id:No
such file or directory
See the manual page for dbus-uuidgen to correct this issue.

Should this be filed as a maemo bug?

-- 
Brad
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers


Re: is dbus-uuidgen --ensure ok in an install script?

2008-09-02 Thread Brad Midgley
hmm

fwiw, maybe it's not so simple... turning on the gps from my daemon
doesn't activate the gps status display in the system tray. Is there a
better way to do this stuff from the background?

-- 
Brad
___
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers