undefined reference to `__errno_location(void)'
Claudio Bley
bley@cs.uni-magdeburg.de
Wed Sep 4 09:03:00 GMT 2002
>>>>> "GRE" == GRE Spam Mail <gre_spam@anora.org> writes:
GRE> On Wed, 04 Sep 2002 09:27:52 +0200 bjorn rohde jensen
GRE> <bjensen@fastmail.fm> wrote:
>> Hi Gordon,
>>
>> Could you post some (small) code demonstrating the problem? I
>> think, you might be confusing ld's in its handling of
>> weak/strong symbols during linking. It would be nice with some
>> code to experiment with:)
>>
>> Yours sincerely,
>>
>> Bjorn
>>
>>
GRE> Sure enough! Here's the smallest code that I've written that
GRE> has this problem.
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 ());
Claudio
More information about the Gcc-help
mailing list