Thread: dwm patching
View Single Post
  #4   (View Single Post)  
Old 14th November 2014
scottro's Avatar
scottro scottro is offline
Real Name: Scott Robbins
ISO Quartermaster
 
Join Date: Apr 2008
Location: NYC
Posts: 631
Default

In FreeBSD, I create the patch and then put it in /usr/ports/x11-dwm/files. I don't know how it works in OpenBSD. To get your custom config do you do something like make DWM_CONF=$HOME/dwm/config.h install clean or something like that?

In FreeBSD, the manual way to do it would be (I'm going into this detail making an assumption which is quite possibly wrong, that it's more or less similar)

Code:
make DWM_CONF=/home/scottro/config.h extract
Then, I go and patch dwm.c (or whatever file is being patched. Then, back to /usr/ports/x11-wm/dwm and make install clean.

As I tend to tweak my config.h a lot while first installing on a particular machine, what I do in practice is patch dwm.c the first time--as the patch that I like is the moveresize patch with the option to make a window being moved automatically a floating window. I now have a patch, patch-dwm.c which I put, as mentioned, under files (which is the canonical place in FreeBSD if you have a patch to a port. Canonical place? Is that a thing? I digress...)

Anyway, now I can keep tweaking my config.h, doing make deinstall make DWM_CONF=/home/scottro/dwm/config.h install clean without worrying anymore about having to manually install the patch.

Again, I don't know how it's done with OpenBSD ports but maybe this has helped.
Meh, might as well spam my own dwm page while at it, http://srobb.net/dwm.html

(And I have one for spectrwm now too, http://srobb.net/spectrwm.html
Reply With Quote