bce71e97a0
This removes (some of) the special casing for git-annex which we need to replicate using overrides. As a first step, we recreate an equivalent set of overrides to the former gitAnnexHook, the only difference being that we use the default installPhase over a custom implementation. A big flaw of the current expression (which was shared by the previous iteration) is that they ignore the testFlags argument. Unfortunately, we can't do that without changing the generic builder implementation.
41 lines
1.7 KiB
Nix
41 lines
1.7 KiB
Nix
# This file defines cabal2nix-unstable, used by maintainers/scripts/haskell/regenerate-hackage-packages.sh.
|
|
{ mkDerivation, aeson, ansi-wl-pprint, base, bytestring, Cabal
|
|
, containers, deepseq, directory, distribution-nixpkgs, fetchzip
|
|
, filepath, hackage-db, hopenssl, hpack, language-nix, lens, lib
|
|
, monad-par, monad-par-extras, mtl, optparse-applicative, pretty
|
|
, process, split, tasty, tasty-golden, text, time, transformers
|
|
, yaml
|
|
}:
|
|
mkDerivation {
|
|
pname = "cabal2nix";
|
|
version = "unstable-2024-04-21";
|
|
src = fetchzip {
|
|
url = "https://github.com/NixOS/cabal2nix/archive/f8e6bf749a158a5ed866c57deee907b5f16c38e5.tar.gz";
|
|
sha256 = "0c73mvza65iy46fv8c8cadsy7klk4jzmimm1mfdavvm8i2cr5476";
|
|
};
|
|
postUnpack = "sourceRoot+=/cabal2nix; echo source root reset to $sourceRoot";
|
|
isLibrary = true;
|
|
isExecutable = true;
|
|
libraryHaskellDepends = [
|
|
aeson ansi-wl-pprint base bytestring Cabal containers deepseq
|
|
directory distribution-nixpkgs filepath hackage-db hopenssl hpack
|
|
language-nix lens optparse-applicative pretty process split text
|
|
time transformers yaml
|
|
];
|
|
executableHaskellDepends = [
|
|
aeson base bytestring Cabal containers directory
|
|
distribution-nixpkgs filepath hopenssl language-nix lens monad-par
|
|
monad-par-extras mtl optparse-applicative pretty
|
|
];
|
|
testHaskellDepends = [
|
|
base Cabal containers directory filepath language-nix lens pretty
|
|
process tasty tasty-golden
|
|
];
|
|
preCheck = ''
|
|
export PATH="$PWD/dist/build/cabal2nix:$PATH"
|
|
export HOME="$TMPDIR/home"
|
|
'';
|
|
homepage = "https://github.com/nixos/cabal2nix#readme";
|
|
description = "Convert Cabal files into Nix build instructions";
|
|
license = lib.licenses.bsd3;
|
|
}
|