Skip to content

Supporting builddir in cabal.project and global config #5271

Open
@merijn

Description

@merijn

To the best of my knowledge, new-X don't currently obey builddir entries in cabal.project. There was some speculation that there was a technical reason for this, but at first glance of the code it just seems the problem is laziness. That is, all code paths dealing with computing the DistDirLayout try and resolve the cabal.project path and builddir in a single step.

It seems fairly straightforward* to split this into two steps, first looking up cabal.project and the project path, then checking establishing the DistDirLayout after that. I would assume that the logical priority for determining builddir would be:

  1. commandline --builddir flag
  2. builddir in cabal.project
  3. default to dist-newstyle

If no one has any theoretical objections I'll try and see if I can get it working as straightforwardly as I hope it to be :p

[*] - Famous last words.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions