Link error and -fsquangle

Dimitri PAPADOPOULOS-ORFANOS papadopo@shfj.cea.fr
Wed Sep 9 07:50:00 GMT 1998


> When compiling a 'hello world' program with -fsquangle I get:
> 
> /usr/bin/ld:
> Unresolved:
> ostream::operator<<(ostream &(*)(ostream &))
> 
> That's with 1.1b on a DU 4 alpha. Or:
> 
> ld32: ERROR 33: Unresolved text symbol "ostream::operator<<(ostream
> &(*)(ostream &))" -- 1st referenced by /var/tmp/ccbH8Z2O.o.
> 
> on 1.1 prerelease on an IRIX 6.4 machine.

I have the same problem on Solaris 2.5.1 with 1.1b:

Undefined                       first referenced
 symbol                             in file
ostream::operator<<(ostream &(*)(ostream &))/tmp/ccJFCa7u.o

> When not using -fsquangle on code with expression templates, 'as' gives up
> because of resulting huge tokens with very little effort.

I have the same problem. Sun's assembler cannot handle lines
larger 1024 characters.

I was waiting for egcs-1.1 and its -fsquangle option to compile one
of our projects which compiles only with the -g flag. I don't know
why we end up with smaller assembly lines with the -g flag.
Alas! egcs-1.1 is too bugged up to be used in real-world situations.

To compile without -g, I sticked to egcs-1.0.3 and used GNU's
assembler.

By the way, how to force g++ to use GNU's as instead of Sun's as?
I installed GNU's as in /usr/local/binutils/bin and put it in the
path before Sun's /usr/ccs/bin/as. This doesn't work, as the path
/usr/ccs/bin/as is hardwired in g++.

--
Dimitri Papadopoulos



More information about the Gcc-bugs mailing list