29. Juni 2010

Customizing DWM in Debian

Category: Howto / Tutorial — Tags: – Kay Smarczewski @ 16:12

As supposed on the DWM customization window key howto, I wanted to change the mod key for my favourite window manager, DWM.

Please look at the update note at the end of this article!

I changed the config.def.h as advised in the tutorial and compiled it following this DWM customization tutorial. But I have got the following error:

kay@localhost:~/download/dwm-5.8.2$make clean install
cleaning dwm build options: CFLAGS = -g -std=c99 -pedantic -Wall -O0 -I. -I/usr/include -I/usr/X11R6/include -DVERSION="5.8.2" -DXINERAMA LDFLAGS = -g -L/usr/lib -lc -L/usr/X11R6/lib -lX11 -L/usr/X11R6/lib -lXinerama CC = cc CC dwm.c
dwm.c:40:37: error: X11/extensions/Xinerama.h: No such file or directory

The solution for that is quite trivial: install Xinerama ;)

# aptitude install libxinerama-dev

If you get the errors

dwm.c:33:28: error: X11/cursorfont.h: No such file or directory
dwm.c:34:24: error: X11/keysym.h: No such file or directory
dwm.c:35:23: error: X11/Xatom.h: No such file or directory
dwm.c:36:22: error: X11/Xlib.h: No such file or directory
dwm.c:37:24: error: X11/Xproto.h: No such file or directory
dwm.c:38:23: error: X11/Xutil.h: No such file or directory

you need to install libx11-dev including its dependencies (libpthread-stubs0, libpthread-stubs0-dev, libxau-dev, libxcb1-dev, libxdmcp-dev, x11proto-core-dev, x11proto-input-dev, x11proto-kb-dev, xtrans-dev):

aptitude install libx11-dev

Aptitude should resolve the dependencies and install them automaticly. If not, you have to do it the same way as mentioned above. ;) After doing the compilation works fine for me. Additionally I had to add the new dwm to my updates-alternatives. Unfortunately, I haven’t found a quite good solution. But the following works for me:

  • edit /var/lib/dpkg/alternatives/dwm
  • add /usr/local/bin/dwm with some priority to it
  • run # update-alternatives –config dwm

Of course you can edit your ~/.xsession file directly to force loading the customized version of dwm, too.

Update: A more appropriate solution in a Debian environment is using checkinstall and dpkg:
# checkinstall -y --pkgname dwm-local --maintainer <your@name> --requires libxinerama-dev,libx11-dev make clean install
# dpkg -i <the_name_of_generated_file.deb>

Checkinstall creates an Debian install package (.deb) from the sources. dpkg installs that and should respect the given dependencies libxinerama-dev and libx11-dev of your new package called dwm-local.

Note: Use instructions at your own risk! See Impressum!

Keine Kommentare »

Noch keine Kommentare

RSS Feed für Kommentare zu diesem Artikel. | TrackBack URI

Hinterlasse einen Kommentar

XHTML ( You can use these tags):
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> .

Kay Smarczewski


mein Blog

Seiten

Kalender mit Posts

Juni 2010
M D M D F S S
« Mai   Aug »
 123456
78910111213
14151617181920
21222324252627
282930  

Schlagwörter

Dieses Blog durchsuchen

© Kay Smarczewski – Powered by WordPress