Re: Is it possible/desirable to avoid using collect2 on Solaris?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



After some experimenting it appears that besides filling in
constructor functions, collect2 is also responsible for passing in the
standard libraries and definitions of _main(). So I take it there's no
avoiding using it, but perhaps when you're using the GNU linker it's
smart enough to not do the second pass on its own?

On Sun, Feb 28, 2010 at 2:15 PM, Joseph Garvin
<joseph.h.garvin@xxxxxxxxx> wrote:
> Based on the documentation here:
>
> http://gcc.gnu.org/onlinedocs/gccint/Collect2.html
>
> It appears that collect2 is inefficient in that it involves two
> passes. I've heard that the GNU linker doesn't require a second pass,
> so if you're using it collect2 should be unnecessary. I'm compiling on
> Solaris, and I know how to get GCC to invoke the GNU linker instead of
> the native Sun one (using -B to point it to a different folder) but if
> I do this and compile a file with -V I can see that it's still running
> collect2. Is there a way to suppress this or is my information
> outdated? If it is possible to avoid using collect2, do any special
> steps need to be taken when not using it or will things 'just work'?
> Google isn't being a lot of help.
>

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux