From owner-freebsd-ports-bugs@FreeBSD.ORG Fri Jul 4 20:20:04 2008 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 ACA01106566C for ; Fri, 4 Jul 2008 20:20:04 +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 889FD8FC2B for ; Fri, 4 Jul 2008 20:20:04 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.2/8.14.2) with ESMTP id m64KK4UJ008080 for ; Fri, 4 Jul 2008 20:20:04 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.2/8.14.1/Submit) id m64KK4a0008079; Fri, 4 Jul 2008 20:20:04 GMT (envelope-from gnats) Resent-Date: Fri, 4 Jul 2008 20:20:04 GMT Resent-Message-Id: <200807042020.m64KK4a0008079@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, Yi-Jheng Lin Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E17E21065673; Fri, 4 Jul 2008 20:12:34 +0000 (UTC) (envelope-from yzlin@cs.nctu.edu.tw) Received: from csmailgate.cs.nctu.edu.tw (csmailgate.cs.nctu.edu.tw [140.113.235.103]) by mx1.freebsd.org (Postfix) with ESMTP id AF8688FC0A; Fri, 4 Jul 2008 20:12:34 +0000 (UTC) (envelope-from yzlin@cs.nctu.edu.tw) Received: from stucgi.cs.nctu.edu.tw (stucgi [140.113.235.130]) by csmailgate.cs.nctu.edu.tw (Postfix) with ESMTP id F0E9D12B29E; Sat, 5 Jul 2008 04:12:32 +0800 (CST) Received: (from yzlin@localhost) by stucgi.cs.nctu.edu.tw (8.14.2/8.14.2/Submit) id m64K5Wcq068184; Sat, 5 Jul 2008 04:05:32 +0800 (CST) (envelope-from yzlin) Message-Id: <200807042005.m64K5Wcq068184@stucgi.cs.nctu.edu.tw> Date: Sat, 5 Jul 2008 04:05:32 +0800 (CST) From: Yi-Jheng Lin To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: ale@FreeBSD.org Subject: ports/125273: [PATCH] ports-mgmt/portconf: new feature "Undefine variables" 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: Fri, 04 Jul 2008 20:20:04 -0000 >Number: 125273 >Category: ports >Synopsis: [PATCH] ports-mgmt/portconf: new feature "Undefine variables" >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Fri Jul 04 20:20:04 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Yi-Jheng Lin >Release: FreeBSD 7.0-RELEASE-p1 amd64 >Organization: NCTU CS >Environment: System: FreeBSD stucgi 7.0-RELEASE-p1 FreeBSD 7.0-RELEASE-p1 #0: Thu Apr 17 15:56:39 CST 2008 >Description: Add a new feature "Undefine variables", which could undefine a variable by adding a symbol '!' before variables. The following is an example. ports.conf: *: WITHOUT_X11=yes graphics/cairo: !WITHOUT_X11 In this setting, every port will install with WITHOUT_X11. But, when we install graphics/cairo, WITHOUT_X11 will be undefined. This could solve the problem when compiling x11-toolkits/gtk20 (via textproc/wv) with graphics/cairo installed with WITHOUT_X11. We'll get the error message: gdkdrawable-x11.c:32:24: cairo-xlib.h: No such file or directory This feature is useful when we want to define a variable for most ports but not every. Port maintainer (ale@FreeBSD.org) is cc'd. Generated with FreeBSD Port Tools 0.77 >How-To-Repeat: >Fix: --- portconf-1.4.patch begins here --- diff -ruN --exclude=CVS /usr/ports/ports-mgmt/portconf/Makefile /amd/account/gcs/96/9655630/dev/ports/ports-mgmt/portconf/Makefile --- /usr/ports/ports-mgmt/portconf/Makefile 2007-10-03 00:50:07.000000000 +0800 +++ /amd/account/gcs/96/9655630/dev/ports/ports-mgmt/portconf/Makefile 2008-07-05 03:04:02.000000000 +0800 @@ -8,7 +8,7 @@ # PORTNAME= portconf -PORTVERSION= 1.3 +PORTVERSION= 1.4 CATEGORIES= ports-mgmt MASTER_SITES= # none DISTFILES= # none diff -ruN --exclude=CVS /usr/ports/ports-mgmt/portconf/files/portconf.sh.in /amd/account/gcs/96/9655630/dev/ports/ports-mgmt/portconf/files/portconf.sh.in --- /usr/ports/ports-mgmt/portconf/files/portconf.sh.in 2007-09-24 03:26:33.000000000 +0800 +++ /amd/account/gcs/96/9655630/dev/ports/ports-mgmt/portconf/files/portconf.sh.in 2008-07-05 02:43:31.000000000 +0800 @@ -36,7 +36,7 @@ sed '/^#/d;/^[[:space:]]*$/d' "${_conf}" | while read _line; do for _port in ${_line%%:*}; do if [ "${_pwd%%${_port}}" != "${_pwd}" ]; then - echo ${_line#*:} | sed -E 's/([A-Z0-9_]+)(=([^|]+))?/\1=\3/g;s/ *\| */|/g;s/ /%/g' + echo ${_line#*:} | sed -E 's/(!?[A-Z0-9_]+)(=([^|]+))?/\1=\3/g;s/ *\| */|/g;s/ /%/g' fi done done diff -ruN --exclude=CVS /usr/ports/ports-mgmt/portconf/pkg-install /amd/account/gcs/96/9655630/dev/ports/ports-mgmt/portconf/pkg-install --- /usr/ports/ports-mgmt/portconf/pkg-install 2007-06-23 03:11:03.000000000 +0800 +++ /amd/account/gcs/96/9655630/dev/ports/ports-mgmt/portconf/pkg-install 2008-07-05 02:45:36.000000000 +0800 @@ -11,6 +11,7 @@ .if !empty(.CURDIR:M${PORTS_DIR}*) && exists(${PKG_PREFIX}/libexec/portconf) _PORTCONF!=${PKG_PREFIX}/libexec/portconf .for i in \${_PORTCONF:S/|/ /g} +\${i:C/!([A-Z0-9_]+)(=([^ ]+)?)?/.undef \1/g} \${i:S/%/ /g} .endfor .endif --- portconf-1.4.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted: