undefined reference to `__errno_location(void)'

GRE Spam Mail gre_spam@anora.org
Wed Sep 4 17:27:00 GMT 2002


On Wed, 4 Sep 2002 12:20:11 -0400 (EDT)
Rupert Wood <rup@kanat.pair.com> wrote:

> Claudio Bley wrote:
> 
> >     GRE> extern int errno;
> >          ^^^^^^^^^^^^^^^^^
> >
> > Remove this line from your source. You get the error because errno is
> > defined as a macro and the line is expanded to
> >
> > extern int (*__errno_location ());
> 
> Which, in that scope, is defined as a C++ symbol. Which is why it
> didn't match the C __errno_location in libpthread.
> 
> The "d'oh" here is that the clue was in the title: it wouldn't have said
> "(void)" if it was trying to match a C symbol because it wouldn't have
> that information.
> 
> Oh well, we learn. (And good spot, Claudio!)
> 
> Rup.
> 
> 

I just wanted to thank you all for your help. The problem seems resolved.
I also want to thank the others that helped me that I didn't reply to in
this message, Such as Der Herr Hofrat.

Sincerely,

Gordon R. Ellsworth, Jr.

P.S. Now I feel stupid. "d'oh!"



More information about the Gcc-help mailing list