The Ultimate Linux Desktop

Motivation

[Disclaimer: If you have found your way to this post somehow, please note that it is still work in progress and more of a collection of notes at this stage.]

If you are a Linux user, you have probably tried out a number of distributions until you found the one that more or less corresponds to you needs. Starting in about 1998 with RedHat, I have eventually moved to Ubuntu and never looked back (and Debian on the server). Unfortunately, open source projects do not have the same obligation to serve the needs of their users as businesses, so developers are free to force their own ideas on the consumers of their goods. This obviously didn’t go so well when Ubuntu switched to Unity and Gnome became Gnome Shell. Initially I was excited to try out a new GUI paradigm, but it quickly became obvious that what was delivered lacked many basic features and the “innovative” concepts should have been refined first and not forced as a beta-quality software on the broadest Linux audience at the time. In short – a repeat of the KDE4 launch disaster.

After using Xfce4/XUbuntu for a time, I finally settled on Linux Mint and that was that. Despite being heavily under development (and still is!), Cinnamon proved to be a viable alternative to Gnome 3 and even tries to include new features. For me this is currently the most usable desktop environment for Linux. If you want to use a traditional desktop with a modern and stream-lined look, I don’t think that you will find anything better.

So far so good. But Linux Mint is based on Ubuntu. And Ubuntu is based on Debian Testing. Time and again I experienced small annoyances, crashes(on Linux!), and even put up with stuff like inability to automatically go to standby mode for whatever reason. It is true that I could have probably eventually fixed all these issues since I have the technical knowledge, but I decided that I simply needed a more stable platform. Time to move on to Debian stable. If you are willing to invest some time into configuring your system and are not afraid to get your hands dirty you will probably opt for Debian stable too. In addition, while most of the software is relatively old, you don’t really need the cutting edge system libraries for most of your work and you can always use backports, testing software, and even install from source. The reason I didn’t go straight to LMDE is that they are not based on Debian stable and I was put off that distribution by several issues with the live image.

What is this guide all about?

The purpose of this guide is to follow the installation of a Debian stable system with a Cinnamon desktop environment from the very beginning. It is more like a documentation of the process in case I will have to do that again (and I am not willing to build install images or whatever). Since the “tricky” part has to deal more with the Cinnamon installation and configuration, I will necessarily skip some steps, assuming that the user is experienced enough to install the basic Debian system himself. Also, you are probably interested in this guide as a reference and not as a step-by-step instruction. In trying to be thorough I am simply saving myself some time when the need for installation and tinkering arises again.

Use a virtual machine first!

When installing an operating system, it is always a good idea to test the whole process first. It is true that modern Linux distributions make that trivially easy, but many unexpected things may occur. For instance, my wireless chip is new enough not to be recognized by the comparatively old kernel (3.2) of Debian Wheezy, so I had to resort to all sorts of hacks to connect to my network. And we need the network to install Cinnamon.

Contents

  1. Layout
  2. Basic System
  3. Cinnamon
  4. Post-Install Configuration

System Layout

Partitioning

In order to manage my system better, especially when reinstalling the operating system, I have came up with the following partitioning:

  • There is a 32 GB partition for the root / ext4 file system
  • A 4 GB swap partition
  • The rest is reserved for the home (ext4) partition

You could always experiment with other partitions like btrsf, but this is not the aim here.

Home Directory Organization

If you like to have the same user name when reinstalling your system, you may want to clean up the old configuration for most of the software packages you use, since some old settings may cause problems with later versions. My latest idea is simply to put all of my data in /home/data and create links to its sub directories from my home directory. Concretely this means:

  • /home/rseed42/Audio -> /home/data/Audio
  • /home/rseed42/Music -> /home/data/Music
  • /home/rseed42/Documents -> /home/data/Documents
  • /home/rseed42/Pictures -> /home/data/Pictures
  • /home/rseed42/.local/bin -> /home/data/.local/bin
  • /home/rseed42/.local/lib -> /home/data/.local/lib
  • /home/rseed42/Desktop
  • /home/rseed42/Tmp

Note that some directories should not be linked. For instance, /home/rseed42/Desktop will be created the first time you log in and it does not contain any of your data, so unless you want to do something special with it, you should leave it to be created automatically.

You may want to maintain custom versions of some configuration files like .bashrc. I found that a nice solution is to initialize your home directory as a Git repository that maintains such files. You will also definitely need a .gitignore file where you can enter most of the other automatically created program configuration directories and files (most are hidden). Due to frequent changes in the configuration files I found that it is best approach to check in only files you want customized and to ignore everything else.

Basic System Installation

While writing this post I am simultaneously installing a Debian Wheezy system in a VirtualBox virtual machine so that I can write up the process step-by-step as it happens.

Boot Image

Note of caution: Unless you are sure that Debian Wheezy will install without problems on your system, you always need a backup plan. Have another live image ready (Ubuntu is likely to boot on most systems) and know what you are doing!

You can get a complete Debian Wheezy image from:

http://www.debian.org/CD/

I recommend using the DVD, since Cinnamon has a ton of dependencies that would be installed faster using the DVD. More specifically, I am using: debian-7.3.0-amd64-DVD-1 for this guide. Please, use a mirror next to you to download it.

To copy it on a USB stick you can use a program like USB Image Writer or even dd:

dd if=<file> of=<device> bs=4M; sync

Pointers for Installing the Base System

  • Use advanced expert install only if you need to load some drivers that are needed for the installation
  • Set up keyboards, localization, etc properly
