Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 19 Mar 2011 16:51:14 GMT
From:      Pavel Gubin <pg@2lazy.ru>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/155697: ports-mgmt/pkg_replace doesn't want to replace java/openjdk6
Message-ID:  <201103191651.p2JGpEt8038745@red.freebsd.org>
Resent-Message-ID: <201103191700.p2JH0Etg009113@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         155697
>Category:       ports
>Synopsis:       ports-mgmt/pkg_replace doesn't want to replace java/openjdk6
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Mar 19 17:00:14 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator:     Pavel Gubin
>Release:        8.2-RELEASE
>Organization:
Lazy.
>Environment:
>Description:
ports-mgmt/pkg_replace fails to replace java/openjdk6 because current version of openjdk6 is "openjdk6-b22_3", and it does not match globbing pattern in pkg_glob function.
>How-To-Repeat:
pkg_replace openjdk6

or

pkg_replace openjdk6-b22_3
>Fix:
This patch is just an ugly kludge and does not fix globbing logic; there should be a better way.


Patch attached with submission follows:

--- pkg_replace.orig	2010-08-21 22:33:21.000000000 +0400
+++ pkg_replace	2011-03-19 19:30:16.000000000 +0300
@@ -442,7 +442,7 @@
 		_pattern=${_arg#${PKG_DBDIR}/}
 
 		case ${_pattern} in
-		*\**|*-pl[0-9]*|*-[0-9]*[0-9.][a-z]|*-[0-9]*[0-9]) ;;
+		*\**|*-pl[0-9]*|*-b[0-9]*|*-[0-9]*[0-9.][a-z]|*-[0-9]*[0-9]) ;;
 		*)		_pattern="${_pattern}-[0-9]*[0-9a-z]" ;;
 		esac
 


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201103191651.p2JGpEt8038745>