Skip to content

[20.03] backport haskell/generic-builder.nix: Fix C lib multiple inclusions#88017

Merged
roberth merged 1 commit intoNixOS:staging-20.03from
hercules-ci:backport-20.03-fix-haskell-darwin-c-lib-links
May 17, 2020
Merged

[20.03] backport haskell/generic-builder.nix: Fix C lib multiple inclusions#88017
roberth merged 1 commit intoNixOS:staging-20.03from
hercules-ci:backport-20.03-fix-haskell-darwin-c-lib-links

Conversation

@roberth
Copy link
Member

@roberth roberth commented May 17, 2020

Backport of #87881

Allow the darwin links code to overwrite libs that were already
copied, because C dependencies can occur multiple times.

Solves errors like

ln: failed to create symbolic link '/nix/store/higpc9xavwcjjzdipz7m9ly03bh7iy2z-hercules-ci-agent-source-0.7.0/lib/links/libboost_context.dylib': File exists

(cherry picked from commit a9373cd)

Motivation for this change
Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Allow the darwin links code to overwrite libs that were already
copied, because C dependencies can occur multiple times.

Solves errors like

    ln: failed to create symbolic link '/nix/store/higpc9xavwcjjzdipz7m9ly03bh7iy2z-hercules-ci-agent-source-0.7.0/lib/links/libboost_context.dylib': File exists

(cherry picked from commit a9373cd)
@ofborg ofborg bot added 6.topic: haskell General-purpose, statically typed, purely functional programming language 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. labels May 17, 2020
@roberth roberth merged commit 710c339 into NixOS:staging-20.03 May 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: haskell General-purpose, statically typed, purely functional programming language 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant