Skip to content

Tutorial: build a desktop environment without dbus

souperdoupe edited this page May 22, 2018 · 5 revisions

The following was originally posted by refracta developer fsmithred, and has been editorially modified. I posted it here because crunkbong is built in a similar way, and also avoids dbus. LXDE lacks the hard dbus dependencies that XFCE requires; thus, the packages in "Part 2" should give a user a more "complete" desktop than native crunkbong.

As this tutorial will produce a custom devuan spin, the crunkbong installer can be used postfacto to add crunkbong scripts and download/install crunkbong programs. Likewise, use of crunkbong at all for these procedures is completely optional.

Part 1: Base setup

debootstrap --arch amd64 ascii /mnt http://pkgmaster.devuan.org/merged

copy any special files to the new system. (e.g. /usr/local/bin/*)

chroot into the new system to install software and edit files,

create root password and create a user.

echo "APT::Install-Recommends \"no\";" > /etc/apt/apt.conf.d/norecommends

Edit /etc/apt/preferences.d/avoid-systemd to exclude dbus and libsystemd0.

Package: systemd-sysv

Pin: release o=Debian

Pin-Priority: -1

Package: *systemd*

Pin: release n=ascii

Pin-Priority: -1

Package: dbus

Pin: release n=ascii

Pin-Priority: -1

Install some packages

apt-get install rsync bash-completion busybox kbd locales firmware-linux-free deborphan unzip lvm2 cryptsetup sshfs
hwinfo alsa-utils moc pppoeconf pppconfig pppoe ntfs-3g dosfstools curl
live-boot live-config live-boot-initramfs-tools live-config-sysvinit squashfs-tools xorriso pmount pv
syslinux syslinux-common syslinux-utils isolinux xz-utils gdisk parted hexedit iftop smartmontools lm-sensors
hdparm testdisk fdupes irssi iptraf ethtool scrot wipe mlocate wireless-tools wpasupplicant \ # get libdbus-1-3 here gddrescue screen feh hddtemp p7zip-full partimage pm-utils sysv-rc-conf tree wodim htop bzip2 whois
lsb-release file setnet net-tools cifs-utils mdadm arp-scan
dialog live-boot-doc live-config-doc refractainstaller-base refractasnapshot-base
btrfs-tools btrfs-progs pciutils psmisc rename tcpd usbutils uuid-runtime dnsutils
eject telnet usbutils util-linux-locales vrms mutt sudo

Part 2: GUI Setup

For ascii (optional)

echo 'Binary::apt::APT::KeepDownloaded-Packages "true";' > /etc/apt/apt.conf.d/01keep-debs

For sanity (avoid *kit)

echo "user ALL= NOPASSWD: /usr/sbin/pm-suspend, /usr/sbin/pm-hibernate, /sbin/halt, /sbin/reboot" > /etc/sudoers.d/user_shutdown

That's pretty good, but I want a graphical environment. Removing this section from the preferences file will allow lsd0 to be installed.

Package: *systemd*

Pin: release n=ascii

Pin-Priority: -1

Install more packages:

apt-get install xorg openbox spacefm lxterminal lxpanel obconf lxappearance lxappearance-obconf lxrandr
linux-headers-4.9.0-6-amd64 build-essential xserver-xorg-legacy xserver-xephyr xterm aptitude
icewm xarchiver leafpad links2 xpdf mpv yad x11vnc xtightvncviewer grsync bleachbit meld asunder winff
mplayer ffmpeg volumeicon-alsa tilda geeqie dkms transmission-gtk gftp
xserver-xorg-video-intel xscreensaver xinput libnotify-bin hexchat
abiword hardinfo gdmap gimp geany firejail firefox-esr grub-of-your-choice

These will NOT install:

audacious xfburn wicd connman libpam-elogind synaptic gdebi

Workarounds

I replaced audacious with deadbeef from http://sourceforge.net/projects/deadbeef..._amd64.deb

For network setup, there's setnet.sh or the command-line. (Author's note: in crunkong, the wefe script will work for this aim.)

For package management, there's the command-line.

Since there's no display manager and no libpam-elogind, I need to force X to run as root:

echo "needs_root_rights=yes" /etc/X11/Xwrapper.config

Now I have a dbus-free system that I can use. I'm watching a video right now.

Part 3: Install crunkbong features (optional)

git clone https://github.com/souperdoupe/crunkbong

cd crunkbong/utils

sh install.sh