Ticket #91 (new defect)

Opened 2 years ago

Last modified 4 months ago

Building executables that use Template Haskell for profiling

Reported by: duncan Assigned to:
Priority: normal Milestone: Cabal-1.8
Component: Cabal library Version: 1.1.4
Severity: normal Keywords:
Cc: Difficulty: easy (<4 hours)
GHC Version: 6.5 Platform: Linux

Description

Programs that use TH need to be built twice if they are to be built for profiling. This is because TH needs to link with vanilla code, not the profiling variant.

We've added support for building libs for profiling that use TH, but that was easy as we alreay have support for building both profiling and vanilla libs at once.

So what needs to be done for building programs is if TH is used then we must build once (but not link) without profiling and then build again normally with profiling.

This will need testing with ghc-6.5/6.6 and a test added to the testsuite. One test ought to be able to cover the cases for libs and for executables, ie a lib that uses TH with an executable that uses it too.

Change History

03/19/08 05:23:34 changed by duncan

  • difficulty changed from normal to easy (<4 hours).

We think this works, we just need a test case adding to the testsuite.

04/24/08 03:24:26 changed by duncan

  • milestone set to Cabal-1.6.

08/15/08 07:12:11 changed by duncan

  • milestone changed from Cabal-1.6 to Cabal-1.8.