/dev/fb0 is the new black

by debianjoe

Image

I stole Wuxmedia’s screenshot.  He’ll either be cool with it, or can yell at me later.  I’ve already posted mine, so I needed some variety.

The very title of this blog could possibly lead to some speculation as to why someone would want X11 to die.  If you’ve ever programmed for anything in X, then this makes total sense.  X is a convoluted hack that is held together by tradition more than practicality.  Oh, sure, it’s fine as long as you’re using gtk and qt wrappers and never actually having to get down to the lower level of how the xserver works, but once you do, you will realize that you cannot un-see what has been seen.

The most fun answer that I’ve found so far is doing framebuffer-only builds, that don’t include xorg/xserver/xinit.  They’re not that hard to set up, and are reasonable well documented in a write-up that I did at the LinuxBBQ.  There are some quirks, but much like the adjustment that people would have coming from another OS to Unix-based systems, you adjust to the quirks.  Unlike Xlibs, these quirks actually make a decent amount of sense.

So, “why?” is probably the greatest question that could be asked.  I honestly started using /dev/fb0 as a display server out of curiosity.  After realizing that you could display some decent graphics (and even movies) with it, I fell in love.  Perhaps it’s part of the backlash against trends towards Gnome3/Unity/gtk-3/qt-toolkits/etc.  I’ve been a fan of cwm and dwm for a while, but more and more, I don’t really even feel the need for X at all.  With the rising popularity of GNU/Linux, there has been a steady increase in trying to make the interfaces more “user-friendly.”  My problem with this design is that all that is actually happening is that the true working components of the Unix core of Linux are being obscured by animated widgets and buttons.

The framebuffer builds offer a release from the world of graphical abstractions.  I’m sure that Ratpoision, stumpwm, and others could be considered to do the same thing, but if you’re not going to build programs designed around X, then I don’t see a reason to use it at all.

I’ll probably write a great deal about using the framebuffer to do things that you would otherwise do in X.  There’s already a thread at the LinuxBBQ forums for this subject, but know that many of the answers there may be directed towards Debian (especially Sid/Experimental).  That doesn’t mean that there aren’t similar solutions elsewhere, and I am going to step out on a limb and say that if you’re looking to avoid the use of X11 in Linux, then you should be able to figure out quite a bit of this on your own.  I will say that I’ve done it on Archlinux and Slackware, so I can promise that those work.

The main advantage to running a FB-build as far as I’m concerned is slightly more abstract than just avoiding graphical bloat.  What it will do is make the user extremely comfortable with using the shell.  Of course, you can always open a terminal emulator and do the same things inside of X, but taking the option of opening a file manager (excluding ncurses ones, of course) away from the user does create a much more aggressive learning curve.  It leads you to some of the fastest answers available in from the command line to perform basic tasks, and as you learn the basics better…the more advanced subjects come easier.

It’s worth adding that https://kmandla.wordpress.com/ is well worth your time to look over if you plan to leave the nest and venture into console-only computing.  Kmandla’s writing is like finding a treasure chest full of goodies, and I’ve yet to try everything that he has written about.