From owner-freebsd-ports-bugs@FreeBSD.ORG Sun Sep 13 00:30:04 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 C33DF106568B for ; Sun, 13 Sep 2009 00:30: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 8677F8FC19 for ; Sun, 13 Sep 2009 00:30:04 +0000 (UTC) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n8D0U4J2060905 for ; Sun, 13 Sep 2009 00:30:04 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n8D0U3tw060904; Sun, 13 Sep 2009 00:30:03 GMT (envelope-from gnats) Resent-Date: Sun, 13 Sep 2009 00:30:03 GMT Resent-Message-Id: <200909130030.n8D0U3tw060904@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, Gerald Pfeifer Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E5603106566C for ; Sun, 13 Sep 2009 00:27:22 +0000 (UTC) (envelope-from pfeifer@sputnik1.dbai.tuwien.ac.at) Received: from sputnik1.dbai.tuwien.ac.at (sputnik1.dbai.tuwien.ac.at [128.131.111.141]) by mx1.freebsd.org (Postfix) with ESMTP id 7C35F8FC16 for ; Sun, 13 Sep 2009 00:27:21 +0000 (UTC) Received: from sputnik1.dbai.tuwien.ac.at (localhost [127.0.0.1]) by sputnik1.dbai.tuwien.ac.at (8.14.3/8.14.3) with ESMTP id n8D0RKhP017494; Sun, 13 Sep 2009 02:27:20 +0200 (CEST) (envelope-from pfeifer@sputnik1.dbai.tuwien.ac.at) Received: (from pfeifer@localhost) by sputnik1.dbai.tuwien.ac.at (8.14.3/8.14.3/Submit) id n8D0RK5Y017390; Sun, 13 Sep 2009 02:27:20 +0200 (CEST) (envelope-from pfeifer) Message-Id: <200909130027.n8D0RK5Y017390@sputnik1.dbai.tuwien.ac.at> Date: Sun, 13 Sep 2009 02:27:20 +0200 (CEST) From: Gerald Pfeifer To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: ports/138774: Tools/bump_revision.pl incorrectly handled REVISION?= 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: Sun, 13 Sep 2009 00:30:04 -0000 >Number: 138774 >Category: ports >Synopsis: Tools/bump_revision.pl incorrectly handled REVISION?= >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Sep 13 00:30:03 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Gerald Pfeifer >Release: FreeBSD 7.2-RELEASE-p2 i386 >Organization: >Environment: >Description: This first happened in January when I chased PORTREVISIONs for all ports with USE_FORTRAN=yes. I reported it by mail back then, yet just ran into this again so I had a look into the actual code. The problem is that for a port with PORTREVISION?=n, bump_revision.pl will not bump n to n+1, but reset to 1. The bug is in extracting the version number properly, and it seems the one line patch below fixes it. Is this okay to commit? >How-To-Repeat: I tested the patch both on math/fftw and lang/gcc34 to cover various cases. >Fix: Index: bump_revision.pl =================================================================== RCS file: /home/pcvs/ports/Tools/scripts/bump_revision.pl,v retrieving revision 1.4 diff -u -3 -p -r1.4 bump_revision.pl --- bump_revision.pl 7 Jan 2009 21:33:17 -0000 1.4 +++ bump_revision.pl 13 Sep 2009 00:18:39 -0000 @@ -46,7 +49,7 @@ sub bumpMakefile { foreach my $line (@lines) { last if ($line =~ /^MAINTAINER/); - $revision += $1 if ($line =~ /PORTREVISION??=[ \t]*(\d+)$/); + $revision += $1 if ($line =~ /PORTREVISION\??=[ \t]*(\d+)$/); } my $printedrev = 0; >Release-Note: >Audit-Trail: >Unformatted: