about summary refs log tree commit diff
path: root/nixpkgs/pkgs/tools/text/difftastic/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/tools/text/difftastic/default.nix')
-rw-r--r--nixpkgs/pkgs/tools/text/difftastic/default.nix6
1 files changed, 6 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/tools/text/difftastic/default.nix b/nixpkgs/pkgs/tools/text/difftastic/default.nix
index 1db60b38a8de..98c3db975edc 100644
--- a/nixpkgs/pkgs/tools/text/difftastic/default.nix
+++ b/nixpkgs/pkgs/tools/text/difftastic/default.nix
@@ -4,6 +4,7 @@
 , fetchFromGitHub
 , testers
 , difftastic
+, stdenv
 }:
 
 let
@@ -32,6 +33,11 @@ rustPlatform.buildRustPackage rec {
     };
   };
 
+  # Work around https://github.com/NixOS/nixpkgs/issues/166205.
+  env = lib.optionalAttrs stdenv.cc.isClang {
+    NIX_LDFLAGS = "-l${stdenv.cc.libcxx.cxxabi.libName}";
+  };
+
   postPatch = ''
     patch -d $cargoDepsCopy/libmimalloc-sys-0.1.24/c_src/mimalloc \
       -p1 < ${mimallocPatch}