* m4/version.m4: Repaired version parsing.
authorStefan Ring <stefan@complang.tuwien.ac.at>
Thu, 24 Jun 2010 21:53:51 +0000 (23:53 +0200)
committerStefan Ring <stefan@complang.tuwien.ac.at>
Thu, 24 Jun 2010 21:53:51 +0000 (23:53 +0200)
Patch provided by Andrew John Hughes <ahughes@redhat.com>

m4/version.m4

index ba7c0e4622b2dde66a0dc0b47c058b7086122d04..2df93aeb8ab5eeb8968c2b5eb68cd9b70576c158 100644 (file)
@@ -29,7 +29,7 @@ if test x`echo "$version" | $SED -e 's/[[0-9a-z+]]*//g'` = "x..";
 then
     major=`echo "$version" | $SED -e 's/\.[[0-9a-z.+]]*$//'`
     minor=`echo "$version" | $SED -e 's/^[[0-9]]*\.//' -e 's/\.[[0-9a-z.+]]*$//'`
-    micro=`echo "$version" | $SED -e 's/^[[0-9]]*\.[[0-9]]*\.//' -e 's/[[a-z.+]]*$//'`
+    micro=`echo "$version" | $SED -r -e 's/^[[0-9]]*\.[[0-9]]*\.([[0-9]]*).*/\1/'`
     extra=`echo "$version" | $SED -e 's/^[[0-9]]*\.[[0-9]]*\.[[0-9]]*//'`
 else
     major=`echo "$version" | $SED -e 's/\.[[0-9a-z.+]]*$//'`