LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices


Reply
  Search this Thread
Old 05-18-2015, 08:56 AM   #1
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
Lightbulb The Linux From Scratch Desktop Project


Having upgraded to xfce 4.12 I have found that yet again stuff has been broken, apparently by inclusion of dependencies ( runtime or otherwise ) on systemd/gtk3 and I'm fed up with it.
See here:

http://www.linuxquestions.org/questi...vt-4175538803/
http://www.linuxquestions.org/questi...it-4175540203/
And so on!

So I decided to start this little project to get a working desktop just with packages from LFS/BLFS avoiding as much as possible packages that rely on stuff that is constantly broken by the likes of systemd/gtk3, so no polkit/consolekit etc, where possible (B)LFS packages are used, this is not set in stone s there are some glaring omissions from the BLFS book.

If you are NOT using (B)LFS this project will almost certainly not work.

This for a GUI desktop only, NOT the underlying system ( xorg/udev etc ).
Other distributions have their own customised desktop so why not LFS, so the LFSDesktopProject was born!

This software is VERY much alpha software and may not work 'as is' on your set up, so if your computer explodes or the wife runs off with the milkman it's not my fault, you have been warned!

The first objective was to find a replacement composite manager from the one supplied by xfce, I chose compton, there doesn't seem to be a compositing manager in BLFS, compton can be found here:
https://github.com/chjj/compton/rele...3-10-21.tar.xz
It needs libconfig from here:
http://www.hyperrealm.com/libconfig/...g-1.4.9.tar.gz

Building libconfig:
Code:
./configure --prefix=/usr
make
sudo make install
Building compton:
Code:
make
sudo make install
Compton is the successor to xcompmgr which I used for years, is rock solid and has shed loads of config options I use:
Code:
compton  -cC -r15 -o.6 -l5 -t5 --backend glx --glx-no-rebind-pixmap -z
Which isn't too fancy or heavy on system resources.

A compositor of some sort is ESSENTIAL for this desktop.

The first job was to set the the wallpaper for the desktop, I have twin monitors and like to have different images on both, so I wrote the setwallpaper app this can be used as is without any desktop ( even from the basic twm installed with xorg ), if you are using another desktop manager like xfce's xfdesktop you need to quit it BEFORE setwallpaper
Code:
xfdesktop --quit
if your file manager covers the root window you will need to turn that off (pcmanfm does this ).

Download SetWallpaper from here:
https://dl.dropboxusercontent.com/s/...r-0.0.4.tar.gz
Unpack and build:
Code:
./autogen --prefix=/usr
make
sudo make install
Use
Code:
setwallpaper -h
For config options, options are dealt with in first come first served order so to set the image for monitor 1,stretch to fit and then monitor 0 tiled use
Code:
setwallpaper --monitor=1 --monitormode=0 --wallpaper=/home/keithhedger/Wallpapers/311917.jpg --monitor=0  --monitormode=1 --wallpaper=/home/keithhedger/Wallpapers/red.jpg --multimode=1
This code may be folded into the LFSDesktop code at some future date, but for now I 'm keeping it separate as some people don't lke icons etc on their desktop.

The second bit was to make the actual desktop app which can be downloaded from here:
https://dl.dropboxusercontent.com/s/...p-0.0.6.tar.gz
Unpack and build:
Code:
./autogen --prefix=/usr
make
sudo make install
The lfsdesktop app can at the moment use two different backends for mounting disks the default is to use a custom setuid app that just does the mount, you can also use udevil to mount disks ( which again is not in the blfs book ) this allows normal user's to all sorts of different disks as a normal user, it is highly configurable and is a great piece of code available here:

https://nodeload.github.com/Ignorant...vil/zip/master
This is not the place to go into all it's details however, but to use udevil add --disable-suidhelper to configure/autogen.sh

To run lfsdesktop use
Code:
lfsdesktop
You can add the --clean switch which will clear the disk cache, so all disks will appear in the default positions, and/or the --theme switch which will try to display the icons with the selected theme like so
Code:
lfsdesktop --theme gnome
running the command again with a different theme name will restart the desktop and switch to the new theme, use theme names only not path's, if a particular icon cannot be found it will try to use the general hard disk icon from the theme or if that is not available the icon from the default gnome theme.

Disk icons initially appear in a grid, but can be dragged to new positions on the grid these positions are remembered until you use the --clean switch.
Dragging an icon will show a white square as you move the mouse ( click and hold obviously ) snapping to the nearest grid position, just release to move the icon to a new position , you can't drop an icon on another icon.
Double clicking the disk icon will mount the disk and open it in the default app set by xdg-open, this was the easy bit, why does xfce still have so many problems detecting and mounting disks!

All prefs are set via a simple text file in keeping with the UNIX philosophy, they are stored at '~/.config/LFS'
The setwallpaper prefs are updated when the app exits, if something mucks up your root window wallpaper, for instance running xfdesktop and then quiting it will result in a grey screen, just issue the setwallpaper command with no arguments and all the previous settings will be used.
The prefs for lfsdesktop ( such as the are ) are at '~/.config/LFS/lfsdesktop.rc' where you can manually set the icon size etc, these prefs will be folded into the lfsdesktop code as switches later on.

That's about all for now as I said still very alpha software but lot's to add, suggestions welcome, the main one being what toolkit I should use for a settings editor, right click menu etc, I won't use gtk, qt5 is nice but is a BIG compile and a bit of overkill, wxWidgets, well I just don't like them, lesstif seems OK but not a lot of documentation, any thoughts? Not urgent yet.

At the moment I am using a hybrid of xfce with xfwm4, xfce4-panel and lfsdesktop/setwallpaper.

Couple of screen shots etc:
https://dl.dropboxusercontent.com/s/...booy/scrn1.jpg
https://dl.dropboxusercontent.com/s/...aard/desk1.mp4

TO DO
Add right click on disk icon to bring up menu for mounting, unmounting and ejecting.
Add Icons from files in ~/Desktop. - DONE.
Improve event handling. - DONE.
Add Settings manager.
Add other backends for mounting disks sudo/pmount, will need a gui for getting password.
Add WM menu if available to right click.
Add SetWallpaper code into LFSDesktop code as an option.

Long way off.

Add session manager.
Add window manager.
Add panels.
Add panel plugins, minimum logout/shutdown/restart/application menu/page switch/clock/notification area, probably more.
Add dock.
Add floating widgets?

Last edited by Keith Hedger; 05-31-2015 at 08:27 AM. Reason: update
 
Old 05-18-2015, 11:18 AM   #2
bryan_S
Member
 
Registered: Aug 2014
Location: N. Florida
Distribution: LinuxfromScratch, OpenSuse, Slackware
Posts: 107

Rep: Reputation: Disabled
Quote:
Having upgraded to xfce 4.12 I have found that yet again stuff has been broken, apparently by inclusion of dependencies ( runtime or otherwise ) on systemd/gtk3 and I'm fed up with it...
Yeah, i recompiled much of my Xfce 4.12 on CRUX _without_ gtk3 installed and it works much nicer now. They (Crux) have a port of Handbrake that works with gtk2 and latest Audacious now defaults to gtk2 (yay!). So i dont miss it (gtk3) at all.

I'm looking forward to trying out Compton with Xfce. I've previously tried using compiz with Xfce but it just doesn't integrate too well.
 
Old 05-18-2015, 12:21 PM   #3
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
I don't use handbrake, too limiting, I do all my CD/DVD ripping with mplayer/ffmpeg.
The other problem I found with xfce 4.12 is that although it is supposed to be gtk2 one of the main parts needs gtk3 ( garcon if I remember ) I downgraded to 4.10, and as soon as I can I shall get rid of that too.
 
Old 05-18-2015, 01:00 PM   #4
hendrickxm
Member
 
Registered: Feb 2014
Posts: 344

Rep: Reputation: Disabled
Great idea! I use i3 and a handfull of gtk2 apps so I can keep dependency issues to a minimum.
Perhaps not completely on topic but ch6 of the LFS-book contains libcap and gperf. Only coreutils can use libcap (compiles fine with --without-libcap) and nothing I know of needs gperf (introduced in LFS 7.6).
Then I also build MesaLib without llvm. A stripped LFS might become useful as it only gets bigger lately.
 
Old 05-25-2015, 02:51 AM   #5
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-15.0 Multilib
Posts: 6,558
Blog Entries: 15

Rep: Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097
Hey Keith have you tried using the loginkit systemd shim kit along with ConsoleKit2? I have sources for loginkit-0.1 up in my Slackworks repo that can be easily downloaded. The install process is in the SlackBuild if you need it. Not sure if it will help, but it might.

As far as GTK3 stuff for Xfce, yes, some of it works, but not all of it. Garcon should still work with GTK2 (version 0.5.0 should anyway).

Also, loginkit does need Linux-PAM, but there is a patch I have if you don't have PAM.

You also MIGHT want to consider drafting a ConsoleKit boot script for sysvinit as well.

Last edited by ReaperX7; 05-25-2015 at 02:53 AM.
 
Old 05-25-2015, 05:48 AM   #6
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
The whole idea of this is to get away from anything systemd'iefied, and console kit although it works relies on other stuff to work properly, you cant for instance use consolekit with xfce-session without dbus and you still get no disk icons without gnomes gvfs even though xfce has its own version of gvfs ( thunarvfs or whatever ) which doesn't seem to do anything.

I want to get away from all these dependencies especially the ones tied to gnome and hence ultimatly to systemd and its ilk.

And yes the blfs book says xfce can be built without gtk3 but that is just not true, garcon ( I think its garcon, I'm not at my mavchine at the moment, so I could be mistaken ) is configured to use gtk3 only

I'm happy to accept suggestions and even code ( anyone fancy writing the window manager ), but not if it involes adding anything to do gtk3/systemd/gnome.
 
Old 05-25-2015, 06:17 AM   #7
ReaperX7
LQ Guru
 
Registered: Jul 2011
Location: California
Distribution: Slackware64-15.0 Multilib
Posts: 6,558
Blog Entries: 15

Rep: Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097Reputation: 2097
That might be a challenge. I know a lot of stuff now is all intertwined with DBus and such.

Getting systemd stuff out is painful, often a headache, but the shims are one way of working around systemd. Unfortunately, systemd-shim itself requires systemd to even build, so that went off the table on my end also. I ended up with Devuan's Loginkit out of curiosity and necessity.

Using hald anymore requires extreme patching to glib's files, and tons of roll up patches to hald itself to build at all. I know FreeBSD is trying to move more onto devd and some various new internals as well. That might be one route for some functionality, but its a God awful damn bloody mess regardless how you look at it.
 
Old 05-25-2015, 08:11 AM   #8
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
Well so far I have a 45% working desktop only using some commandline apps from util-linux, xdg for opening and eudev for device stuff.

I will do another release in a day or so, but so far all disks, fixed and removable usb and dvd/cdrom etc are detected and can be mounted, files in the~/Destktop folder are also shown, with the corrrect icon ( mostly ) and can be double clicked to open them with the default app.

Repositioned icons are remembered and in the case of ejectable disks position is remembered on re-insertion.

Watch this space!
 
Old 05-27-2015, 08:45 AM   #9
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
New update to LFSDesktop here:
https://dl.dropboxusercontent.com/s/...p-0.0.5.tar.gz

Files from ~/Desktop now shown, double clicking them opens in default app.
MUCH less thrashing of the harddrive, everything now kept in memory.
Icons change to reflect a new mimetype, for instance adding '#!/bin/bash' to the top of a text file turns the icon from a text file icon to a shell script icon.

Cache data has changed format so use
Code:
lfsdesktop -c
The first time you run it to force a rebuild of the caches.

Next bit to do add context menu, decide to go for lesstif but got to learn it first!
 
Old 05-31-2015, 08:29 AM   #10
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
New update to LFSDesktop here:

https://dl.dropboxusercontent.com/s/...p-0.0.6.tar.gz

Screenshot:
https://dl.dropboxusercontent.com/s/...xd8u/scrn2.jpg

0.0.6
Now shows 'Computer' icon for root system, and no longer mountable/unmountable from right click.
Uses kernel 'getmntent' routines for determining mounted disks and mount point instead of external command.
More stuff in memory instead of thrashing hardrive.
Folded Desktop files into disk arrays.
Major code clean.
Symlinks handled properly in ~/Desktop.
Pop up menu disappears if you move pointer out of window.
Fixed Segfault trying to eject some disks.
Added right click on disk to mount/unmount/eject.

Last edited by Keith Hedger; 05-31-2015 at 08:34 AM. Reason: added screenshot
 
Old 05-31-2015, 04:08 PM   #11
GameCodingNinja
Member
 
Registered: Jul 2014
Posts: 100

Rep: Reputation: Disabled
I'm using 4.12 with my lfs/blfs and it works fine. For me it seemed to work better if I deleted all the .config, .cache etc and boot up into it fresh where it asks if you want to start with the default layout. I know it's a pain to re-setup your desktop but that seemed to work for me.
 
Old 05-31-2015, 04:47 PM   #12
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
I don't deny that xfec 4.12 can be made to work, I just objet to the path xfce is taking, hence this project, I'm not saying that other desktops don't work or are no good, just want to add an option for people that feel they don't want to have to be dictated to by the likes of the systemd/gtk/gnome devs. Xfce I assume gets some income from marketing, donatations etc and so have vested ( monetary ) interest in the status quo, this is just another option.
 
Old 06-08-2015, 11:46 AM   #13
exvor
Senior Member
 
Registered: Jul 2004
Location: Phoenix, Arizona
Distribution: Gentoo, LFS, Debian,Ubuntu
Posts: 1,537

Rep: Reputation: 87
on my gentoo system i tried to use xfce4 again and i have systemd and its still a broken mess. I think ill have to abandon them again... I used to use it all the time before they adopted dbus and went off the deep end.
 
Old 06-08-2015, 04:36 PM   #14
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
Hence this project, watch this space as I will be updating the desktop in a day or two, with custom icons for files and disks and an application menu ...
 
Old 06-10-2015, 06:17 AM   #15
Keith Hedger
Senior Member
 
Registered: Jun 2010
Location: Wiltshire, UK
Distribution: Void, Linux From Scratch, Slackware64
Posts: 3,150

Original Poster
Rep: Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856Reputation: 856
For some odd reason the 'Edit' button for the original post has dissapeared so I'll put the update here.

New LFSDesktop here:
https://dl.dropboxusercontent.com/s/...p-0.0.7.tar.gz

Quite a few improvements in this one:
0.0.7
Custom icon path dialog now pops up in centre of window.
.desktop files now show proper icon for theme.
Added 'Open' option to right click menu.
Added remove custom icons.
Added set custom icons.
Added 'appmenu' resources file to /etc/X11/app-defaults.
Application menu now pops up at mouse and dissapears if mouse is moved out of window.
Added 'Applications' menu.

Extra screen shots here:
https://dl.dropboxusercontent.com/s/...xjp3/scrn3.jpg
https://dl.dropboxusercontent.com/s/...4m8w/scrn4.jpg
https://dl.dropboxusercontent.com/s/...r5sw/scrn5.jpg
https://dl.dropboxusercontent.com/s/...huup/scrn6.jpg
https://dl.dropboxusercontent.com/s/...jnx8/scrn7.jpg
https://dl.dropboxusercontent.com/s/...ipp9/scrn8.jpg

Right clicking in the root window will now pop up an applications menu built from the desktop files in /usr/share/applications, there is no need for any fancy configs for this menu as it is built dynamically.

There is an xresources file now installed in /etc/X11/app-defaults called appmenu which will allow you to set colours etc of the pop-ups, have a look at the screen shots.

You can set a custom icon on any of the desktop files but be aware it must be an absolute path to the icon.

To get rid of the pop-ups just move the mouse out of the window ( except for the custom icon dialog, you have to either click Ok or Cancel ).
Also be aware that if you rebuild the desktop cache with the '-c' option you will will lose and custom icons, .desktop files will of course go back to displaying their own icon.
Mostly adding/removing custom icons has an immediate visual effect except for removing the custom icon on a .desktop file this will change the files to the generic icon until you restart the desktop.

I am now using lfsdesktop as my default and so far it seems prety stable, so this will be the last update for a little while while I work on the other bits, WM etc.

Enjoy!
 
  


Reply

Tags
blfs, desktop, lfs



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Linux From Scratch Desktop Screen Shots Keith Hedger Linux - Member Desktop Screenshots 3 03-18-2023 09:15 AM
Linux From Scratch project jurp Linux From Scratch 26 03-17-2012 02:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch

All times are GMT -5. The time now is 03:46 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration