From owner-freebsd-ports@freebsd.org Fri Jun 16 17:34:23 2017 Return-Path: Delivered-To: freebsd-ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D0D2AC790EC; Fri, 16 Jun 2017 17:34:23 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (troutmask.apl.washington.edu [128.95.76.21]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "troutmask", Issuer "troutmask" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id B26B664784; Fri, 16 Jun 2017 17:34:23 +0000 (UTC) (envelope-from sgk@troutmask.apl.washington.edu) Received: from troutmask.apl.washington.edu (localhost [127.0.0.1]) by troutmask.apl.washington.edu (8.15.2/8.15.2) with ESMTPS id v5GHYM45038833 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Fri, 16 Jun 2017 10:34:22 -0700 (PDT) (envelope-from sgk@troutmask.apl.washington.edu) Received: (from sgk@localhost) by troutmask.apl.washington.edu (8.15.2/8.15.2/Submit) id v5GHYMFh038832; Fri, 16 Jun 2017 10:34:22 -0700 (PDT) (envelope-from sgk) Date: Fri, 16 Jun 2017 10:34:22 -0700 From: Steve Kargl To: Mathieu Arnold Cc: freebsd-ports@freebsd.org, freebsd-hackers@freebsd.org Subject: Re: JAVA_VERSION??? Message-ID: <20170616173422.GA38774@troutmask.apl.washington.edu> Reply-To: sgk@troutmask.apl.washington.edu References: <20170615234533.GA2871@troutmask.apl.washington.edu> <582b49d8-5910-35b5-40ed-307475830a64@FreeBSD.org> <20170616144318.GA11287@troutmask.apl.washington.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.7.2 (2016-11-26) X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Jun 2017 17:34:23 -0000 On Fri, Jun 16, 2017 at 05:07:30PM +0200, Mathieu Arnold wrote: > Le 16/06/2017 à 16:43, Steve Kargl a écrit : > > On Fri, Jun 16, 2017 at 02:17:03PM +0200, Mathieu Arnold wrote: > >> Le 16/06/2017 à 01:45, Steve Kargl a écrit : > >>> Is this the expected behavior? > >>> > >>> % cd ports/math/octave > >>> % make fetch > >>> octave-4.0.3_5: Makefile error: "1.7+" is not a valid value for JAVA_VERSION. It should be one or more of: 1.6 1.7 1.8 (with an optional "+" suffix.) > >>> % grep JAVA_VERSION Makefile > >>> JAVA_VERSION= 1.7+ > >> > >> Not really. What OSVERSION are you running? > >> > >> What is the content of the _JAVA_VERSION_LIST and > >> _JAVA_VERSION_LIST_REGEXP variables ? > >> > > I'm running a month old freebsd-current. > > > > % uname -a > > FreeBSD troutmask.apl.washington.edu 12.0-CURRENT FreeBSD 12.0-CURRENT > > #0 r318546: Fri May 19 12:51:04 PDT 2017 > > > > % cd /usr/ports/math/octave > > % make -d v fetch |& grep JAVA_VERSION > > $ make -V _JAVA_VERSION_LIST > 1.6 1.7 1.8 1.6+ 1.7+ 1.8+ > $ make -V _JAVA_VERSION_LIST_REGEXP > 1.6\|1.7\|1.8\|1.6+\|1.7+\|1.8+ > > You should get the same as me. I wonder if it is not a difference in how > grep behaves on 12 where it does not match 1.7+ with the regexp in there. > Yes, it appears to be a grep issue. In Mk/bsd.java.mk, I removed the @ in line 227 to see what the test did. I then try to reproduce just the part with grep (without the -q option) at a Bourne shell prompt. # echo "1.7+" 1.7+ # echo "1.7+" | /usr/bin/tr " " "\n" 1.7+ # echo "1.7+" | /usr/bin/tr " " "\n" | /usr/bin/grep "1.6\|1.7\|1.8\|1.6+\|1.7+\|1.8+" # So, nothing is returned. If I reduce the regex pattern, I see # echo "1.7+" | /usr/bin/tr " " "\n" | /usr/bin/grep "1.7+" 1.7+ -- Steve 20170425 https://www.youtube.com/watch?v=VWUpyCsUKR4 20161221 https://www.youtube.com/watch?v=IbCHE-hONow