--- /dev/null
+--- a/Makefile
++++ b/Makefile
+@@ -12,45 +12,44 @@
+ @echo dzen2 build options:
+ @echo "CFLAGS = ${CFLAGS}"
+ @echo "LDFLAGS = ${LDFLAGS}"
+- @echo "CC = ${CC}"
++ @echo "CC = $(CC)"
+ @echo "LD = ${LD}"
+
+ .c.o:
+ @echo CC $<
+- @${CC} -c ${CFLAGS} $<
++ $(CC) -c ${CFLAGS} $<
+
+ ${OBJ}: dzen.h action.h config.mk
+
+ dzen2: ${OBJ}
+ @echo LD $@
+- @${LD} -o $@ ${OBJ} ${LDFLAGS}
+- @strip $@
++ ${LD} -o $@ ${OBJ} ${LDFLAGS}
+ @echo "Run ./help for documentation"
+
+ clean:
+ @echo cleaning
+- @rm -f dzen2 ${OBJ} dzen2-${VERSION}.tar.gz
++ rm -f dzen2 ${OBJ} dzen2-${VERSION}.tar.gz
+
+ dist: clean
+ @echo creating dist tarball
+- @mkdir -p dzen2-${VERSION}
+- @mkdir -p dzen2-${VERSION}/gadgets
+- @mkdir -p dzen2-${VERSION}/bitmaps
+- @cp -R CREDITS LICENSE Makefile INSTALL README.dzen README help config.mk action.h dzen.h ${SRC} dzen2-${VERSION}
+- @cp -R gadgets/Makefile gadgets/config.mk gadgets/README.dbar gadgets/textwidth.c gadgets/README.textwidth gadgets/dbar.c gadgets/gdbar.c gadgets/README.gdbar gadgets/gcpubar.c gadgets/README.gcpubar gadgets/kittscanner.sh gadgets/README.kittscanner gadgets/noisyalert.sh dzen2-${VERSION}/gadgets
+- @cp -R bitmaps/alert.xbm bitmaps/ball.xbm bitmaps/battery.xbm bitmaps/envelope.xbm bitmaps/volume.xbm bitmaps/pause.xbm bitmaps/play.xbm bitmaps/music.xbm dzen2-${VERSION}/bitmaps
+- @tar -cf dzen2-${VERSION}.tar dzen2-${VERSION}
+- @gzip dzen2-${VERSION}.tar
+- @rm -rf dzen2-${VERSION}
++ mkdir -p dzen2-${VERSION}
++ mkdir -p dzen2-${VERSION}/gadgets
++ mkdir -p dzen2-${VERSION}/bitmaps
++ cp -R CREDITS LICENSE Makefile INSTALL README.dzen README help config.mk action.h dzen.h ${SRC} dzen2-${VERSION}
++ cp -R gadgets/Makefile gadgets/config.mk gadgets/README.dbar gadgets/textwidth.c gadgets/README.textwidth gadgets/dbar.c gadgets/gdbar.c gadgets/README.gdbar gadgets/gcpubar.c gadgets/README.gcpubar gadgets/kittscanner.sh gadgets/README.kittscanner gadgets/noisyalert.sh dzen2-${VERSION}/gadgets
++ cp -R bitmaps/alert.xbm bitmaps/ball.xbm bitmaps/battery.xbm bitmaps/envelope.xbm bitmaps/volume.xbm bitmaps/pause.xbm bitmaps/play.xbm bitmaps/music.xbm dzen2-${VERSION}/bitmaps
++ tar -cf dzen2-${VERSION}.tar dzen2-${VERSION}
++ gzip dzen2-${VERSION}.tar
++ rm -rf dzen2-${VERSION}
+
+ install: all
+ @echo installing executable file to ${DESTDIR}${PREFIX}/bin
+- @mkdir -p ${DESTDIR}${PREFIX}/bin
+- @cp -f dzen2 ${DESTDIR}${PREFIX}/bin
+- @chmod 755 ${DESTDIR}${PREFIX}/bin/dzen2
++ mkdir -p ${DESTDIR}${PREFIX}/bin
++ cp -f dzen2 ${DESTDIR}${PREFIX}/bin
++ chmod 755 ${DESTDIR}${PREFIX}/bin/dzen2
+
+ uninstall:
+ @echo removing executable file from ${DESTDIR}${PREFIX}/bin
+- @rm -f ${DESTDIR}${PREFIX}/bin/dzen2
++ rm -f ${DESTDIR}${PREFIX}/bin/dzen2
+
+ .PHONY: all options clean dist install uninstall
+--- a/config.mk
++++ b/config.mk
+@@ -4,7 +4,7 @@
+ # Customize below to fit your system
+
+ # paths
+-PREFIX = /usr/local
++PREFIX = /usr
+ MANPREFIX = ${PREFIX}/share/man
+
+ X11INC = /usr/X11R6/include
+@@ -18,61 +18,12 @@
+ # Uncomment: Remove # from the beginning of respective lines
+ # Comment : Add # to the beginning of the respective lines
+
+-## Option 1: No Xinerama no XPM no XFT
+-#LIBS = -L/usr/lib -lc -L${X11LIB} -lX11
+-#CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\"
+-
+-
+-## Option 2: No Xinerama with XPM
+-#LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 -lXpm
+-#CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\" -DDZEN_XPM
+-
+-
+-# Option 3: With Xinerama no XPM
+-#LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 -lXinerama
+-#CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\" -DDZEN_XINERAMA
+-
+-
+-## Option 4: With Xinerama and XPM
+-#LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 -lXinerama -lXpm
+-#CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\" -DDZEN_XINERAMA -DDZEN_XPM
+-
+-
+-## Option 5: With XFT
+-LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 `pkg-config --libs xft`
+-CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\" -DDZEN_XFT `pkg-config --cflags xft`
+-
+-
+-## Option 6: With XPM and XFT
+-#LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 -lXpm `pkg-config --libs xft`
+-#CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\" -DDZEN_XPM -DDZEN_XFT `pkg-config --cflags xft`
+-
+-
+-## Option 7: With Xinerama and XFT
+-#LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 -lXinerama `pkg-config --libs xft`
+-#CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\" -DDZEN_XINERAMA -DDZEN_XFT `pkg-config --cflags xft`
+-
+-
+-## Option 8: With Xinerama and XPM and XFT
+-#LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 -lXinerama -lXpm `pkg-config --libs xft`
+-#CFLAGS = -Wall -Os ${INCS} -DVERSION=\"${VERSION}\" -DDZEN_XINERAMA -DDZEN_XPM -DDZEN_XFT `pkg-config --cflags xft`
+-
+-
++LIBS = -lX11
++CFLAGS += -Wall ${INCS} -DVERSION=\"${VERSION}\"
+
+ # END of feature configuration
+
+-
+-LDFLAGS = ${LIBS}
+-
+-# Solaris, uncomment for Solaris
+-#CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\"
+-#LDFLAGS = ${LIBS}
+-#CFLAGS += -xtarget=ultra
+-
+-# Debugging
+-#CFLAGS = ${INCS} -DVERSION=\"${VERSION}\" -std=gnu89 -pedantic -Wall -W -Wundef -Wendif-labels -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-align -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline -Wdisabled-optimization -O2 -pipe -DDZEN_XFT `pkg-config --cflags xft`
+-#LDFLAGS = ${LIBS}
++LDFLAGS += ${LIBS}
+
+ # compiler and linker
+-CC = gcc
+-LD = ${CC}
++LD = $(CC)
+--- a/gadgets/Makefile
++++ b/gadgets/Makefile
+@@ -12,61 +12,57 @@
+ @echo dzen2 gadgets build options:
+ @echo "CFLAGS = ${CFLAGS}"
+ @echo "LDFLAGS = ${LDFLAGS}"
+- @echo "CC = ${CC}"
++ @echo "CC = $(CC)"
+ @echo "LD = ${LD}"
+
+ .c.o:
+ @echo CC $<
+- @${CC} -c ${CFLAGS} $<
++ $(CC) -c ${CFLAGS} $<
+
+ ${OBJ}: dbar.h config.mk
+
+ dbar: ${OBJ}
+ @echo LD $@
+- @${LD} -o $@ dbar-main.o dbar.o ${LDFLAGS}
+- @strip $@
++ ${LD} -o $@ dbar-main.o dbar.o ${LDFLAGS}
+
+ gdbar: ${OBJ}
+ @echo LD $@
+ # @${LD} -o $@ gdbar.o dbar.o ${LDFLAGS} -L${X11LIB} -lX11
+- @${LD} -o $@ gdbar.o dbar.o ${LDFLAGS}
+- @strip $@
++ ${LD} -o $@ gdbar.o dbar.o ${LDFLAGS}
+
+ gcpubar: ${OBJ}
+ @echo LD $@
+ # @${LD} -o $@ gcpubar.o dbar.o ${LDFLAGS} -L${X11LIB}
+- @${LD} -o $@ gcpubar.o dbar.o ${LDFLAGS}
+- @strip $@
++ ${LD} -o $@ gcpubar.o dbar.o ${LDFLAGS}
+
+ textwidth: ${OBJ}
+ @echo LD $@
+- @${LD} -o $@ textwidth.o ${LDFLAGS} -L${X11LIB} -lX11
+- @strip $@
++ ${LD} -o $@ textwidth.o ${LDFLAGS} -L${X11LIB} -lX11
+
+ clean:
+ @echo cleaning
+- @rm -f ${OBJ} dbar
+- @rm -f ${OBJ} gdbar
+- @rm -f ${OBJ} gcpubar
+- @rm -f ${OBJ} textwidth
++ rm -f ${OBJ} dbar
++ rm -f ${OBJ} gdbar
++ rm -f ${OBJ} gcpubar
++ rm -f ${OBJ} textwidth
+
+ install: all
+ @echo installing executable file to ${DESTDIR}${PREFIX}/bin
+- @mkdir -p ${DESTDIR}${PREFIX}/bin
+- @cp -f dbar ${DESTDIR}${PREFIX}/bin
+- @chmod 755 ${DESTDIR}${PREFIX}/bin/dbar
+- @cp -f gdbar ${DESTDIR}${PREFIX}/bin
+- @chmod 755 ${DESTDIR}${PREFIX}/bin/gdbar
+- @cp -f gcpubar ${DESTDIR}${PREFIX}/bin
+- @chmod 755 ${DESTDIR}${PREFIX}/bin/gcpubar
+- @cp -f textwidth ${DESTDIR}${PREFIX}/bin
+- @chmod 755 ${DESTDIR}${PREFIX}/bin/textwidth
++ mkdir -p ${DESTDIR}${PREFIX}/bin
++ cp -f dbar ${DESTDIR}${PREFIX}/bin
++ chmod 755 ${DESTDIR}${PREFIX}/bin/dbar
++ cp -f gdbar ${DESTDIR}${PREFIX}/bin
++ chmod 755 ${DESTDIR}${PREFIX}/bin/gdbar
++ cp -f gcpubar ${DESTDIR}${PREFIX}/bin
++ chmod 755 ${DESTDIR}${PREFIX}/bin/gcpubar
++ cp -f textwidth ${DESTDIR}${PREFIX}/bin
++ chmod 755 ${DESTDIR}${PREFIX}/bin/textwidth
+
+ uninstall:
+ @echo removing executable file from ${DESTDIR}${PREFIX}/bin
+- @rm -f ${DESTDIR}${PREFIX}/bin/dbar
+- @rm -f ${DESTDIR}${PREFIX}/bin/gdbar
+- @rm -f ${DESTDIR}${PREFIX}/bin/gcpubar
+- @rm -f ${DESTDIR}${PREFIX}/bin/textwidth
++ rm -f ${DESTDIR}${PREFIX}/bin/dbar
++ rm -f ${DESTDIR}${PREFIX}/bin/gdbar
++ rm -f ${DESTDIR}${PREFIX}/bin/gcpubar
++ rm -f ${DESTDIR}${PREFIX}/bin/textwidth
+
+ .PHONY: all options clean install uninstall
+--- a/gadgets/config.mk
++++ b/gadgets/config.mk
+@@ -1,7 +1,7 @@
+ # Customize below to fit your system
+
+ # paths
+-PREFIX = /usr/local
++PREFIX = /usr
+ MANPREFIX = ${PREFIX}/share/man
+
+ X11INC = /usr/X11R6/include
+@@ -10,9 +10,8 @@
+ X11LIB = /usr/X11R6/lib
+ LIBS = -L/usr/lib
+
+-CFLAGS = -Os ${INCS}
+-LDFLAGS = ${LIBS}
++CFLAGS += ${INCS}
++LDFLAGS += ${LIBS}
+
+ # compiler and linker
+-CC = gcc
+ LD = ${CC}
--- /dev/null
+--- a/main.c
++++ b/main.c
+@@ -293,7 +293,6 @@
+ static void
+ set_docking_ewmh_info(Display *dpy, Window w, int dock) {
+ unsigned long strut[12] = { 0 };
+- unsigned long strut_s[4] = { 0 };
+ XWindowAttributes wa;
+ Atom type;
+ unsigned int desktop;
+@@ -339,8 +338,6 @@
+ strut[2] = si.y + wa.height;
+ strut[8] = wa.x;
+ strut[9] = wa.x + wa.width - 1;
+-
+- strut_s[2] = strut[2];
+ }
+ else if((wa.y - si.y + wa.height) == si.height) {
+ #ifdef DZEN_XINERAMA
+@@ -358,8 +355,6 @@
+ #endif
+ strut[10] = wa.x;
+ strut[11] = wa.x + wa.width - 1;
+-
+- strut_s[3] = strut[3];
+ }
+
+ if(strut[2] != 0 || strut[3] != 0) {
+@@ -832,11 +827,9 @@
+ XFreeStringList(missing);
+
+ if(dzen.fnpl[p].set) {
+- XFontSetExtents *font_extents;
+ XFontStruct **xfonts;
+ char **font_names;
+ dzen.fnpl[p].ascent = dzen.fnpl[p].descent = 0;
+- font_extents = XExtentsOfFontSet(dzen.fnpl[p].set);
+ n = XFontsOfFontSet(dzen.fnpl[p].set, &xfonts, &font_names);
+ for(i = 0, dzen.fnpl[p].ascent = 0, dzen.fnpl[p].descent = 0; i < n; i++) {
+ if(dzen.fnpl[p].ascent < (*xfonts)->ascent)
+--- a/gadgets/textwidth.c
++++ b/gadgets/textwidth.c
+@@ -62,11 +62,9 @@
+ if(missing)
+ XFreeStringList(missing);
+ if(font.set) {
+- XFontSetExtents *font_extents;
+ XFontStruct **xfonts;
+ char **font_names;
+ font.ascent = font.descent = 0;
+- font_extents = XExtentsOfFontSet(font.set);
+ n = XFontsOfFontSet(font.set, &xfonts, &font_names);
+ for(i = 0, font.ascent = 0, font.descent = 0; i < n; i++) {
+ if(font.ascent < (*xfonts)->ascent)
+--- a/gadgets/gcpubar.c
++++ b/gadgets/gcpubar.c
+@@ -40,7 +40,6 @@
+
+ int main(int argc, char *argv[]) {
+ int i, t;
+- double total;
+ struct cpu_info mcpu;
+ FILE *statfp;
+ char buf[256], *ep;
+@@ -149,7 +148,6 @@
+ while(fgets(buf, sizeof buf, statfp)) {
+ if(!strncmp(buf, "cpu ", 4)) {
+ unsigned long long unice;
+- double myload;
+ /* linux >= 2.6 */
+ if((sscanf(buf, "cpu %llu %llu %llu %llu %llu",
+ &ncpu.user, &unice, &ncpu.sys, &ncpu.idle, &ncpu.iowait)) < 5) {