]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
flex version check is now done by awk alone
authorBVK Chaitanya <bvk.groups@gmail.com>
Sat, 10 Apr 2010 12:36:45 +0000 (18:06 +0530)
committerBVK Chaitanya <bvk.groups@gmail.com>
Sat, 10 Apr 2010 12:36:45 +0000 (18:06 +0530)
configure.ac

index 0af597bd384fcb34daa8997f8fde02e990856e33..08260eae5d91754575012b883c19daf7c6d48b0a 100644 (file)
@@ -192,7 +192,7 @@ AC_PROG_MKDIR_P
 if test "x$LEX" = x; then
   AC_MSG_ERROR([flex is not found])
 else
-  version=`$LEX --version 2>/dev/null | $SED -e 's/flex//' -e 's/version//' | $AWK -F "." '{ printf "%d", $1 * 10000 + $2 * 100 + $3;}'`
+  version=`$LEX --version | $AWK '{ split($NF,x,"."); print x[[1]]*10000+x[[2]]*100+x[[3]]; }'`
   if test -n "$version" -a "$version" -ge 20535; then
     :
   else