This is the mail archive of the gcc@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]
Other format: [Raw text]

Re: gcc ld error


daniel tian <daniel.xntian@gmail.com> writes:

>     I just wanna get the argment passed to ld, when I could debug the
> ld with gdb.
>     I run the command the
>         rice-elf-gcc helloworld.c -v
>     But I couldn't get the parameter passed to ld.
>     and I don't know what the relationship between "collect2" and
> "ld". It seems they do have some connections between them.

collect2 invokes ld with the same options (with a couple of
unimportant exceptions) that were passed to collect2.

To see precisely what collect2 does:
    rice-elf-gcc -v -Wl,-debug helloworld.c

(The -debug option is one of the exceptions: collect2 does not pass it
on to ld.)

Ian


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