Commit 352def90 authored by wolfgang's avatar wolfgang

[project @ 2004-10-01 03:52:57 by wolfgang]

Replace \? by \{0,1\} in the sed regular expressions, as the former
does not work with Mac OS X's (= BSD's) sed.

I'm a bit confused by the situation here:
According to Mac OS X man pages, the latter syntax is part of the
POSIX 1003.2 standard for basic regular expressions, while the former
is not. According to the manpage installed with my Gentoo linux, neither
is in the POSIX standard.

However, GNU sed accepts both \? and \{0,1\}, while Mac OS X's sed accepts
only \{0,1\}.
parent 3772fc40
......@@ -7,10 +7,10 @@ AC_SUBST([ProjectNameShort], [$PACKAGE_TARNAME])
AC_SUBST([ProjectVersion], [$PACKAGE_VERSION])
# Split PACKAGE_VERSION into (possibly empty) parts
VERSION_MAJOR=`echo $PACKAGE_VERSION | sed 's/^\(@<:@^.@:>@*\)\(\.\?\(.*\)\)$/\1'/`
VERSION_TMP=`echo $PACKAGE_VERSION | sed 's/^\(@<:@^.@:>@*\)\(\.\?\(.*\)\)$/\3'/`
VERSION_MINOR=`echo $VERSION_TMP | sed 's/^\(@<:@^.@:>@*\)\(\.\?\(.*\)\)$/\1'/`
ProjectPatchLevel=`echo $VERSION_TMP | sed 's/^\(@<:@^.@:>@*\)\(\.\?\(.*\)\)$/\3'/`
VERSION_MAJOR=`echo $PACKAGE_VERSION | sed 's/^\(@<:@^.@:>@*\)\(\.\{0,1\}\(.*\)\)$/\1'/`
VERSION_TMP=`echo $PACKAGE_VERSION | sed 's/^\(@<:@^.@:>@*\)\(\.\{0,1\}\(.*\)\)$/\3'/`
VERSION_MINOR=`echo $VERSION_TMP | sed 's/^\(@<:@^.@:>@*\)\(\.\{0,1\}\(.*\)\)$/\1'/`
ProjectPatchLevel=`echo $VERSION_TMP | sed 's/^\(@<:@^.@:>@*\)\(\.\{0,1\}\(.*\)\)$/\3'/`
# Calculate project version as an integer, using 2 digits for minor version
case $VERSION_MINOR in
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment