Run application without a desktop environment

This forum is for discussion about general software issues.

Run application without a desktop environment

Postby anatolik » Tue Mar 15, 2016 5:39 pm

I work on my project's team dashboard. I want to use a Raspberry Pi or similar small computer to show a full-screen GTK app. I just need to run my app and do not need any heavy desktop environments.

I see Kodi has a standalone mode that can run without gnome/kde. I want to do the same. I am looking at service file both for

- x86 https://github.com/graysky2/kodi-standa ... di.service It uses xinit to start the application. It looks reasonable to me.

- then I looked at service file uses for Arch RPi. https://github.com/archlinuxarm/PKGBUIL ... di.service This service is much simpler but it is not clear for me how it starts X server. Tried to make the same service file for my app and it fails saying that X is not initialized. I briefly looked at Kodi sourcecode and do not see where it uses xinit.

Could anyone explain how Kodi is started in standalone DE-less mode at Arch ARM? Do you have other examples of DE-less applications used at ARM Arch Linux.

Thanks.
anatolik
 
Posts: 9
Joined: Tue Mar 15, 2016 5:25 pm

Re: Run application without a desktop environment

Postby pepedog » Tue Mar 15, 2016 7:18 pm

Usually this works
$this->bbcode_second_pass_code('', 'xorg-xinit /path-to-app/apname')
Look at .xinitrc to customise startx
pepedog
Developer
 
Posts: 2431
Joined: Mon Jun 07, 2010 3:30 pm
Location: London UK

Re: Run application without a desktop environment

Postby anatolik » Tue Mar 15, 2016 8:36 pm

$this->bbcode_second_pass_quote('pepedog', 'U')sually this works
$this->bbcode_second_pass_code('', 'xorg-xinit /path-to-app/apname')
Look at .xinitrc to customise startx


Yes, something like this is possible. I googled before asking this questions and most recommendations suggest starting app with xinit/startx. But at this point I am interested to understand how Kodi starts its application without xinit.

I see this package change https://github.com/archlinuxarm/PKGBUIL ... 97d3104aba ARM Kodi removed $this->bbcode_second_pass_code('', 'xinit') call. But the commit message does not tell how Kodi starts X.
anatolik
 
Posts: 9
Joined: Tue Mar 15, 2016 5:25 pm

Re: Run application without a desktop environment

Postby anatolik » Thu Mar 17, 2016 3:56 pm

I can start my application with /usr/bin/xinit /usr/bin/foobar -- :0 -nolisten tcp and it starts fine.

As of RaspberryPI - it looks like Kodi has some direct framebuffer rendering support that allows to bypass Xserver. I asked around and it looks like this direct framebuffer feature is specific to RPi, not many boards allow this. Thus using xserver with xinit is more flexible solution. But if anybody has more information how direct framebuffer rendering is implemented at RPi let me know - I would like to learn more about it.
anatolik
 
Posts: 9
Joined: Tue Mar 15, 2016 5:25 pm


Return to General

Who is online

Users browsing this forum: No registered users and 0 guests