From owner-freebsd-java@FreeBSD.ORG Fri Apr 8 19:48:11 2011 Return-Path: Delivered-To: freebsd-java@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9679E1065677; Fri, 8 Apr 2011 19:48:11 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 67B0B8FC0A; Fri, 8 Apr 2011 19:48:11 +0000 (UTC) Received: from bigwig.baldwin.cx (66.111.2.69.static.nyinternet.net [66.111.2.69]) by cyrus.watson.org (Postfix) with ESMTPSA id 09DBA46B46; Fri, 8 Apr 2011 15:48:11 -0400 (EDT) Received: from jhbmac.hudson-trading.com (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 77E928A027; Fri, 8 Apr 2011 15:48:10 -0400 (EDT) Message-ID: <4D9F667A.90302@FreeBSD.org> Date: Fri, 08 Apr 2011 15:48:10 -0400 From: John Baldwin User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.15) Gecko/20110303 Thunderbird/3.1.9 MIME-Version: 1.0 To: Jung-uk Kim References: <4D9F1E05.4070900@FreeBSD.org> <201104081511.47184.jkim@FreeBSD.org> In-Reply-To: <201104081511.47184.jkim@FreeBSD.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.6 (bigwig.baldwin.cx); Fri, 08 Apr 2011 15:48:10 -0400 (EDT) Cc: freebsd-java@freebsd.org Subject: Re: Version number of openjdk6 port X-BeenThere: freebsd-java@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting Java to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Apr 2011 19:48:11 -0000 On 4/8/11 3:11 PM, Jung-uk Kim wrote: > On Friday 08 April 2011 10:39 am, John Baldwin wrote: >> Please consider using a better version number for the openjdk6 >> port. Right now it uses a version number of 'b20_7' which due to >> the way package version works, is considered less than 0: >> >> % pkg_version -t 0 b20_7 >> >> >> Why does this matter? cfengine uses 'pkg_info -E pkg_name>0' to >> test if a package is installed. > > Then, I would say cfengine is broken. "0" in that version match string > is package dependent, not major, minor, or whatever. For example: > > %pkg_info -E 'avahi>0.6.20' > avahi-0.6.29 > %pkg_info -E 'openjdk6>b0' > openjdk6-b22_4 > %pkg_info -E 'mplayer>1.0.r0' > mplayer-1.0.r20110329 Hmm, I can probably workaround this then using an explicit comparison rule (so it doesn't use >0). It would be nice if we had an official way to match a package with "any version". Perhaps "pkg_info -E 'pkg-*'" if we assume that package names can never have dashes in them (to avoid problems, with, say, 'foo-*' matching both foo-1.0 and foo-bar-1.0.). Oh, we already have those types of packages: xorg-7.5 X.Org complete distribution metaport xorg-apps-7.5_1 X.org apps meta-port The problem is how can software generically say "is any version of the foo package installed". It would seem we don't support that currently? -- John Baldwin