Argh, found one compiler that gives a minor version including text so cut it

off the versions.
edge.strict_endians
antona 2005-10-15 10:16:26 +00:00
parent c0b2d7dab2
commit be4c70b45e
1 changed files with 3 additions and 3 deletions

View File

@ -240,9 +240,9 @@ fi
# Check for gcc version being >= 2.96.
AC_MSG_CHECKING(version of $_cc)
cc_version=`$_cc -dumpversion`
cc_major=`echo $cc_version | cut -d'.' -f1`
cc_minor=`echo $cc_version | cut -d'.' -f2`
cc_version=`$_cc -dumpversion 2> /dev/null | head -n 1`
cc_major=`echo $cc_version | cut -d'.' -f1 | sed s/"^\([0-9]+\).*$"/"\1"/`
cc_minor=`echo $cc_version | cut -d'.' -f2 | sed s/"^\([0-9]+\).*$"/"\1"/`
if test -z "$cc_version"; then
cc_version="v. ?.??"
cc_major=1