Opened 8 years ago

Closed 8 years ago

#861 closed bug (fixed)

-prof without profiling libraries fails without explanation

Reported by: guest Owned by:
Priority: normal Milestone:
Component: Compiler Version: 6.4.2
Keywords: prof profile libraries Cc:
Operating System: Linux Architecture: x86_64 (amd64)
Type of failure: Difficulty: Unknown
Test Case: Blocked By:
Blocking: Related Tickets:

Description

Compiling with -prof caused ghc to fail on the first import, claiming that the module to be imported could not be found (it worked perfectly without -prof).

Initialliy I thought the -prof was just plain buggy.
After a while I realised the real reason was that the profiling library package was not installed.

The bug here is a lack of error report by the compiler. Something like "Profile libraries not found". Instead, the way it fails is totally unrelated to the cause.

Change History (2)

comment:1 Changed 8 years ago by duncan

This is actually a fairly common thing that users fall over because by default distros like debian do not install the profiling libraries. In debian they live in seperare "-prof" packages which need to be installed. It's not hard you just need to know that's what you need to do. So perhaps any improvement to the error message in this area might suggest that the profiling libs are missing and probably need to be installed.

comment:2 Changed 8 years ago by simonmar

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

Fixed. eg:

conc056.hs:5:0:
    Failed to load interface for `Control.Concurrent.STM':
      Perhaps you haven't installed the profiling libraries for package stm-1.0?
      Use -v to see a list of the files searched for.
Note: See TracTickets for help on using tickets.