Skip to content
This repository has been archived by the owner on Feb 3, 2021. It is now read-only.

Pugs build fails on GHC 7.4.1/Windows #25

Open
ghost opened this issue Oct 1, 2012 · 3 comments
Open

Pugs build fails on GHC 7.4.1/Windows #25

ghost opened this issue Oct 1, 2012 · 3 comments

Comments

@ghost
Copy link

ghost commented Oct 1, 2012

Pugs.hs build fails on latest haskell platform (2012.2.0.0 with GHC 7.4.1). The OS is windows 7 64 bit.

C:\>cabal update
Downloading the latest package list from hackage.haskell.org

C:\>cabal install Pugs
Resolving dependencies...
Configuring pugs-compat-0.0.6.20120717.204800...
Building pugs-compat-0.0.6.20120717.204800...
Preprocessing library pugs-compat-0.0.6.20120717.204800...

src\Pugs\Compat\Posix.hs:134:8:
    Could not find module `IO'
    It is a member of the hidden package `haskell98-2.0.0.1'.
    Perhaps you need to add `haskell98' to the build-depends in your .cabal file
.
    Use -v to see a list of the files searched for.
cabal: Error: some packages failed to install:
Pugs-6.2.13.20120717 depends on pugs-compat-0.0.6.20120717.204800 which failed
to install.
pugs-compat-0.0.6.20120717.204800 failed during the building phase. The
exception was:
ExitFailure 1

C:\>ghc --version
The Glorious Glasgow Haskell Compilation System, version 7.4.1

A more verbose output can be found here: https://gist.github.com/3810975#file_cabal.issue_verbose.txt

I tried to fix that with moving IO to System.IO - admittedly, it seems to be more involved than that. Unless I'm very much mistaken, this would involve moving any dependencies from haskell98 to base (that's bundled along with GHC, as is the case since GHC 7.0.1)

@mathw
Copy link

mathw commented Oct 1, 2012

It's probably to do with base now being Haskell 2010, and thus not having Haskell 98's library set visible. There's a way to get GHC to use the Haskell 98 set, which is more of a stopgap but might help get things up and running for a while (i.e. until they stop shipping Haskell 98's core libraries). As http://stackoverflow.com/questions/9555671/ghc-7-4-update-breaks-haskell98 answers explain:

ghc -package haskell98 -hide-package base

Because base is now Haskell 2012, you have to hide it and bring Haskell 98 in instead.

audreyt added a commit that referenced this issue Oct 1, 2012
  Still downloading Haskell Platform on Windows 8 here, so not
  exactly sure if it's the right fix... Will follow up soon.
@ghost
Copy link
Author

ghost commented Oct 1, 2012

Right, since we mostly rely on haskell98 for base packages, is it time to
switch to ghc's base?

Feel free to contact me over email and I'm willing to help out.
On Oct 1, 2012 7:14 PM, "Matthew Walton" [email protected] wrote:

It's probably to do with base now being Haskell 2010, and thus not having
Haskell 98's library set visible. There's a way to get GHC to use the
Haskell 98 set, which is more of a stopgap but might help get things up and
running for a while (i.e. until they stop shipping Haskell 98's core
libraries). As
http://stackoverflow.com/questions/9555671/ghc-7-4-update-breaks-haskell98answers explain:

ghc -package haskell98 -hide-package base

Because base is now Haskell 2012, you have to hide it and bring Haskell 98
in instead.


Reply to this email directly or view it on GitHubhttps://github.com//issues/25#issuecomment-9032316.

@ghost
Copy link
Author

ghost commented Oct 1, 2012

Hiding base package doesn't quite seem to be the right solution, since Compat.hs in pugs-compat uses System.Mem.Weak which is part of base. Using both haskell98 and base doesn't cut it either, since it leads to ambiguous Prelude errors.

Is there a better way of specifiying exact modules on a per-file basis?

audreyt added a commit that referenced this issue Oct 1, 2012
OK, that doesn't work. It appears to be a tricky problem...
Maybe we will end up splitting the "base" pugs-compat part
with the "haskell98" part.

This reverts commit 3ee7e28.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant