evilwm installation guide

Building from source

See the evilwm home page for downloads. Once you have a copy of the source code, either the git repository or by downloading a tar archive, building is very straightforward.

In addition to the standard C compiler tools, you will need X11 development files installed. Under Debian, the x11proto-dev, libx11-dev and libxrandr-dev packages should suffice.

The source distribution does contain a configure script, but this is not from the GNU build system. It is a minimal bash script provided to simplify multiarch cross-builds under Debian. Instead, edit the Makefile to modify build flags for your platform.

Then, building and installing is very simple:

$ make
$ make install

That's it! But if you need to install to a different prefix, you can override with something like:

$ make install prefix=/usr/local

Starting evilwm

The install process puts a file called evilwm.desktop into /usr/share/applications, so depending on your desktop manager, you may simply be able to pick evilwm from a menu when you log in. Otherwise, most managers will run Xsession, which will look for a file in your home directory called .xsession and run it (so be sure it has execute permission). Here's a simple example .xsession file:

#!/bin/sh
test -f $HOME/.Xresources && xrdb -merge $HOME/.Xresources
xsetroot -solid \#400040 -cursor_name left_ptr
( /usr/bin/evilwm -snap 10 >/dev/null 2>&1 & )
exec xclock -digital -padding 2 -g -0+0

The cursor shape and background colour are set with standard X tools (evilwm won't do this for you). xclock becomes the "magic process" (session terminates when it is killed). evilwm itself is started in a subshell otherwise xclock would become its parent, and killing evilwm to restart it may result in a zombie process. You could also avoid this by not exec-ing the "magic process"; the shell will handle child signals properly.

See here for a more complete example of a .xsession file. Obviously, it depends on a lot of external packages.

If you typically start X by typing startx from the console, you might need the .xsession file to be called .xinitrc. A symlink should suffice.

After starting, you should be able to bring up an xterm with Control+Alt+Enter. For more information on configuring and using evilwm, see the manual.

Updated 30 Jul 2021