From owner-freebsd-ports-bugs@FreeBSD.ORG Sat Oct 31 00:00:16 2009 Return-Path: Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 46B0110656D1 for ; Sat, 31 Oct 2009 00:00:16 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id B8A888FC27 for ; Sat, 31 Oct 2009 00:00:15 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n9V00FpB044678 for ; Sat, 31 Oct 2009 00:00:15 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n9V00FKr044677; Sat, 31 Oct 2009 00:00:15 GMT (envelope-from gnats) Resent-Date: Sat, 31 Oct 2009 00:00:15 GMT Resent-Message-Id: <200910310000.n9V00FKr044677@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Aragon Gouveia Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A59FE1065676 for ; Fri, 30 Oct 2009 23:57:09 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id 931B28FC15 for ; Fri, 30 Oct 2009 23:57:09 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n9UNv9rj088114 for ; Fri, 30 Oct 2009 23:57:09 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id n9UNv8qC088113; Fri, 30 Oct 2009 23:57:08 GMT (envelope-from nobody) Message-Id: <200910302357.n9UNv8qC088113@www.freebsd.org> Date: Fri, 30 Oct 2009 23:57:08 GMT From: Aragon Gouveia To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/140127: [patch] x11-wm/scrotwm version upgrade 0.9.19 X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 31 Oct 2009 00:00:16 -0000 >Number: 140127 >Category: ports >Synopsis: [patch] x11-wm/scrotwm version upgrade 0.9.19 >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: maintainer-update >Submitter-Id: current-users >Arrival-Date: Sat Oct 31 00:00:14 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Aragon Gouveia >Release: 8.0-RC2 >Organization: >Environment: FreeBSD fuzz.geek.sh 8.0-RC2 FreeBSD 8.0-RC2 #0: Fri Oct 30 03:05:28 SAST 2009 toor@fuzz.geek.sh:/usr/obj/usr/src/sys/FUZZ amd64 >Description: scrotwm version upgrade Please: - apply attached patch - remove files/spawn_menu_colourfix.patch Thank you to Joel Dahl for testing/troubleshooting. >How-To-Repeat: >Fix: Patch attached with submission follows: diff -uNr scrotwm.orig/Makefile scrotwm/Makefile --- scrotwm.orig/Makefile 2009-07-01 21:06:37.000000000 +0200 +++ scrotwm/Makefile 2009-10-31 01:45:36.000000000 +0200 @@ -6,7 +6,7 @@ # PORTNAME= scrotwm -PORTVERSION= 0.9.5 +PORTVERSION= 0.9.19 CATEGORIES= x11-wm MASTER_SITES= http://www.peereboom.us/scrotwm/snapshot/ \ ${MASTER_SITE_LOCAL} @@ -17,7 +17,6 @@ COMMENT= A small, dynamic tiling window manager for X11 OPTIONS= DMENU "Depend on x11/dmenu" On \ - DMENU_COLFIX "Fix inverted/select colour on dmenu" On \ DMENU_BOTTOM "dmenu at screen bottom (instead of top)" Off \ CLOCKFORMAT "Configurable strftime(3) clock format" Off @@ -27,14 +26,11 @@ USE_XLIB= yes MAN1= scrotwm.1 -PLIST_FILES= bin/scrotwm lib/swmhack.so etc/scrotwm.conf +PLIST_FILES= bin/scrotwm lib/libswmhack.so etc/scrotwm.conf .if defined(WITH_DMENU) RUN_DEPENDS= dmenu:${PORTSDIR}/x11/dmenu .endif -.if defined(WITH_DMENU_COLFIX) -EXTRA_PATCHES+= ${FILESDIR}/spawn_menu_colourfix.patch -.endif .if defined(WITH_DMENU_BOTTOM) EXTRA_PATCHES+= ${FILESDIR}/spawn_menu_atbottom.patch .endif @@ -47,11 +43,11 @@ -I${WRKSRC}/linux -lutil -L${X11BASE}/lib -lX11 -lXrandr \ -o ${WRKSRC}/${PORTNAME} ${WRKSRC}/${PORTNAME}.c ${CC} ${CFLAGS} -I${X11BASE}/include -shared -fPIC \ - -o ${WRKSRC}/swmhack.so ${WRKSRC}/lib/swm_hack.c + -o ${WRKSRC}/libswmhack.so ${WRKSRC}/lib/swm_hack.c do-install: ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin - ${INSTALL_DATA} ${WRKSRC}/swmhack.so ${PREFIX}/lib + ${INSTALL_DATA} ${WRKSRC}/libswmhack.so ${PREFIX}/lib ${INSTALL_DATA} ${WRKSRC}/scrotwm.conf ${PREFIX}/etc ${INSTALL_MAN} ${WRKSRC}/scrotwm.1 ${PREFIX}/man/man1 diff -uNr scrotwm.orig/distinfo scrotwm/distinfo --- scrotwm.orig/distinfo 2009-07-01 21:06:37.000000000 +0200 +++ scrotwm/distinfo 2009-10-30 01:25:08.000000000 +0200 @@ -1,3 +1,3 @@ -MD5 (scrotwm-0.9.5.tgz) = d0ae2cdcaefa953627a250a183261670 -SHA256 (scrotwm-0.9.5.tgz) = 35a7e3ab805fc680459390e2e165f224268cec39bceb9679385c86a3054035ae -SIZE (scrotwm-0.9.5.tgz) = 36134 +MD5 (scrotwm-0.9.19.tgz) = a7af5038fac7e42e8d8cf5ed2d4a6da2 +SHA256 (scrotwm-0.9.19.tgz) = ea150eac5fe71f6e5c6284bfb9b96d94f0c1e05b3998d124218de84f1c49aee1 +SIZE (scrotwm-0.9.19.tgz) = 48706 diff -uNr scrotwm.orig/files/clock_format.patch scrotwm/files/clock_format.patch --- scrotwm.orig/files/clock_format.patch 2009-07-01 21:06:38.000000000 +0200 +++ scrotwm/files/clock_format.patch 2009-10-24 16:59:24.000000000 +0200 @@ -1,51 +1,79 @@ ---- scrotwm.c.orig 2009-06-29 03:46:08.000000000 +0200 -+++ scrotwm.c 2009-06-28 10:07:24.000000000 +0200 -@@ -182,6 +182,7 @@ - int bar_verbose = 1; +--- scrotwm.c.orig 2009-10-24 16:21:19.000000000 +0200 ++++ scrotwm.c 2009-10-24 16:58:55.000000000 +0200 +@@ -193,6 +193,7 @@ int bar_height = 0; + int stack_enabled = 1; int clock_enabled = 1; -+char clock_format[31] = "%a %b %d %R %Z %Y"; ++char *clock_format = NULL; + int title_name_enabled = 0; + int title_class_enabled = 0; pid_t bar_pid; - GC bar_gc; - XGCValues bar_gcv; -@@ -557,6 +558,7 @@ - - /* conf file stuff */ - #define SWM_CONF_WS "\n= \t" -+#define SWM_CONF_VAL_WS "\n\t" - #define SWM_CONF_FILE "scrotwm.conf" - int - conf_load(char *filename) -@@ -594,7 +596,7 @@ - if ((var = strsep(&cp, SWM_CONF_WS)) == NULL || cp == NULL) - break; - cp += (long)strspn(cp, SWM_CONF_WS); -- if ((val = strsep(&cp, SWM_CONF_WS)) == NULL) -+ if ((val = strsep(&cp, SWM_CONF_VAL_WS)) == NULL) - break; - - DNPRINTF(SWM_D_MISC, "conf_load: %s=%s\n",var ,val); -@@ -624,6 +626,8 @@ - case 'c': - if (!strncmp(var, "clock_enabled", strlen("clock_enabled"))) - clock_enabled = atoi(val); -+ else if (!strncmp(var, "clock_format", strlen("clock_format"))) -+ strlcpy(clock_format, val, 31); - else if (!varmatch(var, "color_focus", &i)) - setscreencolor(val, i, SWM_S_COLOR_FOCUS); - else if (!varmatch(var, "color_unfocus", &i)) -@@ -779,12 +783,12 @@ +@@ -839,7 +840,7 @@ else { time(&tmt); localtime_r(&tmt, &tm); - strftime(s, sizeof s, "%a %b %d %R %Z %Y ", &tm); + strftime(s, sizeof s, clock_format, &tm); } + for (i = 0; i < ScreenCount(display); i++) { - x = 1; - TAILQ_FOREACH(r, &screens[i].rl, entry) { -- snprintf(loc, sizeof loc, "%d:%d %s%s %s", -+ snprintf(loc, sizeof loc, "%d:%d %s %s %s", - x++, r->ws->idx + 1, s, bar_ext, bar_vertext); +@@ -851,7 +852,7 @@ + if (stack_enabled) + stack = r->ws->cur_layout->name; + +- snprintf(loc, sizeof loc, "%d:%d %s %s %s %s", ++ snprintf(loc, sizeof loc, "%d:%d %s %s %s %s", + x++, r->ws->idx + 1, stack, s, bar_ext, + bar_vertext); bar_print(r, loc); - } +@@ -3293,10 +3294,11 @@ + #define SWM_CONF_FILE "scrotwm.conf" + + enum { SWM_S_BAR_DELAY, SWM_S_BAR_ENABLED, SWM_S_STACK_ENABLED, +- SWM_S_CLOCK_ENABLED, SWM_S_CYCLE_EMPTY, SWM_S_CYCLE_VISIBLE, +- SWM_S_SS_ENABLED, SWM_S_TERM_WIDTH, SWM_S_TITLE_CLASS_ENABLED, +- SWM_S_TITLE_NAME_ENABLED, SWM_S_BAR_FONT, SWM_S_BAR_ACTION, +- SWM_S_SPAWN_TERM, SWM_S_SS_APP, SWM_S_DIALOG_RATIO }; ++ SWM_S_CLOCK_ENABLED, SWM_S_CLOCK_FORMAT, SWM_S_CYCLE_EMPTY, ++ SWM_S_CYCLE_VISIBLE, SWM_S_SS_ENABLED, SWM_S_TERM_WIDTH, ++ SWM_S_TITLE_CLASS_ENABLED, SWM_S_TITLE_NAME_ENABLED, ++ SWM_S_BAR_FONT, SWM_S_BAR_ACTION, SWM_S_SPAWN_TERM, ++ SWM_S_SS_APP, SWM_S_DIALOG_RATIO }; + + int + setconfvalue(char *selector, char *value, int flags) +@@ -3314,6 +3316,12 @@ + case SWM_S_CLOCK_ENABLED: + clock_enabled = atoi(value); + break; ++ case SWM_S_CLOCK_FORMAT: ++ if (clock_format != NULL) ++ free(clock_format); ++ if ((clock_format = strdup(value)) == NULL) ++ err(1, "setconfvalue: clock_format"); ++ break; + case SWM_S_CYCLE_EMPTY: + cycle_empty = atoi(value); + break; +@@ -3407,6 +3415,7 @@ + { "bind", setconfbinding, 0 }, + { "stack_enabled", setconfvalue, SWM_S_STACK_ENABLED }, + { "clock_enabled", setconfvalue, SWM_S_CLOCK_ENABLED }, ++ { "clock_format", setconfvalue, SWM_S_CLOCK_FORMAT }, + { "color_focus", setconfcolor, SWM_S_COLOR_FOCUS }, + { "color_unfocus", setconfcolor, SWM_S_COLOR_UNFOCUS }, + { "cycle_empty", setconfvalue, SWM_S_CYCLE_EMPTY }, +@@ -4468,6 +4477,13 @@ + if (cfile) + conf_load(cfile); + ++ if (clock_format == NULL) { ++ if ((clock_format = strdup("%a %b %d %R %Z %Y")) ++ == NULL) { ++ errx(1, "strdup"); ++ } ++ } ++ + /* setup all bars */ + for (i = 0; i < ScreenCount(display); i++) + TAILQ_FOREACH(r, &screens[i].rl, entry) { diff -uNr scrotwm.orig/files/spawn_menu_atbottom.patch scrotwm/files/spawn_menu_atbottom.patch --- scrotwm.orig/files/spawn_menu_atbottom.patch 2009-07-01 21:06:38.000000000 +0200 +++ scrotwm/files/spawn_menu_atbottom.patch 2009-10-24 07:11:38.000000000 +0200 @@ -1,11 +1,12 @@ ---- scrotwm.c.orig 2009-06-29 03:46:08.000000000 +0200 -+++ scrotwm.c 2009-06-28 10:07:24.000000000 +0200 -@@ -199,7 +200,7 @@ - char *spawn_lock[] = { "xlock", NULL }; - char *spawn_initscr[] = { "initscreen.sh", NULL }; - char *spawn_menu[] = { "dmenu_run", "-fn", NULL, "-nb", NULL, -- "-nf", NULL, "-sb", NULL, "-sf", NULL, NULL }; -+ "-nf", NULL, "-sb", NULL, "-sf", NULL, "-b", NULL }; +--- scrotwm.c.orig 2009-10-24 07:10:36.000000000 +0200 ++++ scrotwm.c 2009-10-24 07:11:10.000000000 +0200 +@@ -2812,7 +2812,8 @@ + " -nb $bar_color" + " -nf $bar_font_color" + " -sb $bar_border" +- " -sf $bar_color", 0); ++ " -sf $bar_color" ++ " -b", 0); + } - #define SWM_MENU_FN (2) - #define SWM_MENU_NB (4) + /* key bindings */ diff -uNr scrotwm.orig/files/spawn_menu_colourfix.patch scrotwm/files/spawn_menu_colourfix.patch --- scrotwm.orig/files/spawn_menu_colourfix.patch 2009-07-01 21:06:38.000000000 +0200 +++ scrotwm/files/spawn_menu_colourfix.patch 1970-01-01 02:00:00.000000000 +0200 @@ -1,11 +0,0 @@ ---- scrotwm.c.orig 2009-06-29 03:46:08.000000000 +0200 -+++ scrotwm.c 2009-06-28 10:07:24.000000000 +0200 -@@ -1139,7 +1143,7 @@ - spawn_menu[SWM_MENU_FN] = bar_fonts[bar_fidx]; - spawn_menu[SWM_MENU_NB] = r->s->c[SWM_S_COLOR_BAR].name; - spawn_menu[SWM_MENU_NF] = r->s->c[SWM_S_COLOR_BAR_FONT].name; -- spawn_menu[SWM_MENU_SB] = r->s->c[SWM_S_COLOR_BAR_BORDER].name; -+ spawn_menu[SWM_MENU_SB] = r->s->c[SWM_S_COLOR_BAR_FONT].name; - spawn_menu[SWM_MENU_SF] = r->s->c[SWM_S_COLOR_BAR].name; - - spawn(r, args); >Release-Note: >Audit-Trail: >Unformatted: