question about linker
Eric Christopher
echristo@apple.com
Fri Sep 9 18:06:00 GMT 2005
On Sep 9, 2005, at 10:28 AM, sean yang wrote:
> Hi
> I am looking for the source code related to linking stage--coz I am
> trying to modify (very slightly) the linker. I understand that 'ld'
> is the linker in Linux. My question is:
> Is 'ld' a part of gcc toolchain?
> --If it is, I should be able to find source file producing 'ld'.
> But I haven't found the source file to be compiled to 'ld'.
> --If it's not, main() of gcc.c should invoke ld if it found the '-
> o' option. But I didn't find the invocation either(maybe it's not a
> straightforward invocation).
The linker is ld, and is in the binutils package. http://
sourceware.org/binutils/.
To see what's really going on try adding -v and -Wl,-v to your gcc
command line.
-eric
More information about the Gcc
mailing list