This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: gcc merrily compiles empty files


Mo McKinlay wrote:
> 
> Surely these would amount to the same thing, in terms of object files,
> though...and hence lead to the same problems?

Not necessarily. A conditionally empty source normally shouldn't produce
linkage failure. In the case of my accident, a zero-length file in the
object directory got compiled instead of the sourcefile in the source
tree, so all kinds of symbols were missing.

> If I didn't misread your original message, it points to a more serious
> problem on your platform (i.e, why did those empty C sources compile to
> produce object files which caused linkings problems?)

It could be a platform thing. What happens if you try feeding gcc a
0-byte foo.c on your platform?

Henry

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]