xdg-app and gtkmm

Murray Cumming murrayc at murrayc.com
Wed Dec 9 19:54:37 UTC 2015


On Wed, 2015-12-09 at 14:31 +0100, Alexander Larsson wrote:
> > > After a build, you can debug the app with: 
> > >   xdg-app build app bash
> > > 
> > > then you can from inside the "sandbox" e.g. run prefixsuffix in
> > > gdb,
> > > or
> > > strace it to see what dconf is trying to do.
> > 
> > Thanks. But I don't have the problem when running it like that.
> Only
> > when running it via xdg-app run.
> > 
> > Is there any other way to find out what files it might be trying to
> > access while running under xdg-app run?
> 
> Yes, you can run:
> 
>   xdg-app run --command=bash -d io.github.murraycu.PrefixSuffix
> 
> That will give you a shell in the same kind of sandbox as the app,
> but
> with (from -d) a sdk runtime instead of the regular one.

Thanks. strace there showed me that dconf is indeed trying to open a
"child" profile:

open("/etc/dconf/profile/child", O_RDONLY) = -1 ENOENT (No such file or
directory)
open("/app/share/dconf/profile/child", O_RDONLY) = -1 ENOENT (No such
file or directory)
open("/usr/share/dconf/profile/child", O_RDONLY) = -1 ENOENT (No such
file or directory)


I do actually have a "child" dconf profile set up in my regular
environment, since some experiments I did with lockdown. Sorry, the
generic name didn't remind me that I'd done it:
http://www.murrayc.com/permalink/2015/01/30/locking-down-a-gnome-settin
g/

This error seems to have happened because I still have
DCONF_PROFILE=child set in my environment, which normally makes dconf
use the profile specified in my /etc/dconf/profile/child file. But
there is no /etc/dconf/profile/child  when running under xdg-app. Maybe
DCONF_PROFILE should be unset in the xdg-app environment, if xdg-apps
are not meant to use the same dconf database as the regular system.


-- 
Murray Cumming
murrayc at murrayc.com
www.murrayc.com






More information about the xdg-app mailing list