gcc behind the scenes

Rask Ingemann Lambertsen rask@sygehus.dk
Sun May 20 17:47:00 GMT 2007


On Sun, May 20, 2007 at 07:58:30PM +0300, Sunzir Deepur wrote:
> Hello,,
> 
> I tried to compile foo.c using "gcc -v foo.c",
> and I noticed:
> 1. the driver is not calling cpp. why is that ? isn't there a preprocessing
>   stage ?

   It has been integrated into cc1 for several years. IIRC to provide better
error messages and to speed up compilation.

> 2. the linker binary is actually called collect2 and not ld.
>    is there a reason for that (I'm using a FC5 system) ?

   The linker is ld, collect2 is just a helper program. Please see
<URL:http://gcc.gnu.org/onlinedocs/gccint/Initialization.html>, in
particular the last bit, for the explanation.

-- 
Rask Ingemann Lambertsen



More information about the Gcc-help mailing list