Open
Description
There seem to be no way to specify cabal flag for dependencies. In ghc-tags
and ghc-tags-plugin
I would like to use ghc-tags-core
as a dependency but:
ghc-tags
needs-f +ghc-lib
, by defaultghc-tags-plugin
needs-f -ghc-lib
by default
The cabal's file build-depends
only allow to specify version constraints. cabal.project
file allows to include constraints but it's not distributed through hackage
users will need to use:
cabal install -f +ghc-lib ghc-tag
cabal install -f -ghc-lib ghc-tags-plugin
which is far from perfect (because cabal install ghc-tag
would fail or the other one depending what is the default value for ghc-lib
flag). Is there a way around this? If not what would be the right solution:
- add a way to configure dependency flags in a
.cabal
file? - a way to distribute an executable with its
cabal.project
file (socabal install
would take it into account)? this could work forghc-tags
andghc-tags-plugin
, but it wouldn't in other scenarios - something else?