[geos-devel] GEOS 3.7.0rc1 release

Greg Troxel gdt at lexort.com
Mon Aug 20 16:25:13 PDT 2018


"Regina Obe" <lr at pcorp.us> writes:

> I asked Sebastian the same thing.  He said it's needed in configure
> script to escape the [] as I recall.

Of course :-) I was looking back and forth in so many rules I forgot
which it was.

But, I figured out what was wrong.  This is the version from configure
(so no extra [ - don't paste it in...).    The key thing is to add ()
around .* before the ?, because

  .*?

is malformed.   It's the .* production that the ? applies to (present or
not).

  VERSION_RELEASE=`echo "$VERSION" | sed -E 's/^([0-9]+\.[0-9]+\.[0-9]+)(.*)?$/\1/'`

GNU sed may be allowing this as an extension, because "*?" doesn't make
sense, since * is repetition.

Actually, the whole ? is redundant and can be just dropped, because

  (.*)?

matches zero or more occurrences fo any character, and also the empty
string.  But .* matches the empty string anyway.  So while I can see the
point that it leads the reader to think "either some arbitrary string or
the empty string", it's just more complicated for no good reason.

So just drop the ? after the .*

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 162 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/geos-devel/attachments/20180820/db378d98/attachment.sig>


More information about the geos-devel mailing list