This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: gcc merrily compiles empty files
- To: Mo McKinlay <mmckinlay at gnu dot org>
- Subject: Re: gcc merrily compiles empty files
- From: Henry Sobotka <sobotka at axess dot com>
- Date: Tue, 20 Jun 2000 21:32:36 -0400
- CC: Michael Meissner <meissner at cygnus dot com>, gcc-bugs at gcc dot gnu dot org
- References: <Pine.LNX.4.21.0006210112470.7284-100000@granite.labs.ekto.org>
- Reply-To: sobotka at axess dot com
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