maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   dbus scratchbox problem (https://talk.maemo.org/showthread.php?t=14928)

v-v 2008-01-12 16:08

dbus scratchbox problem
 
Hello, when trying to do a:
Code:

GtkWidget* OpenDialog;
OpenDialog = hildon_file_chooser_dialog_new  (GTK_WINDOW(window), GTK_FILE_CHOOSER_ACTION_OPEN);

I get:
Code:

process 25084: 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
then I tried to do a dbus-uuidgen --ensure resulting in the following error:
Code:

Couldn't get main dbus connection: Failed to execute dbus-launch to autolaunch D-Bus session
qemu: uncaught target signal 4 (Illegal instruction) - exiting.

Next, I tried a dbus-launch and dbus-cleanup-sockets that said: Cleaned up 0 sockets in /var/tmp; 0 sockets are still in use; 0 in unknown state
The error i get now is:
Code:

qemu: Unsupported syscall: 264
qemu: uncaught target signal 11 (Segmentation fault) - exiting

The same thing happens not only with my code but also with maemopad if I try to do a File->Open.
The code works well on my n800 with os2008, I'm getting this problem only in scratchbox.

Any idea how to solve this?

Thank you very much :)

pipeline 2008-01-13 14:43

Re: dbus scratchbox problem
 
How are you launching the app? Have you tried launching like this :
run-standalone.sh ./myapp

I think that sets up some environment variables which dbus might be needing.

v-v 2008-01-13 20:45

Re: dbus scratchbox problem
 
yup, I'm lunching it with run-standalone.sh all the time :/
(OK, I tried without it, now, but it's acting the same)

cripes 2008-01-13 21:50

Re: dbus scratchbox problem
 
assume you also ran "af-sb-init.sh start" before you began?

v-v 2008-01-14 00:15

Re: dbus scratchbox problem
 
Yes of course :)
As I said File->Open in MaemoPad under the emulator doesn't work either :/

Maybe the errors when starting it could help:
Code:

[sbox-CHINOOK_ARMEL: ~] >export DISPLAY=:2
[sbox-CHINOOK_ARMEL: ~] > af-sb-init.sh start
Note: For remote X connections DISPLAY should contain hostname!
Sample files present.
Starting DBUS system bus
Starting D-BUS session bus daemon
Starting Maemo Launcher: maemo-launcher.
defender: died my parent is not who he claims to be
maemo-launcher: error rising the oom shield for pid=6414 status=2816
Starting Sapwood image server
Starting Matchbox window manager
Starting clipboard-manager
sapwood-server[6427]: GLIB INFO default - server started
Starting Keyboard
maemo-launcher: invoking '/usr/bin/hildon-input-method.launch'
qemu: Unsupported syscall: 264
qemu: Unsupported syscall: 307
qemu: Unsupported syscall: 305
mbpixbuf: unable to use XShm. DISPLAY remote?
qemu: Unsupported syscall: 306
qemu: Unsupported syscall: 308
Starting Hildon Desktop
maemo-launcher: invoking '/usr/bin/hildon-desktop.launch'
qemu: Unsupported syscall: 264
[sbox-CHINOOK_ARMEL: ~]

The other things works just fine, there is just this problem with dbus :/
(I can see the GUI of the firmware and I can see the programs running fine, gtk works just fine, exept this :/

cripes 2008-01-14 01:24

Re: dbus scratchbox problem
 
have you tried with the x86 target?

v-v 2008-01-14 13:23

Re: dbus scratchbox problem
 
Quote:

Originally Posted by cripes (Post 127087)
have you tried with the x86 target?

Ok, I tried setting up a x86 target and it works :)

Could you explain why it's so? Do I need to change targets all the time when compiling for the emulator or for the Nokia or dbus should normally work with an armel target too?

Many thanks :)

free 2008-01-14 15:52

Re: dbus scratchbox problem
 
From what I understood, x86 target is supposed to work for pretty everything (that doesn't play with low level stuff) and is aimed at UI/Integration testing with the help of an IDE on your PC.
Armel qemu support is not sufficient (?) for running armel GUI apps on your PC. It's only good for building and sending to the device.
For specific d-bus handling I don't know. D-bus by itself could work but everything around, I'm not sure.

v-v 2008-01-14 18:13

Re: dbus scratchbox problem
 
OK, thank you for the help and the explanation :)

jakov 2008-01-28 03:36

Re: dbus scratchbox problem
 
Quote:

Originally Posted by v-v (Post 127401)
Ok, I tried setting up a x86 target and it works :)

Could you explain why it's so? Do I need to change targets all the time when compiling for the emulator or for the Nokia or dbus should normally work with an armel target too?

Many thanks :)

Hi, I have the same problem to you. Then I select the X86 target. But it didn't work.

The difference is my app previously runing on Maemo 3.x well. When I update to maemo 4.0 chinook, modify something such as hildon lib..., compling successfully, but can't run-standalone with it.

The error is:

Code:

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.
  D-Bus not built with -rdynamic so unable to print a backtrace
/usr/bin/run-standalone.sh: line 11:  4462 Aborted                (core dumped) "$@"

Any help is highly appreciated.

Thanks,


All times are GMT. The time now is 14:27.

vBulletin® Version 3.8.8