I am trying to get wx installed using stack. I don't have Haskell installed globally and use stack new <app> new-template
to create a new project. Next, within the directory I run stack install wx
and get an error message:
In the dependencies for wx-0.92.3.0:
wxcore must match >=0.92, but the stack configuration has no specified
version (latest matching version is 0.92.3.0)
Following-up the recommended actions and rerunning stack install wx
a couple of times, the extra-deps list looks like this:
- wxcore-0.92.3.0
- wxc-0.92.3.0
- wxdirect-0.92.3.0
- Cabal-1.24.2.0
- process-1.4.3.0
- base-4.10.1.0
at this point, stack complains:
In the dependencies for process-1.4.3.0:
base-4.11.1.0 from stack configuration does not match >=4.4 && <4.11
(latest matching version is 4.10.1.0)
and suggesting to add base-4.10.1.0
again, but which is already there.
Q: so, how should I install wx?
Is it really that hard to get wxHaskell going? Should I start using cabal instead of stack? I use the latest stack version 1.7.1 with lts-12.4 as the resolver. A similar question was posted back in 2015.
base
(orCabal
andprocess
for that matter) other than what's in the resolver. You can try to reconfigure with--resolver lts-9.21
. LTS 9.21 had base 4.10, so that might work as long as you remove everything not wx-releated from your extra deps - Cubiclts-8.16
andextra-deps: - wxdirect-0.92.3.0 - wxc-0.92.3.0 - wxcore-0.92.3.0 - wx-0.92.3.0
. Don't you have a constraint onbase
in the cabal file? Good luck, I remember I had a hard time to make it work... - Stéphane Laurent