diff options
author | Robert Hensing <robert@roberthensing.nl> | 2020-05-14 15:26:01 +0200 |
---|---|---|
committer | Peter Simons <simons@cryp.to> | 2020-05-15 21:02:08 +0200 |
commit | 4353027d0b535b9c22c3c5d0de58718590483a28 (patch) | |
tree | 5eb0ec4e087023b56a0c8b9004d7de93d8cf2282 /pkgs/development/haskell-modules | |
parent | 4ed93cc494f123643aad5d0c394cee92e4fd73de (diff) |
haskell/generic-builder.nix: Fix C lib multiple inclusions
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
Diffstat (limited to 'pkgs/development/haskell-modules')
-rw-r--r-- | pkgs/development/haskell-modules/generic-builder.nix | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pkgs/development/haskell-modules/generic-builder.nix b/pkgs/development/haskell-modules/generic-builder.nix index 49cbe02b71e57..de5bf631bf0d6 100644 --- a/pkgs/development/haskell-modules/generic-builder.nix +++ b/pkgs/development/haskell-modules/generic-builder.nix @@ -383,7 +383,8 @@ stdenv.mkDerivation ({ for d in $(grep '^dynamic-library-dirs:' "$packageConfDir"/* | cut -d' ' -f2- | tr ' ' '\n' | sort -u); do for lib in "$d/"*.{dylib,so}; do - ln -s "$lib" "$dynamicLinksDir" + # Allow overwriting because C libs can be pulled in multiple times. + ln -sf "$lib" "$dynamicLinksDir" done done # Edit the local package DB to reference the links directory. |