BuildingOnLinux.wiki
author kyberneticist@gmail.com
Sun, 14 Oct 2012 14:27:06 +0000
changeset 253 d7db074d6efa
parent 250 9c711f1b4638
child 263 afcb38bfd761
permissions -rw-r--r--
unc0rr added another dependency

#summary Instructions for building the development version of Hedgewars on Linux (debian focus)
#labels Phase-Implementation,Phase-Deploy,Phase-Support

= Introduction =

Copy and Paste instructions for a Hedgewars development build. Should work on Debian and the like (Ubuntu, Mint).  Packages for other distros should have similar names.  Remember to copy the *entire* apt-get lines!

= Prerequisites =

{{{
sudo apt-get install mercurial cmake qt4-qmake libqt4-dev libsdl1.2-dev libsdl-net1.2-dev libsdl-mixer1.2-dev libsdl-image1.2-dev libsdl-ttf2.0-dev liblua5.1-dev fpc
}}}
If you want PNG screenshots, add:
{{{
sudo apt-get install libpng12-dev
}}}
If you want video recording, add:
{{{
sudo apt-get install libavcodec-dev libavformat-dev freeglut3
}}}
If you want to try building the server as well (requires at least libghc base 4.3 now) try these too:
{{{
sudo apt-get install ghc libghc-binary-dev libghc-bytestring-show-dev libghc-dataenc-dev libghc-deepseq-dev libghc-hslogger-dev libghc-mtl-dev libghc-network-dev libghc-parsec3-dev libghc-utf8-string-dev libghc-vector-dev
}}}

= Building process =

{{{
mkdir -p ~/games ~/hg/hedgewars/build
cd ~/hg/hedgewars
hg clone -v https://hedgewars.googlecode.com/hg/ trunk
}}}

The initial clone of the repository will take a while, is about 575MiB or so...

{{{
cd ~/hg/hedgewars/build
cmake ../trunk -DCMAKE_BUILD_TYPE="DEBUG" -DCMAKE_INSTALL_PREFIX="$HOME/games" -DDATA_INSTALL_DIR="$HOME/games" -DNOSERVER=1
make install
}}}
if you want to build the server as well, change -DNOSERVER=1 to -DNOSERVER=0

then wait for the build to complete, then run ...

{{{
~/games/bin/hedgewars
}}}

You can also create a launcher for it on your desktop or on applications menu if you wish, using the ~/games/bin/hedgewars path

== Build Updates ===

{{{
cd ~/hg/hedgewars/build
hg -R ../trunk pull -u
cmake ../trunk -DCMAKE_BUILD_TYPE="DEBUG" -DCMAKE_INSTALL_PREFIX="$HOME/games" -DDATA_INSTALL_DIR="$HOME/games" -DNOSERVER=1
make install
}}}