diff options
author | Dmitry Kalinkin <dmitry.kalinkin@gmail.com> | 2019-12-23 21:04:34 -0500 |
---|---|---|
committer | Peter Simons <simons@cryp.to> | 2019-12-27 20:37:13 +0100 |
commit | c744527e3e35d6b0c0a67d1030894f3214bca2e8 (patch) | |
tree | ac23ee9d64035d682c783d59bae8975d878321d8 | |
parent | b7a5df05c342896e69ab6b0ff202bcbbb4579b11 (diff) | |
download | nixpkgs-c744527e3e35d6b0c0a67d1030894f3214bca2e8.tar nixpkgs-c744527e3e35d6b0c0a67d1030894f3214bca2e8.tar.gz nixpkgs-c744527e3e35d6b0c0a67d1030894f3214bca2e8.tar.bz2 nixpkgs-c744527e3e35d6b0c0a67d1030894f3214bca2e8.tar.lz nixpkgs-c744527e3e35d6b0c0a67d1030894f3214bca2e8.tar.xz nixpkgs-c744527e3e35d6b0c0a67d1030894f3214bca2e8.tar.zst nixpkgs-c744527e3e35d6b0c0a67d1030894f3214bca2e8.zip |
gitAndTools.git-annex: fix darwin build
Closes: #76342 Fixes: #73435
-rw-r--r-- | pkgs/development/haskell-modules/configuration-nix.nix | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/pkgs/development/haskell-modules/configuration-nix.nix b/pkgs/development/haskell-modules/configuration-nix.nix index 8a8f2860186..6886a35c0a8 100644 --- a/pkgs/development/haskell-modules/configuration-nix.nix +++ b/pkgs/development/haskell-modules/configuration-nix.nix @@ -592,12 +592,19 @@ self: super: builtins.intersectAttrs super { ''; }); - # On Darwin, git-annex mis-detects options to `cp`, so we wrap the binary to - # ensure it uses Nixpkgs' coreutils. git-annex = with pkgs; if (!stdenv.isLinux) then let path = stdenv.lib.makeBinPath [ coreutils ]; in overrideCabal (addBuildTool super.git-annex makeWrapper) (_drv: { + # This is an instance of https://github.com/NixOS/nix/pull/1085 + # Fails with: + # gpg: can't connect to the agent: File name too long + postPatch = stdenv.lib.optionalString stdenv.isDarwin '' + substituteInPlace Test.hs \ + --replace ', testCase "crypto" test_crypto' "" + ''; + # On Darwin, git-annex mis-detects options to `cp`, so we wrap the + # binary to ensure it uses Nixpkgs' coreutils. postFixup = '' wrapProgram $out/bin/git-annex \ --prefix PATH : "${path}" |