Start Menu

Start Menu: Choose expert install for more options (like using sudo)

Load Components

Load additional components for the installer if your hardware needs them.

Use sudo

Use sudo instead of a separate root account

Setup the time server client

Use a time server mirror.

Choose to install the Debian desktop environment

Choose to install the Debian desktop environment because it includes many dependencies for Cinnamon and makes the whole process easy.

Install Grub

Install Grub, but beware of UEFI problems.

And that’s it!

Preparing the system for Cinnamon

There are several things we need to do before setting up a bleeding edge version of Cinnamon. We need some tools and some configuration.

Configuring the Source Repositories

First, we need to update the /etc/apt/sources.list file.

# Security updates (Germany)
deb http://security.debian.org/ wheezy/updates main contrib non-free
deb-src http://security.debian.org/ wheezy/updates main contrib non-free

# Updates (Germany)
deb http://ftp2.de.debian.org/debian/ wheezy-updates main
deb-src http://ftp2.de.debian.org/debian/ wheezy-updates main

# Backports (Germany)
deb http://ftp2.de.debian.org/debian/ wheezy-backports main
deb-src http://ftp2.de.debian.org/debian/ wheezy-backports main

# Linux mint (cinnamon)
deb http://packages.linuxmint.com/ debian main import
deb-src http://packages.linuxmint.com/ debian main import

# Base repository (Germany)
deb http://ftp2.de.debian.org/debian/ wheezy main contrib non-free
deb-src http://ftp2.de.debian.org/debian/ wheezy main contrib non-free

# For some audio/video codecs and newer software
deb http://www.deb-multimedia.org wheezy main non-free

Now run apt-get update.

apt-get install linuxmint-keyring (unless you are paranoid and would like to install the key first)

apt-get update

Cinnamon:

1. Problem: libc6-2.15 dependency. On Wheezy stable it is 2.13-38, so no go (unless you want to risk your system’s stability with an experimental version).

2. Solution: compile from source

apt-get install git

mkdir -p ~/Src/Cinnamon

git clone https://github.com/linuxmint/cjs

in cjs:

git checkout -b 2.0.0 2.0.0

Install build tools:

apt-get install dpkg-dev debhelper cdbs gnome-pkg-tools autotools-dev dh-autoreconf pkg-config

Install build dependencies:

apt-get install libdbus-glib-1-dev libglib2.0-dev libgirepository1.0-dev gobject-introspection uuid-runtime libcairo2-dev libmozjs185-dev

dpkg-buildpackage -us -uc

install all *.deb packages

git clone https://github.com/linuxmint/cinnamon-desktop

git checkout -b 2.0.4 2.0.4

Install build tools:

apt-get install intltool gtk-doc-tools gnome-doc-tools  gnome-doc-utils yelp-tools

Install build dependencies:

apt-get install libxrandr-dev libxext-dev libxkbfile-dev libgdk-pixbuf2.0-dev libxml2-dev libglib2.0-doc libgtk-3-doc libgl1-mesa-dev libgtk-3-dev

sudo apt-get install cinnamon-translations

sudo apt-get install cinnamon-session

git clone https://github.com/linuxmint/cinnamon-settings-daemon

git checkout -b 2.0.8 2.0.8

Install build dependencies:

sudo apt-get install libnotify-dev libxt-dev libxtst-dev libpulse-dev libcanberra-gtk3-dev libcups2-dev libpolkit-gobject-1-dev libupower-glib-dev libcolord-dev liblcms2-dev libnss3-dev libgudev-1.0-dev libwacom-dev libgnomekbd-dev libxklavier-dev

dpkg-buildpackage -us -uc

We need the following package first:

apt-get install nemo-data

Now install all generated *.deb packages

git clone https://github.com/linuxmint/cinnamon-control-center

git checkout -b 2.0.9 2.0.9

Install build dependencies:

apt-get install hardening-wrapper libcheese-gtk-dev libgnome-menu-3-dev libgstreamer-plugins-base0.10-dev libnm-glib-dev libnm-gtk-dev libnm-util-dev network-manager-dev libclutter-gtk-1.0-dev

dpkg-buildpackage -us -uc

install the *.deb files

git clone https://github.com/linuxmint/muffin

git checkout -b 2.0.5 2.0.5

Install build dependencies:

apt-get install libgconf2-dev libstartup-notification0-dev

dpkg-buildpackage -us -uc

Install *.deb files

git clone https://github.com/linuxmint/Cinnamon

git checkout -b 2.0.14 2.0.14

Install build dependencies:

sudo apt-get install python-dev libcaribou-dev libcroco3-dev libgnome-bluetooth-dev libgnome-keyring-dev librsvg2-dev libsoup2.4-dev libwnck-dev libxss-dev libpolkit-agent-1-dev

dpkg-buildpackage -us -uc

We need some install dependencies:

sudo apt-get install python-opencv python-pam python-lxml python-pyinotify

Install *.deb files.

git clone https://github.com/linuxmint/nemo

git checkout -b 2.0.8 2.0.8

sudo apt-get install libgail-3-dev libexif-dev libexempi-dev

dpkg-buildpackage -us -uc

Install *.deb files

git clone https://github.com/linuxmint/cinnamon-screensaver

git checkout -b 2.0.3 2.0.3

sudo apt-get install libpam0g-dev x11proto-xf86vidmode-dev libxxf86vm-dev

dpkg-buildpackage -us -uc

Install the *.deb files

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s