static linking
Jonathan M Davis via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Sun Jul 26 13:25:00 PDT 2015
On Sunday, July 26, 2015 19:17:59 Martin Nowak via Digitalmars-d-learn wrote:
> On 07/26/2015 05:19 PM, Laeeth Isharc wrote:
> > The former is trickier on arch in particular (not related to Dicebot's
> > choice) because they don't distributed static versions of library files
> > as a matter of policy.
>
> Yes, quite a few distributions no longer support fully static linking.
> Some, e.g. hardened gentoo, don't allow it for security reasons (they
> use ASLR on PIE).
As I understand, it's considered a _very_ bad idea to statically link to
glibc at this point, which sucks, since having a program that just keeps
working when other stuff on the system is updated can be nice. It _is_ a
security problem on some level though - particularly with stuff like
openssl - since if you statically link, you don't get updates when the
libraries you depend on get security fixes.
But it's definitely statically linking everything that doesn't work with dmd
(or at least didn't the last time I checked), because it doesn't pass
-static through to gcc properly. Statically linking phobos should work just
fine.
- Jonathan M Davis
More information about the Digitalmars-d-learn
mailing list