Ticket #231 (new defect)

Opened 10 months ago

Last modified 4 hours ago

"buildable: False" should fail the current configuration

Reported by: duncan Assigned to: nominolo
Priority: normal Milestone: Cabal-1.8
Component: Cabal library Version: 1.2.3.0
Severity: normal Keywords:
Cc: Difficulty: hard (< 1 day)
GHC Version: 6.8.2 Platform:

Description

Currently resolving configurations does not take account of the buildable field. It should act rather like build-depends: non-existant, though with a different error message.

If possible the error message should relate to the guard condition expression (the conjunction if there are several nested guards).

At the moment it is not considered at all and we don't notice that the package cannot be built until the build step, rather than the configure step.

One problem is that it's not clear if buildable: False is always fatal. People sometimes do that for test executables that are not supposed to be installed. So what should the behaviour be? The lib or only exe failing to configure must be an error.

Change History

02/04/08 17:22:16 changed by duncan

  • owner set to nominolo.

04/24/08 03:23:05 changed by duncan

  • milestone set to Cabal-1.6.

08/15/08 07:37:02 changed by duncan

Another possibility is to deprecate buildable for this use case and add fail instead which would provide an error message to indicate why a particular configuration is not possible.

The semantics would be slightly different to buildable: False. It would make configuring the whole package fail, not just disable building that executable or library.

12/02/08 16:53:55 changed by duncan

  • difficulty changed from normal to hard (< 1 day).
  • milestone changed from Cabal-1.6 to Cabal-1.8.

This is doable as part of a larger overhaul of configuration search.