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).

Can someone show me where should I start to investigate it? Thanks a lot,

Shuo

Here is something I thought related, but I think it is not directly related to linking stage.
6615       if (! strcmp (linker_name_spec, "collect2"))
  6616     {
  6617       char *s = find_a_file (&exec_prefixes, "collect2", X_OK, 0);
  6618       if (s == NULL)
  6619         linker_name_spec = "ld";
  6620     }

_________________________________________________________________
Don’t just search. Find. Check out the new MSN Search! http://search.msn.click-url.com/go/onm00200636ave/direct/01/

Reply via email to