2

I was trying to install the reactive banana package on Windows, with little success. It seems to know about the packages, but fail on installation. Any hints?

>cabal install Reactive
Resolving dependencies...
...
cabal: Error: some packages failed to install:
category-extras-0.53.5 failed during the building phase. The exception was:
ExitFailure 1
reactive-0.11.5 depends on category-extras-0.53.5 which failed to install.

>cabal install category-extras
Resolving dependencies...
Configuring category-extras-0.53.5...
...
cabal: Error: some packages failed to install:
category-extras-0.53.5 failed during the building phase. The exception was:
ExitFailure 1

>cabal install reactive-banana-wx
Resolving dependencies...
Downloading monads-tf-0.1.0.0...
Warning: monads-tf.cabal: A package using 'cabal-version: >=1.2.3' must use
section syntax. See the Cabal user guide for details.
...
setup.exe: wx-config: does not exist
cabal: Error: some packages failed to install:
reactive-banana-wx-0.3.0.1 depends on wxcore-0.12.1.7 which failed to install.
wx-0.12.1.6 depends on wxcore-0.12.1.7 which failed to install.
wxcore-0.12.1.7 failed during the configure step. The exception was:
ExitFailure 1

etc...

OK, I got all the wx-stuff installed - took several steps. wx-config, then wxWidgets, then install the Haskell parts (wx, wxcore, reactive-banana.wx). But the basic Reactive and category-extras still fail as above. - step 39 of 99 of category-extras fails:

[39 of 99] Compiling Control.Monad.Either ( src\Control\Monad\Either.hs, dist\bu
ild\Control\Monad\Either.o )

src\Control\Monad\Either.hs:44:10:
    Duplicate instance declarations:
      instance Monad (Either e)
        -- Defined at src\Control\Monad\Either.hs:44:10-25
      instance Monad (Either e) -- Defined in Control.Monad.Instances

src\Control\Monad\Either.hs:49:10:
    Duplicate instance declarations:
      instance Applicative (Either e)
        -- Defined at src\Control\Monad\Either.hs:49:10-31
      instance Applicative (Either e) -- Defined in Control.Applicative

src\Control\Monad\Either.hs:53:10:
    Duplicate instance declarations:
      instance MonadFix (Either e)
        -- Defined at src\Control\Monad\Either.hs:53:10-28
      instance MonadFix (Either e) -- Defined in Control.Monad.Fix
cabal: Error: some packages failed to install:
category-extras-0.53.5 failed during the building phase. The exception was:
ExitFailure 1

Update:

I find the Wx universe for Haskell a bit of a mess. There are lots of notes on this and descriptions of issues with wx & wxHaskell on windows, requiring old versions of GHC in some suggestions, etc. The code is not compatible with current MSoft compilers, so require other compiler installs, etc. All in all fairly disappointing to me after a few hours of poking at it. I did install wx-config, wxPack, wxWidgets, then wxHaskell, and then from cabal wx & wxcore; all reported success - still it failed (wxmsw28_gcc.dll not found; although it is in the library). Their initial tests (samples/controls...) fail. All of the samples links and many more are broken on the wxWidgets and wxHaskell pages. After a reboot (?!) it does seem to run some tests - so I am hoping for success now.

I was hoping for a magic "apt-get install" like experience.

For FRP -- The FRP examples (in leksah) give lots of: "Link destinations not found for..." error messages, but so far now do run.

All in all it from my experience it seems like wxHaskell and FRP don't seem very easy to use on Windows. Certainly not something I'd assign to a class to try as a good example of Haskell's ease and utility! :-)

I appreciate all the complexity and work involved in these packages, and don't mean to complain - just an experience report. Perhaps the wxHaskell packages are not commonly used, or ..??

2
  • Looks like you need wx-config, which is probably part of wxWindows? Jul 11, 2011 at 18:09
  • OK, I got all the wx-stuff installed - took several steps. wx-config, then wxWidgets, then install the Haskell parts (wx, wxcore, reactive-banana.wx). But the basic Reactive and category-extras still fail as above.
    – guthrie
    Jul 12, 2011 at 2:48

2 Answers 2

6

Note that you have to include the "banana" in "reactive-banana". :-)

cabal install reactive-banana
cabal install reactive-banana-wx

In other words, Reactive is not the package you are looking for, reactive-banana is. (The Reactive package is an older experiment by Conal Elliott with similar goals, but it has a few systemic bugs and has now bitrotted a bit.)

2
  • Thanks - this fixed it! Seems like there are install problems with the other package (see above), glad to avoid them.
    – guthrie
    Jul 12, 2011 at 12:34
  • Note: similar error resolved by "apt-get install libwxgtk2.8-dev" on my Debian.
    – Vi.
    Oct 31, 2011 at 18:16
1

It looks like there's a windows port of wx-config here. I'd be surprised if it isn't in wx-core already. Do you have the WX c library installed? It is needed - the Haskell package is just bindings to the C library.

2
  • I think I found a binary download at sourceforge - odd that it is not mentioned on their home page(!). link Adding the wx-config you pointed to didn't make nay difference.
    – guthrie
    Jul 11, 2011 at 20:12
  • @guthrie then compile it yourself? I think thats what they recommend anyway Jul 12, 2011 at 0:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.