aboutsummaryrefslogtreecommitdiff
path: root/gcc/configure
diff options
context:
space:
mode:
authorHans-Peter Nilsson <hp@bitrange.com>2012-10-11 00:52:26 +0000
committerHans-Peter Nilsson <hp@bitrange.com>2012-10-11 00:52:26 +0000
commit0e1b43cd08149a9f4bb678bb873ed3b0ecd6cbac (patch)
treecaab9a75374f7e11793ed8f8ccf2951b10f99ca8 /gcc/configure
parentc71887e83a9b42e138ab138427f86df5f6c281b1 (diff)
* acinclude.m4 (_gcc_COMPUTE_GAS_VERSION): Allow a single
character to quote the VERSION= contents. Sanity-check contents. * configure.ac ("what linker to use" ld version extraction): Ditto. * configure: Regenerate. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@192342 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/configure')
-rwxr-xr-xgcc/configure12
1 files changed, 10 insertions, 2 deletions
diff --git a/gcc/configure b/gcc/configure
index 45bba8e785e..95dcc44eb3f 100755
--- a/gcc/configure
+++ b/gcc/configure
@@ -21237,11 +21237,15 @@ for f in $gcc_cv_as_bfd_srcdir/configure \
$gcc_cv_as_gas_srcdir/configure \
$gcc_cv_as_gas_srcdir/configure.in \
$gcc_cv_as_gas_srcdir/Makefile.in ; do
- gcc_cv_gas_version=`sed -n -e 's/^[ ]*\(VERSION=[0-9]*\.[0-9]*.*\)/\1/p' < $f`
+ gcc_cv_gas_version=`sed -n -e 's/^[ ]*VERSION=[^0-9A-Za-z_]*\([0-9]*\.[0-9]*.*\)/VERSION=\1/p' < $f`
if test x$gcc_cv_gas_version != x; then
break
fi
done
+case $gcc_cv_gas_version in
+ VERSION=[0-9]*) ;;
+ *) as_fn_error "cannot find version of in-tree assembler" "$LINENO" 5;;
+esac
gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"`
gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.\([0-9]*\)"`
gcc_cv_gas_patch_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.[0-9]*\.\([0-9]*\)"`
@@ -21395,11 +21399,15 @@ $as_echo "newly built ld" >&6; }
fi
for f in $gcc_cv_ld_bfd_srcdir/configure $gcc_cv_ld_gld_srcdir/configure $gcc_cv_ld_gld_srcdir/configure.in $gcc_cv_ld_gld_srcdir/Makefile.in
do
- gcc_cv_gld_version=`sed -n -e 's/^[ ]*\(VERSION=[0-9]*\.[0-9]*.*\)/\1/p' < $f`
+ gcc_cv_gld_version=`sed -n -e 's/^[ ]*VERSION=[^0-9A-Za-z_]*\([0-9]*\.[0-9]*.*\)/VERSION=\1/p' < $f`
if test x$gcc_cv_gld_version != x; then
break
fi
done
+ case $gcc_cv_gld_version in
+ VERSION=[0-9]*) ;;
+ *) as_fn_error "cannot find version of in-tree linker" "$LINENO" 5 ;;
+ esac
gcc_cv_gld_major_version=`expr "$gcc_cv_gld_version" : "VERSION=\([0-9]*\)"`
gcc_cv_gld_minor_version=`expr "$gcc_cv_gld_version" : "VERSION=[0-9]*\.\([0-9]*\)"`
else