Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-08 Thread Daniel Fuchs
Hi Mike, sorry for not reacting sooner. I applied your patch on my machine, and now get the following: sh ./get_source.sh ./get_source.sh: line 70: [: too many arguments ./get_source.sh: line 76: [: `)' expected, found -1 ./get_source.sh: line 82: [: `)' expected, found -1 I have added: echo

Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-08 Thread Daniel Fuchs
Hi Mike, The issue seems to be that 'expr 0 + 0' writes 0 on stdout but has an exit status of 1 $ expr 0 + 0 0 $ echo $? 1 $ man expr EXPR(1) BSD General Commands Manual EXPR(1) [ ... ] DIAGNOSTICS The expr utility exits with one of the following values: 0 the expression

Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-08 Thread pointo1d
Hi Daniel , On 08/07/14 11:30, Daniel Fuchs wrote: Hi Mike, sorry for not reacting sooner. I applied your patch on my machine, and now get the following: sh ./get_source.sh ./get_source.sh: line 70: [: too many arguments ./get_source.sh: line 76: [: `)' expected, found -1 ./get_source.sh:

Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-08 Thread pointo1d
Hiya Daniel , On 08/07/14 13:15, Daniel Fuchs wrote: On 7/8/14 1:40 PM, pointo1d wrote: What do you see if you run the script using bash ? Just the same. best regards, -- daniel Try this ... #!/bin/sh -e # # Copyright (c) 2010, 2014, Oracle and/or its affiliates. All rights reserved.

Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-08 Thread Daniel Fuchs
Hi, Thanks Dave, yes - your patch works like a charm :-) best regards, -- daniel Note: the following also works on my machine: -- check() { read var if expr 1 + $var /dev/null ; then echo $var else return 2 fi }

Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-08 Thread Daniel Fuchs
Hi Mike, This one works perfectly on my machine :-) Thumbs up! -- daniel On 7/8/14 7:40 PM, Mike Duigou wrote: I've updated the webrev with yet a different variant of the extract version field function. http://cr.openjdk.java.net/~mduigou/JDK-8048184/1/webrev/ Sorry Dave, I resist all

Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-07 Thread Mike Duigou
Ping! (Still need a reviewer) The pushed version will reduce the required Mercurial client version to 1.4 as that is the version that is shipped with Oracle Enterprise Linux and is used by a large number of our development/testing virtual machines. It's not convenient to update these systems

Re: RFR: 8048184 : (s) handle mercurial dev build version string

2014-07-07 Thread Tim Bell
Mike: Ping! (Still need a reviewer) Looks good to me. Approved. TIm The pushed version will reduce the required Mercurial client version to 1.4 as that is the version that is shipped with Oracle Enterprise Linux and is used by a large number of our development/testing virtual