diff --git a/pkgs/development/haskell-modules/with-packages-wrapper.nix b/pkgs/development/haskell-modules/with-packages-wrapper.nix index ac484b3c112..3cbf0c004fd 100644 --- a/pkgs/development/haskell-modules/with-packages-wrapper.nix +++ b/pkgs/development/haskell-modules/with-packages-wrapper.nix @@ -107,7 +107,7 @@ symlinkJoin { # Clean up the old links that may have been (transitively) included by # symlinkJoin: rm -f $dynamicLinksDir/* - for d in $(grep dynamic-library-dirs $packageConfDir/*|awk '{print $2}'); do + for d in $(grep dynamic-library-dirs $packageConfDir/*|awk '{print $2}'|sort -u); do ln -s $d/*.dylib $dynamicLinksDir done for f in $packageConfDir/*.conf; do