This forum has been archived. All content is frozen. Please use KDE Discuss instead.

kdenlive 16.04 inside chroot: runs fine, windows not drawn

Tags: None
(comma "," separated)
lmichaels
Registered Member
Posts
15
Karma
0
Hello

Followed instructions to install a basic Ubuntu 16.04 environment inside a schroot.

Installed Ubuntu packages for MLT and ffmpeg, as well as the dependencies listed (https://community.kde.org/Kdenlive/Development/KF5).

Downloaded most recent version of kdenlive source from git and followed steps (https://kdenlive.org/download-source#kdenlive) to compile it.

Compiled and installed without errors.

When I try to start kdenlive inside the schroot it outputs to the terminal:

Code: Select all
Non KDE Desktop detected, forcing Breeze icon theme
---
[long list of supported formats]


and opened up a window telling me "Welcome to Kdenlive 16.11.70, using MLT 6.0.0" and shows me three warnings about missing apps (dvdauthor genisoimage/mkisofs and vlc). I click "OK" and it "draws" the borders of a main window but the contents of window itself are empty. It additionall prints out to the terminal:

Code: Select all
"This is a beta version. Always backup your data"
Removing cache at "/home/l/.cache/kdenlive-thumbs.kcache"
shm_open() failed: Function not implemented
shm_open() failed: Function not implemented


kdenlive continues running, it is just failing to display anything inside the window.

How can I fix this? Is it related to the schroot environment? In any case, the initial dialog (about the three missing apps, etc.) displays just fine. Is it drawn in a different way than the main kdenlive window?
lmichaels
Registered Member
Posts
15
Karma
0
I have just noticed that while running
Code: Select all
cmake .. -DCMAKE_INSTALL_PREFIX=$INSTALL_PREFIX


the configure script complained at the very top about:


Code: Select all
-- Could NOT find KF5XmlGui , checked the following files:
    /usr/lib/x86_64-linux-gnu/cmake/KF5XmlGui/KF5XmlGuiConfig.cmake (version 5.18.0)


Might this be related? However, I seem to have all the relevant packages installed:

Code: Select all
# aptitude search xmlgui
i A libkf5xmlgui-bin                                                            - User configurable main windows.                                                       
i A libkf5xmlgui-data                                                           - User configurable main windows.                                                       
i   libkf5xmlgui-dev                                                            - User configurable main windows.                                                       
i A libkf5xmlgui5                                                               - User configurable main windows.                                                       
p   libkf5xmlgui5-dbg                                                           - User configurable main windows.         
vpinon
KDE Developer
Posts
708
Karma
6
OS
chroot instructions are a bit outdated : xenial could be used instead of vivid, which provides old frameworks version... but this shouldn't be the problem.

then do you use the "schroot" command (using desktop profile) to start your sandbox?
I believe this should open the bridge for shared memory (shm)

and do you confirm that your aptitude command is from the chroot?

I really have to provide appimage archives, but still no time for that sorry :-\
lmichaels
Registered Member
Posts
15
Karma
0
Thank you for reading my message.

Regarding the schroot:

Contents of /etc/schroot/chroot.d/xenial.conf:

Code: Select all
[xenial]
aliases=default
description=xenial
type=directory
directory=/VMs/kdenlive
preserve-environment=true
script-config=desktop/config


I start by running:

l@l:~$ schroot -p -c xenial
W: line 7 [xenial]: Deprecated key ‘script-config’ used
I: This option will be removed in the future; please update your configuration
(xenial)me@laptop:~$

The aptitude command is being run inside the chroot:

(xenial)root@laptop:~# aptitude search xmlgui
i A libkf5xmlgui-bin - User configurable main windows.
i A libkf5xmlgui-data - User configurable main windows.
i libkf5xmlgui-dev - User configurable main windows.
i A libkf5xmlgui5 - User configurable main windows.
i libkf5xmlgui5-dbg - User configurable main windows.

After having read your reference to shm, I tried uncommenting the following lines in /etc/schroot/desktop/fstab:

/run /run none rw,bind 0 0
/run/lock /run/lock none rw,bind 0 0
/dev/shm /dev/shm none rw,bind 0 0
/run/shm /run/shm none rw,bind 0 0

but it didn't change the behavior I described above.
lmichaels
Registered Member
Posts
15
Karma
0
I wonder if the clue might lie in the fact that the first splash screen displays just fine ("Welcome to kdenlive", missing apps, etc.) but the main window doesn't.

If I delete ~/.config/kdenliverc and run kdenlive again, the spash screen invariably shows up and gets drawn just fine. The main window however doesn't get drawn.
lmichaels
Registered Member
Posts
15
Karma
0
Two other bits of information, in case they are of use:

1) By mistake, I just started kdenlive inside the schroot as root and... it worked fine even after the splash screen! So everything seems to be in place for it to work. But what is keeping it from working as a regular user?

2) Looking around for anything related to /run and shm, I remembered I had manually created the dir /run/user/1000 inside the chroot (and set it to be owned by my user) because, before I did so, kdenlive would complain about:

