Skip to content

Instantly share code, notes, and snippets.

@23Skidoo
Created September 5, 2013 21:07
Show Gist options
  • Save 23Skidoo/6456188 to your computer and use it in GitHub Desktop.
Save 23Skidoo/6456188 to your computer and use it in GitHub Desktop.
A shell script for setting up a fresh EC2 Ubuntu 12.04 instance for GHC/Cabal development. Inspired by https://gist.github.com/rrnewton/6295246
#! /bin/sh
sudo aptitude update
sudo aptitude full-upgrade
sudo aptitude install build-essential git libgmp3-dev libgmp3c2 libgmp-dev pigz lbzip2 autoconf libtool zlib1g-dev libncurses-dev zile
wget http://www.haskell.org/ghc/dist/7.6.3/ghc-7.6.3-x86_64-unknown-linux.tar.bz2
tar xjvf ghc-7.6.3-x86_64-unknown-linux.tar.bz2
cd ghc-7.6.3
mkdir ~/bin/ghc-7.6.3
./configure --prefix /home/ubuntu/bin/ghc-7.6.3 && make install
cd ..
export PATH=$HOME/bin/ghc-7.6.3/bin:$PATH
git clone https://github.com/haskell/cabal.git
cd cabal/Cabal
runghc Setup.hs configure --user
runghc Setup.hs build
runghc Setup.hs install
cd ../cabal-install
sh bootstrap.sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment