Might anyone of you know why
$ nix-shell \
-I nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/nixos-unstable.tar.gz \
-p "haskellPackages.ghcWithPackages (p: [p.compose-ltr])" \
--run ghci
fails with
Configuring compose-ltr-0.2.3...
Setup: Encountered missing dependencies:
QuickCheck ==2.8.1, hspec ==2.2.0
builder for ‘/nix/store/pvmm9qcp9xpj5hw77nbfyfj4wxs49jl8-compose-ltr-0.2.3.drv’ failed with exit code 1
cannot build derivation ‘/nix/store/41znxh9qi408n9j63fqvixrlkaasrgkx-ghc-8.0.1-with-packages.drv’: 1 dependencies couldn't be built
?
(blank lines added for separation and emphasis)
I'm asking since as far as I am aware I'm not asking nix to build/run unit tests of compose-ltr, so why does it care about QuickCheck and hspec?
Yes, QuickCheck and hspec are mentioned in the .cabal file, but only for test-suite spec and not library.
Additionally, can I fix this either by
- specifying something further in my
nix-shellcommand, - changing something in the
.cabalfile ofcompose-ltr, or - adding a
.nixfile tocompose-ltr?
I wouldn't say I have much experience with nix yet, so a detailed response is welcome.
Replace
with
which disables tests for this package. Overall this should be included into https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/haskell-modules/configuration-common.nix (a PR on GitHub will be welcome, I think)