Code: Select all
QStandardPaths: wrong ownership on runtime directory /run/user/1000, -2 instead of 1000


I have now removed this dir and the behavior is unchanged. Outside the chroot, I notice that there exists a link called /run/user/1000/X11-display that is not visible from within the schroot -- might this be related to the problem?
vpinon
KDE Developer
Posts
708
Karma
6
OS
the chroot config that worked for me at that time, see on the wiki page:

/etc/schroot/chroot.d/vivid.conf:

[vivid]
aliases=default
description=vivid
type=directory
profile=desktop
directory=$CHROOTDIR
users=$USER

note the profile=desktop that bridges many things to use desktop apps, and the users=your_user_name which properly sets access rights...
lmichaels
Registered Member
Posts
15
Karma
0
Thank you for the schroot config. I updated /etc/schroot/chroot.d/xenial.conf to read

Code: Select all
[xenial]
aliases=default
description=xenial
type=directory
profile=desktop
directory=(dir holding chroot environment)
preserve-environment=true
users=(myusername)


The windows still don't draw, the borders show up and the kdenlive process doesn't crash but nothing is visible (other than the "Welcome to kdenlive" dialog if I delete ~/.config/kdenliverc).

Output of kdenlive:
Code: Select all
(xenial)username@laptop:~$ kdenlive
"This is a beta version. Always backup your data"
Failed to create secure directory (/run/user/1000/pulse): No such file or directory
Failed to create secure directory (/run/user/1000/pulse): No such file or directory
 


Might it be related to this error messages?

As mentioned earlier, I tried uncommenting the following lines at the end of /etc/schroot/chroot.d/desktop/fstab:

Code: Select all
/run           /run            none    rw,bind         0       0
/run/lock      /run/lock       none    rw,bind         0       0
/dev/shm       /dev/shm        none    rw,bind         0       0
/run/shm       /run/shm        none    rw,bind         0       0


but still get that error message about being unable to create a secure directory.

I tried manually creating /run/user/1000 (inside the chroot) and assigning it to my user

(xenial)username@laptop:~$ sudo mkdir /run/user/1000
(xenial)username@laptop:~$ sudo chown -R username /run/user/1000

those two error messages are gone but kdenlive still can't draw the main window:

(xenial)username@laptop:~$ kdenlive
"This is a beta version. Always backup your data"
Removing cache at "/home/l/.cache/kdenlive-thumbs.kcache"

What might be keeping it from drawing the main window as a non-root user?
lmichaels
Registered Member
Posts
15
Karma
0
I have just installed and tried to run kate (the kde text editor) inside the xenial chroot.

It functions just fine and draws all the windows (both dialogs as well as the main window) without problems.

Might this help narrow down the problem?


Bookmarks



Who is online

Registered users: bancha, Bing [Bot], daret, Evergrowing, Google [Bot], lockheed, sandyvee, Sogou [Bot]