2006-04-24
Building wxFruit and Yampa with GHC 6.4.x
wxFruit is a Haskell GUI library based on Functional Reactive Programming concepts. It uses wxWindows as its underlying GUI framework. For FRP it uses the Haskell FRP framework Yampa.
Both libraries are relatively old and seem to have suffered bitrot as I couldn't get them to compile using a recent GHC build (GHC 6.4.x). A bit of searching came across this post to the haskell-jp list which had some patches to enable these to build. I've extracted the relevant patches here:
These can be applied by using 'patch' from within the original wxFruit and Yampa distributions:
cd afrp-0.4
patch -p1 <afrp.diff
cd ../wxfruit-0.1
patch -p1 <wxfruit.diff
Alternatively you can download the already patched versions I've made here:
To build and install the patched Yampa, the following should work:
cd afrp-0.4
runhaskell Setup.hs configure
runhaskell Setup.hs build
sudo runhaskell Setup.hs install
Once this is done the wxFruit paddle example builds with:
cd ../wxfruit-0.1
ghc --make -farrows -o paddle paddle.hs