[Haskell-cafe] How to direct cabal to use an alternative ghc version, ala stack?
capn.freako at gmail.com
Thu Sep 3 12:32:45 UTC 2015
Thanks to all, whom replied.
I found that a simple “stack install …” worked perfectly, as an alternative to “cabal install ...". Stack seems to have honored all the “cabal …” things I did in setting up my sandbox, including all my “cabal sandbox —add-source …” commands (5 in all). And, of course, it used the back-rev’d version of ghc I configured it (i.e. - stack) for.
That is SO neat that I can’t understand why it’s not a featured item in the Stack documentation.
Thanks, Stack crew!
On Sep 2, 2015, at 8:59 PM, Michael Snoyman <michael at snoyman.com> wrote:
> On Thu, Sep 3, 2015 at 3:37 AM, David Banas <capn.freako at gmail.com> wrote:
> Hi all,
> How do I direct cabal to use an alternative (i.e. - not my system’s default) version of ghc, which I’ve installed, via stack?
> I tried this:
> stack exec cabal install ...
> but got this:
> cabal: Use of GHC's environment variable GHC_PACKAGE_PATH is incompatible with
> Cabal. Use the flag --package-db to specify a package database (it can be used
> multiple times).
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> We have a flag to working better with cabal, you can try:
> stack exec --no-ghc-package-path -- cabal install
> I'm under the impression that there are changes planned to cabal (possibly already implemented but not released) that will allow it to function nicely with the GHC_PACKAGE_PATH environment variable, but I'm uncertain if that's true.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Haskell-Cafe