[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: binutils-2.15.90.0.3 bug-report
From: |
Ian Lance Taylor |
Subject: |
Re: binutils-2.15.90.0.3 bug-report |
Date: |
24 Oct 2004 21:17:07 -0400 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 |
w.szukalski <address@hidden> writes:
> I had written a file 'css-format.c' that contained a function
> call of 'close_css_box()' which had not yet been defined.
> But 'ar' created a library, although the function definition
> is missing:
>
> css-format.c:1994: warning: implicit declaration of function
> `close_css_box'
> ar: creating libhtmlw.a
>
> And the resulting program, using this local library, was created.
>
> Where is the bug? In GCC or in BINUTILS? I suppose, 'ar' or 'ld'
> should have realized the missing definition.
It is not a bug to create a library which includes objects which have
undefined references. Nor is it a bug to use such a library. It
would be a bug if an object with undefined references were linked into
your program if the linker did not complain about the undefined
symbol. You have not shown that your program actually uses the object
css-format.o. If the linker does not think that object is required,
it will not include it in the link. If it is not included in the
link, the fact that it references an undefined symbol is unimportant.
Ian