diff options
author | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-05-23 08:11:50 +0000 |
---|---|---|
committer | jakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-05-23 08:11:50 +0000 |
commit | 1aa4bbf2c14f98fd42f4ed1e429be3d1de43e9a3 (patch) | |
tree | aec27ba10b0e5d570ed21115ac9738c88f65d5fd | |
parent | 2b8ca2992c00cbb7c5ff5a1527f8b671ce8b2752 (diff) | |
download | gcc-1aa4bbf2c14f98fd42f4ed1e429be3d1de43e9a3.tar.gz |
* configure.in: Fix as version test for binutils 2.12.1 releases
(without dates).
* configure: Rebuilt.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@53775 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rwxr-xr-x | gcc/configure | 24 | ||||
-rw-r--r-- | gcc/configure.in | 26 |
3 files changed, 51 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index cb83350e9ea..dd18993cc50 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2002-05-23 Jakub Jelinek <jakub@redhat.com> + + * configure.in: Fix as version test for binutils 2.12.1 releases + (without dates). + * configure: Rebuilt. + 2002-05-23 Richard Henderson <rth@redhat.com> * config/i386/i386.c (get_pic_label_name): New. diff --git a/gcc/configure b/gcc/configure index ea8701c0edb..60e65d3a36c 100755 --- a/gcc/configure +++ b/gcc/configure @@ -7207,9 +7207,29 @@ elif test x$gcc_cv_as != x; then # the date string after the version number. ld_ver=`$gcc_cv_ld --version 2>/dev/null | head -1` if echo "$ld_ver" | grep GNU > /dev/null; then - ld_date=`echo $ld_ver | sed -n 's,^.*\([2-9][0-9][0-9][0-9]\)[-]*\([01][0-9]\)[-]*\([0-3][0-9]\).*$,\1\2\3,;p'` + ld_vers=`echo $ld_ver | sed -n 's,^.*[ ]\([0-9][0-9]*\.[0-9][0-9]*\(\|\.[0-9][0-9]*\)\)\([ ].*\|\)$,\1,p'` + ld_date=`echo $ld_ver | sed -n 's,^.*\([2-9][0-9][0-9][0-9]\)[-]*\([01][0-9]\)[-]*\([0-3][0-9]\).*$,\1\2\3,p'` if test 0"$ld_date" -lt 20020404; then - gcc_cv_as_hidden="no" + if test -n "$ld_date"; then + # If there was date string, but was earlier than 2002-04-04, fail + gcc_cv_as_hidden="no" + elif test -z "$ld_vers"; then + # If there was no date string nor ld version number, something is wrong + gcc_cv_as_hidden="no" + else + ld_vers_major=`expr "$ld_vers" : '\([0-9]*\)'` + ld_vers_minor=`expr "$ld_vers" : '[0-9]*\.\([0-9]*\)'` + ld_vers_patch=`expr "$ld_vers" : '[0-9]*\.[0-9]*\.\([0-9]*\)'` + test -z "$ld_vers_patch" && ld_vers_patch=0 + if test "$ld_vers_major" -lt 2; then + gcc_cv_as_hidden="no" + elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 12; then + gcc_cv_as_hidden="no" + elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -eq 12 \ + -a "$ld_vers_patch" -eq 0; then + gcc_cv_as_hidden="no" + fi + fi fi fi fi diff --git a/gcc/configure.in b/gcc/configure.in index a67f0228480..71bfca708f9 100644 --- a/gcc/configure.in +++ b/gcc/configure.in @@ -1541,11 +1541,31 @@ elif test x$gcc_cv_as != x; then ld_ver=`$gcc_cv_ld --version 2>/dev/null | head -1` if echo "$ld_ver" | grep GNU > /dev/null; then changequote(,)dnl - ld_date=`echo $ld_ver | sed -n 's,^.*\([2-9][0-9][0-9][0-9]\)[-]*\([01][0-9]\)[-]*\([0-3][0-9]\).*$,\1\2\3,;p'` -changequote([,])dnl + ld_vers=`echo $ld_ver | sed -n 's,^.*[ ]\([0-9][0-9]*\.[0-9][0-9]*\(\|\.[0-9][0-9]*\)\)\([ ].*\|\)$,\1,p'` + ld_date=`echo $ld_ver | sed -n 's,^.*\([2-9][0-9][0-9][0-9]\)[-]*\([01][0-9]\)[-]*\([0-3][0-9]\).*$,\1\2\3,p'` if test 0"$ld_date" -lt 20020404; then - gcc_cv_as_hidden="no" + if test -n "$ld_date"; then + # If there was date string, but was earlier than 2002-04-04, fail + gcc_cv_as_hidden="no" + elif test -z "$ld_vers"; then + # If there was no date string nor ld version number, something is wrong + gcc_cv_as_hidden="no" + else + ld_vers_major=`expr "$ld_vers" : '\([0-9]*\)'` + ld_vers_minor=`expr "$ld_vers" : '[0-9]*\.\([0-9]*\)'` + ld_vers_patch=`expr "$ld_vers" : '[0-9]*\.[0-9]*\.\([0-9]*\)'` + test -z "$ld_vers_patch" && ld_vers_patch=0 + if test "$ld_vers_major" -lt 2; then + gcc_cv_as_hidden="no" + elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 12; then + gcc_cv_as_hidden="no" + elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -eq 12 \ + -a "$ld_vers_patch" -eq 0; then + gcc_cv_as_hidden="no" + fi + fi fi +changequote([,])dnl fi fi if test x"$gcc_cv_as_hidden" = xyes; then |