summary refs log tree commit diff
path: root/pkgs/by-name/as/ast-grep/package.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/by-name/as/ast-grep/package.nix')
-rw-r--r--pkgs/by-name/as/ast-grep/package.nix5
1 files changed, 5 insertions, 0 deletions
diff --git a/pkgs/by-name/as/ast-grep/package.nix b/pkgs/by-name/as/ast-grep/package.nix
index b1979b00b0819..226174fd85c4e 100644
--- a/pkgs/by-name/as/ast-grep/package.nix
+++ b/pkgs/by-name/as/ast-grep/package.nix
@@ -17,6 +17,11 @@ rustPlatform.buildRustPackage rec {
 
   cargoHash = "sha256-OFNqBkPAKaSqDQUWisupj6FlDbm3kw0xq5nbvj04H5U=";
 
+  # Work around https://github.com/NixOS/nixpkgs/issues/166205.
+  env = lib.optionalAttrs stdenv.cc.isClang {
+    NIX_LDFLAGS = "-l${stdenv.cc.libcxx.cxxabi.libName}";
+  };
+
   # error: linker `aarch64-linux-gnu-gcc` not found
   postPatch = ''
     rm .cargo/config.toml