Table of Contents

Hacking

SVN repository

The sources are managed in a Subversion repository. You need a SVN client in order to retrieve the sources. You either use the svn CLI utility or a svn GUI (e.g. RapidSVN).

The repository is accessible at https://holdingnuts.svn.sourceforge.net/svnroot/holdingnuts

You can checkout the latest trunk with this command:

$ svn co https://holdingnuts.svn.sourceforge.net/svnroot/holdingnuts/trunk holdingnuts/trunk

You can also browse the sources via the trac source-browser.

Building the sources

Here is a list of requirements for building the sources:

Compiling on Linux

Make sure all needed development packages required above are installed. For instance on Ubuntu you need to install these packages:

# apt-get install build-essential cmake libqt4-dev libsqlite3-dev libsdl-dev

Preferred method (outer-src-dir build)

$ cd holdingnuts && ls
branches  tags  trunk
$ mkdir build && cd build
$ cmake ../trunk
$ make

Alternatively you can do a build in the source-directory

$ cd holdingnuts/trunk
$ cmake .     # take notice of the . at the end
$ make

Gentoo Linux - subversion snapshot ebuild

Only for Gentoo Linux users: There's a holdingnuts snapshot ebuild which allows conveniently building a snapshot from SVN repository. Place this file in an overlay (e.g. /usr/local/portage/games-board/holdingnuts/holdingnuts-9999.ebuild) and perform the usual steps needed for emerging external ebuilds.

Compiling on Windows

Currently there's support for compiling with MinGW32. However, building with Visual C++ should work (with some tweeks!).

Dependencies:

Important: Avoid using spaces in paths or you may run into problems!

Short instruction (console only)

C:\>cd holdingnuts\trunk

; If you're building with MinGW, run this (take notice of the . at the end)
C:\holdingnuts\trunk>cmake -G "MinGW Makefiles" .
C:\holdingnuts\trunk>mingw32-make

; If you're building with Visual C++ (adjust your Visual Studio version), run this (take notice of the . at the end)
C:\holdingnuts\trunk>cmake -G "Visual Studio 9 2008" .
; Now you can open the resulting project-file with Visual Studio.

Long instruction (GUI/console)

Follow these steps for building the sources on Windows:

When building with MinGW
These steps are needed for both variants (MingGW and Visual Studio)
When building with MinGW
When building with Visual Studio

Compiling on Mac OS X

The steps are similar to the steps needed for Linux. There are pre-compiled libs for SDL and Qt4 available. You may either have your own environment setup for compiling or you can use MacPorts.

If you're going to build with MacPorts, you'll need to install these tools and libraries:

sudo port install cmake qt4-mac libsdl

If you run into a strange problem with your linker, try to add libc to the linker-flags:

CMAKE_EXE_LINKER_FLAGS:STRING=-lc

What's next?

Read how to setup your HoldingNuts environment.

For further information please take a look at Development and Participate.