Ticket #1521 (closed bug: wontfix)
Problems building the time library with Cabal / Setup.hs
| Reported by: | Olivier Boudry | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Not GHC |
| Component: | libraries (other) | Version: | 6.6.1 |
| Keywords: | Cc: | michal.terepeta@… | |
| Operating System: | Windows | Architecture: | x86 |
| Type of failure: | None/Unknown | Difficulty: | Unknown |
| Test Case: | Blocked By: | ||
| Blocking: | Related Tickets: |
Description
I get the following error when building the time library using ghc-6.6.1 and Cabal-1.1.6.2.
C:\Temp\time>runhaskell Setup.hs configure
Setup.hs:17:29:
Couldn't match expected type `GHC.IOBase.ExitCode'
against inferred type `()'
Expected type: Args
-> Bool
-> PackageDescription
-> LocalBuildInfo
-> IO GHC.IOBase.ExitCode
Inferred type: Args
-> Bool
-> PackageDescription
-> LocalBuildInfo
-> IO ()
In the `runTests' field of a record
In the expression:
defaultUserHooks
{confHook = add_Win32_dep $ (confHook defaultUserHooks),
runTests = runTestScript}
I solved it by changing the type signature of runTestScript and removing the maybeExit function call from the body:
import GHC.IOBase ... runTestScript :: Args -> Bool -> PackageDescription -> LocalBuildInfo -> IO GHC.IOBase.ExitCode runTestScript _args _flag _pd _lbi = withCurrentDirectory "test" $ system "make"
Then, the Setup.hs script compiles but I get a dependency problem
C:\Temp\time>runhaskell Setup.hs configure Configuring time-1.1.1... configure: Dependency Win32-any: using Win32-2.1.1 configure: Dependency base-any: using base-2.1.1 Setup.hs: cannot satisfy dependency old-locale-any
I solved it with removing that dependency from the time.cabal file.
Last issue: at installation HsTimeConfig?.h is missing (copied it from ghc-6.6.1 source).
I don't know to which extent those problems are related to my specific installation. Looks like the user hooks signature has changed in the latest versions of Cabal.
Change History
Note: See
TracTickets for help on using
tickets.
