gcc/configure failed to detect assembler hidden support on solaris2.6
Andreas Schwab
schwab@suse.de
Mon Dec 2 11:45:00 GMT 2002
Daniel Jacobowitz <drow@mvista.com> writes:
|> On Thu, Nov 28, 2002 at 05:29:29PM +0100, Thibaud Tortech wrote:
|> > Hi all,
|> >
|> > I'm working on sparc-sun-solaris2.6 and I'm trying to build
|> > binutils-2.13.1 + gcc-3.2.1 on that platform.
|> >
|> > First I build and install binutils-2.13.1 then configured gcc with the
|> > following line:
|> > ../gcc-3.2.1/configure --prefix=/var/tmp/gnu --with-gnu-as --with-gnu-ld
|> > --with-as=/var/tmp/gnu/bin/as --with-ld=/var/tmp/gnu/bin/ld
|> > --enable-languages=c
|> >
|> > The gcc/configure script reports that the assembler doesn't support
|> > hidden symbol attribute. Or in the same script there's a comment saying
|> > that: "GNU LD versions before 2.12.1 have buggy support for STV_HIDDEN."
|> >
|> > Then I found that the following line(#7220) in gcc/configure:
|> > ld_vers=`echo $ld_ver | sed -n 's,^.*[
|> > ]\([0-9][0-9]*\.[0-9][0-9]*\(\|\.[0-9][0-9]*\)\)\([ ].*\|\)$,\1,p'`
|> > return an empty line instead of 2.13.1.
|> >
|> > I changed it to:
|> > ld_vers=`echo $ld_ver | sed -n 's,^.*[
|> > ]\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*$,\1,p'`
|> > and things seens to be OK.
|> >
|> > Is it OK?
|>
|> What's $ld_vers? This looks like a bug in your 'sed'... it may be
|> misnumbering the backreference?
I think the problem is that old sed does not support \| or nested \( \).
>From the autoconf manual:
Alternation, `\|', is common but POSIX does not require its
support, so it should be avoided in portable scripts. Solaris 8
`sed' does not support alternation; e.g., `sed '/a\|b/d'' deletes
only lines that contain the literal string `a|b'.
Anchors (`^' and `$') inside groups are not portable.
Nested parenthesization in patterns (e.g., `\(\(a*\)b*)\)') is
quite portable to modern hosts, but is not supported by some older
`sed' implementations like SVR3.
Andreas.
--
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux AG, Deutschherrnstr. 15-19, D-90429 Nürnberg
Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
More information about the Gcc
mailing list