Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ihaskell fails to build #22047

Closed
vaibhavsagar opened this issue Jan 23, 2017 · 7 comments
Closed

ihaskell fails to build #22047

vaibhavsagar opened this issue Jan 23, 2017 · 7 comments

Comments

@vaibhavsagar
Copy link
Member

Issue description

IHaskell is not GHC 8 compatible, and so it doesn't build on 16.09 onwards. Instead I get this error:

Setup: Encountered missing dependencies:
base >=4.6 && <4.9, ghc >=7.6 && <7.11
builder for ‘/nix/store/9bbjk1lknn94y4b7wf9wd9pfgfcfms37-ghc-parser-0.1.8.0.drv’ failed with exit code 1
cannot build derivation ‘/nix/store/ybqc2p7qk1p2i8ka889xh5ksid1xv0kn-ghc-8.0.1-with-packages.drv’: 1 dependencies couldn't be built
cannot build derivation ‘/nix/store/6mg7sz0sl6ki7r877g3agc3slqwmnlsf-ihaskell-0.8.4.0.drv’: 1 dependencies couldn't be built
building path(s) ‘/nix/store/qjcg07sw2hammhy3jxkarif5i0jszpgk-ipykernel-4.3.1.tar.gz’
cannot build derivation ‘/nix/store/5z2rsbvisv77hqz7rmxlhg1m7kfj7c7y-ihaskell-with-packages.drv’: 1 dependencies couldn't be built
error: build of ‘/nix/store/5z2rsbvisv77hqz7rmxlhg1m7kfj7c7y-ihaskell-with-packages.drv’ failed

Steps to reproduce

nix-build '<nixpkgs>' -A ihaskell

Technical details

  • System: 16.09.1512.6b28bd0 (Flounder)
  • Nix version: nix-env (Nix) 1.11.6
  • Nixpkgs version: 16.09.1512.6b28bd0
@teh
Copy link
Contributor

teh commented Jan 26, 2017

Thanks for filing an issue! I see you already filed the GHC 8 incompatibility upstream.

You could try the following patch:

diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index 0dc5b81..886a603 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -2253,7 +2253,7 @@ in
 
 
   ihaskell = callPackage ../development/tools/haskell/ihaskell/wrapper.nix {
-    inherit (haskellPackages) ihaskell ghcWithPackages;
+    inherit (haskell.packages.ghc7103) ihaskell ghcWithPackages;
 
     ipython = python3.buildEnv.override {
       extraLibs = with python3Packages; [ ipython ipykernel jupyter_client notebook ];

but it'll require re-building substantial amounts of old code that are no longer being build by hydra. If it works we can apply the patch, otherwise I think I'd vote for removing the package. What do you think?

@vaibhavsagar
Copy link
Member Author

After applying your patch, I'm getting an error building gtk2hs-buildtools (#18586). Is there an easy workaround for this? I'm hopeful that IHaskell will gain GHC 8 compatibility in the near term, so I'd rather not remove the package 😄

@teh
Copy link
Contributor

teh commented Jan 27, 2017

Reading #18586 I doubt there is.

In order to save other people time maybe we should at least add an assert with an informative message and a link to this bug so other people won't lose time trying to install ihaskell?

@vaibhavsagar
Copy link
Member Author

Sure, that's a good idea.

teh added a commit to teh/nixpkgs that referenced this issue Jan 27, 2017
meta.broken doesn't work in buildEnv so we abort when the dependencies
are evaluated.

See bug for more context.
@globin globin closed this as completed in 6dd5c9d Jan 27, 2017
globin added a commit that referenced this issue Jan 27, 2017
Revert "Mark ihaskell as broken. Closes #22047."
@teh
Copy link
Contributor

teh commented Jan 27, 2017

I can't see an easy way of disabling ihaskell, so I suggest removal, followed by re-introduction when fixed. @vaibhavsagar - would you be able to own this?

@vaibhavsagar
Copy link
Member Author

I've created a pull request.

vcunat pushed a commit that referenced this issue Jan 30, 2017
See #22047. This change should be reverted after IHaskell has been
updated to support GHC 8.
@vaibhavsagar vaibhavsagar mentioned this issue Nov 6, 2017
8 tasks
@baracoder
Copy link
Contributor

I am experiencing a similar error on current nixos-unstable channel

nix-env -iA ihaskell -f https://github.com/NixOS/nixpkgs-channels/archive/nixos-unstable.tar.gz 

...

Configuring gtk2hs-buildtools-0.13.4.0...
CallStack (from HasCallStack):
  die', called at libraries/Cabal/Cabal/Distribution/Simple/Configure.hs:950:20 in Cabal-2.4.0.1:Distribution.Simple.Configure
  configureFinalizedPackage, called at libraries/Cabal/Cabal/Distribution/Simple/Configure.hs:460:12 in Cabal-2.4.0.1:Distribution.Simple.Configure
  configure, called at libraries/Cabal/Cabal/Distribution/Simple.hs:596:20 in Cabal-2.4.0.1:Distribution.Simple
  confHook, called at libraries/Cabal/Cabal/Distribution/Simple/UserHooks.hs:67:5 in Cabal-2.4.0.1:Distribution.Simple.UserHooks
  configureAction, called at libraries/Cabal/Cabal/Distribution/Simple.hs:178:19 in Cabal-2.4.0.1:Distribution.Simple
  defaultMainHelper, called at libraries/Cabal/Cabal/Distribution/Simple.hs:115:27 in Cabal-2.4.0.1:Distribution.Simple
  defaultMain, called at Setup.hs:6:8 in main:Main
Setup: Encountered missing dependencies:
base >=4 && <4.12

builder for '/nix/store/4776fq3wwchhb1bnpznxb5fqwbm1zp1g-gtk2hs-buildtools-0.13.4.0.drv' failed with exit code 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants