Installing

Linux

Helm is mainly developed and tested on Linux, so it is obviously the easiest platform to develop with. To install Helm on Linux, you will first need to install all the dependencies through your package manager. Helm depends on the the following development libraries being present:

  • Cairo 1.x.x
  • SDL 2.0.x
  • Pango 1.x.x

You will also need to install GHC 7.6+ and its accompanying Cabal. This can be done the old fashioned way, or can be done entirely through Stack, which is recommended.

If you use Stack, running stack setup will have been sufficient to install the latest version of the GHC. You can confirm that the installed GHC is definitely version 7.6 (or later) by checking that the output of stack ghc -- --version (or just ghc --version for independent installation) is something similar to the following:

$ stack ghc -- --version
The Glorious Glasgow Haskell Compilation System, version 7.6.3

Once GHC has been installed, use the following to install the Helm haskell package (replace “stack” with “cabal” if using Cabal directly):

$ stack update
$ stack install gtk2hs-buildtools
$ stack install helm

The gtk2hs dependency needs to be installed manually because it is required to build the Cairo bindings. You can now start using Helm to make games!

macOS

You will first need to install the Haskell Platform 2013.2.0.0 for Mac and the Xcode command line tools. The complete instructions for this process are on the linked download page. Once the Haskell platform has been installed through its installer, confirm that the installed version of GHC is definitely 7.6 (or later) by checking that the output of ghc --version is something similar to the following in a new Terminal window:

$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 7.6.3

In order to install Helm, you will first need to install the same external dependencies discussed in the Linux section using an OS X package manager. For this guide we’ll only be explaining the process using the Homebrew package manager, but it should be similar tactics for others. Firstly, install the latest version of Homebrew from its website. You can then run the following commands to install the dependencies using Homebrew:

$ brew doctor # if this is your first time using homebrew
$ brew install sdl2
$ brew install cairo --without-x11
$ brew install pango --without-x11

We need to add the --without-x11 flag when installing Cairo and Pango because we can’t use the X11 backend on OS X without an X11 server (not that we want to, anyway). We can now run the Cabal package manager included in the previously installed Haskell platform to install the Helm libraries (in a similar manner to Linux):

$ cabal update # if this is your first time using cabal
$ cabal install gtk2hs-buildtools
$ cabal install helm

You’re ready to start making games!

Windows

Coming soon!


© 2013-2014 Switchface Studios

#haskell-game