From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Feb 15 15:50:03 2010 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 EFDB51065695 for ; Mon, 15 Feb 2010 15:50:02 +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 B464D8FC19 for ; Mon, 15 Feb 2010 15:50:02 +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 o1FFo212016956 for ; Mon, 15 Feb 2010 15:50:02 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id o1FFo2Ur016955; Mon, 15 Feb 2010 15:50:02 GMT (envelope-from gnats) Resent-Date: Mon, 15 Feb 2010 15:50:02 GMT Resent-Message-Id: <201002151550.o1FFo2Ur016955@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, pluknet Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C1B601065692 for ; Mon, 15 Feb 2010 15:46:16 +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 B146C8FC19 for ; Mon, 15 Feb 2010 15:46:16 +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 o1FFkG7i037381 for ; Mon, 15 Feb 2010 15:46:16 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id o1FFkGCM037379; Mon, 15 Feb 2010 15:46:16 GMT (envelope-from nobody) Message-Id: <201002151546.o1FFkGCM037379@www.freebsd.org> Date: Mon, 15 Feb 2010 15:46:16 GMT From: pluknet To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: ports/143955: 'make search' doesn't skip comments in /usr/ports/MOVED 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: Mon, 15 Feb 2010 15:50:03 -0000 >Number: 143955 >Category: ports >Synopsis: 'make search' doesn't skip comments in /usr/ports/MOVED >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Feb 15 15:50:02 UTC 2010 >Closed-Date: >Last-Modified: >Originator: pluknet >Release: FreeBSD 7.2-STABLE i386 >Organization: >Environment: FreeBSD host 7.2-STABLE FreeBSD 7.2-STABLE #4: Wed Jan 13 11:26:44 MSK 2010 root@host:/usr/obj/usr/home/pluknet/cvs-7/src/sys/JAW i386 >Description: Abstract: When ports are moved, renamed or deleted, they're added to /usr/ports/MOVED. ports/104161 let 'make search' also search in /usr/ports/MOVED Problem: 'make search' also searches in /usr/ports/MOVED's comments. While here, there's an unwrapped line around my generated diff (see attached patch), which would be nice to fix as well. >How-To-Repeat: Specify name's argument in 'make search' to match something that's in MOVED's comments. # make search name=MOVED Port: # MOVED - a list of (recently) moved or removed ports Moved: Date: Reason: Port: # Moved to: Where the port was moved to, or which port users Moved: Date: Reason: Port: # Why: The reason why the port was moved or removed. Moved: Date: Reason: Port: # If previously removed port gets restored, make sure to delete the relevant Moved: Date: Reason: >Fix: Apply the patch. Patch attached with submission follows: --- Mk/bsd.port.subdir.mk.orig 2010-02-15 18:31:30.000000000 +0300 +++ Mk/bsd.port.subdir.mk 2010-02-15 18:33:10.000000000 +0300 @@ -517,8 +517,10 @@ } \ { \ oldname = $$1; newname = $$2; \ + if (oldname ~ /^\#/) next; \ sub(".*\/", "", oldname); newname = sub(".*\/", "", newname); \ - if (((icase ? tolower(oldname) : oldname) ~ name) || ((icase ? tolower(newname) : newname) ~ name)) { \ + if (((icase ? tolower(oldname) : oldname) ~ name) || \ + ((icase ? tolower(newname) : newname) ~ name)) { \ for (i = 1; i <= 4; i++) { \ printf("%s:\t%s\n", names[i], $$i); \ } \ >Release-Note: >Audit-Trail: >Unformatted: