[Nix-dev] mostly minimal Nixos built using gold ld where possible

Rohan Hart rohan.hart17 at gmail.com
Thu Mar 18 01:16:59 CET 2010


After many broken builds I've managed to get a working mostly-minimal
Nixos build using the new Gold ld linker where possible.  The changes
are attached.

Some packages still use the original GNU ld linker, either due to bugs
or limitations in the current Gold version (although I did fix one so
that GHC would build) or some deep dependency on how ld works.  For
Nixos in particular the current patchelf (0.5) fails with a floating
point exception on anything linked by Gold.

Many of the package level changes are due to Gold being more strict in
ensuring that all symbols can be found at link time.  In most cases
I've simply added an LDFLAGS = ... entry in the derivation.  I believe
this will be harmless with GNU ld so there's no stdenv entry
indicating that Gold is enabled.

If a hydra branch of nixpkgs was created I'd be happy to (slowly) fix
packages till there's a stable build.  In the mean time I'd like to be
able to use Nixos without multi-day compile delays  ;-)

cheers
Rohan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gold.patch
Type: text/x-patch
Size: 15472 bytes
Desc: not available
Url : http://lists.science.uu.nl/pipermail/nix-dev/attachments/20100318/ed7d0dbc/attachment.bin 


More information about the nix-dev mailing list