Opened 9 years ago

Closed 9 years ago

Last modified 7 years ago

#859 closed bug (fixed)

Highly misleading missing-package error message

Reported by: simonpj Owned by:
Priority: normal Milestone:
Component: Compiler Version: 6.4.2
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: Test Case:
Blocked By: Blocking:
Related Tickets: Differential Revisions:

Description

GHC reports

ghc.exe: unknown package: ghc-6.5

But it's there all right:

sh-2.04$ ../utils/ghc-pkg/ghc-pkg-inplace list
c:/darcs/fc2/driver/package.conf.inplace:
    Cabal-1.1.4, Win32-1.0, base-1.0, (ghc-6.5), haskell98-1.0,
    rts-1.0, template-haskell-1.0

The real problem is revealed by using -v

...
package ghc-6.5 will be ignored due to missing dependencies:
  Win32
...
ghc.exe: unknown package: ghc-6.5

So the culprit is that Win32 isn't there, not that ghc-6.5 isn't there. The error message is jolly misleading.

There's nothing ghc/win32 specific about this. It's a bug in the package machinery.

Change History (3)

comment:1 Changed 9 years ago by simonmar

  • Resolution set to fixed
  • Status changed from new to closed

I've fixed this:

  • error messages about missing packages now state if the missing package is a dependency of some other package.
  • the build system will now fail rather than register a package with missing dependencies.
  • packages with missing dependencies are now not simply dropped from the package database in GHC unless they depend on a package that was explicitly ignored with -ignore-package.

comment:2 Changed 7 years ago by simonmar

  • Architecture changed from Unknown to Unknown/Multiple

comment:3 Changed 7 years ago by simonmar

  • Operating System changed from Unknown to Unknown/Multiple
Note: See TracTickets for help on using tickets.