RE: Gcc libraries

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

 



Can I do static linking in such a way that only gcc static libraries are
linked. With -static option, all the libraries expected are of static in
nature, whereas my product has 100 shared libs of its own and it is
_not_ possible to have that static in nature. 

-----Original Message-----
From: Jonathan Bartlett [mailto:johnnyb@eskimo.com] 
Sent: Monday, February 17, 2003 10:16 PM
To: redhat-devel-list@redhat.com
Subject: Re: Gcc libraries


Actually, I believe the load time can be faster on static linking,
especially for C++ because it takes a lot of time for the linker to
resolve those dynamic links.  I could be mistaken, though.

Jon

On Mon, 17 Feb 2003, John wrote:

> On Mon, 17 Feb 2003, Ajay Bansal wrote:
>
> > Hi All
> >
> > I am using gcc 3.2.1 for building my code.
> >
> > Now the end customer may not have the shared libs used by gcc like
> > libstdc++so.5 etc.
> >
> > Can I ship these libraries along with the product? Or Do I have to 
> > follow some procedure
>
> read the licence that applies to gcc. You will find you can distribute

> those libraries. If you do, you must also contract to supply the 
> source code etc (or just include it).
>
> However, I would be reluctant to install gcc and its libraries on any 
> system where it's not the standard compiler.
>
> You can also statically link your program with those libraries (you 
> still have that source problem), but that has other disadvantages: a. 
> Wasted disk space with duplicated code b. Longer startup times because

> you force the system to load one copy of the library code for each 
> copy of the app. In contrast, if you use shared libraries (and 
> especially, the same version in use on the client's system), you need 
> load only one copy for the whole system. c. If there are bugs in the 
> RTL, then you will need to ship new versions of your code so you can 
> replace the RTL. In contrast, if you use the shared libraries, the 
> client can fix the problem by installing vendor fixes.
>
> I recommend you use the same version of gcc your client does.
>
>
> --
> Please, reply only to the list.
>
>
>
>
> _______________________________________________
> Redhat-devel-list mailing list
> Redhat-devel-list@redhat.com 
> https://listman.redhat.com/mailman/listinfo/redhat-devel-list
>



_______________________________________________
Redhat-devel-list mailing list
Redhat-devel-list@redhat.com
https://listman.redhat.com/mailman/listinfo/redhat-devel-list



_______________________________________________
Redhat-devel-list mailing list
Redhat-devel-list@redhat.com
https://listman.redhat.com/mailman/listinfo/redhat-devel-list

[Index of Archives]     [Kernel Newbies]     [Red Hat General]     [Fedora]     [Red Hat Install]     [Linux Kernel Development]     [Yosemite News]

  Powered by Linux