En/Get Unknown Horizons

From Unknown Horizons

Jump to: navigation, search

The following article contains instructions to download and install Unknown Horizons.

Contents

The Basics

  • First of all, nobody should be discouraged by the length of this article. It just covers a lot of issues.
  • Please, previously read everything relevant for you exactly.
  • Generelly it is not necessary to compile Unknown Horizons. Merely the libraries for executing Python files are needed. For Linux they are mostly pre-installed and for Windows easy to post-install. (How it is done exactly is explained further below.)
  • Developers or people maybe going to get one can download the current SVN revisions of FIFE and Unknown Horizons and compile the engine themselves. (How this is done exactly is also explained further below.)

Download last stable version

The last official and stable Release of Unknown Horizons can always be found here.

  • For Windows there is an installer shipping with Python and OpenAL.
  • For Linux a tar.gz archive with binaries for FIFE and the stable Unknown Horizons release each for 32bit- and 64bit-architecture.
    • NOTE: You need the 1.34 version of libboost to run Unknown Horizons

Common users can now stop reading this article right here.

Download and compile SVN revision

Build dependencies

Supported build environments

Supported compilers

Framework

SDL addon libs

  • SDL_ttf >= 2.0
  • SDL_image

Sound libs

  • libvorbis
  • libvorbisfile
  • libogg
  • OpenAL

GUI/RAD libs

Scripting-related libs

Compression libs

Optional libs

  • libopengl & libglu >= 1.3: for additional OpenGL support.

SVN clients

A SVN client is required to download the SVN revision. The following list provides some recommendations for software to use. A detailed list of clients can be found on Tigris.org .

SVN web interface

  • The Unknown Horizons code can be viewed online via webinterface.

Windows

Linux

Multi-platform

LINUX

Resolve build dependencies

Debian/Ubuntu

apt-get install -y build-essential scons libalsa-ocaml-dev libsdl1.2-dev libboost-dev libsdl-ttf2.0-dev libsdl-image1.2-dev libvorbis-dev libalut-dev python-dev libboost-regex-dev libboost-filesystem-dev libboost-test-dev swig zlib1g-dev libopenal-dev subversion libguichan-dev python-yaml python-distutils-extra intltool

Gentoo

emerge --ask --verbose --noreplace libvorbis libogg media-libs/openal guichan boost libsdl sdl-image sdl-ttf scons subversion pyyaml python-distutils-extra intltool

Check out SVN revision

FIFE SVN:

Unknown Horizons SVN:

The most simple and fastest way on Linux is - as often - using the command line in a terminal. Experienced user will know themselves what to do. Therefore a detailed example for the less experienced ones will follow here:

  • Start a terminal, switch to the /home folder and create the directory structure for FIFE and Unknown Horizons:
:~$ mkdir UnknownHorizons && cd UnknownHorizons
:~/UnknownHorizons$ mkdir fife UnknownHorizons
  • Then download the SVN revisions of FIFE and Unknown Horizons into the corresponding folders:
:~/UnknownHorizons$ cd fife && svn co http://fife.svn.cvsdude.com/engine/trunk
:~/UnknownHorizons/fife$ cd ../UnknownHorizons && svn co svn://unknown-horizons.org/unknown-horizons/trunk
  • To update to a newer revision just run a SVN update in the corresponding folders:
:~/UnknownHorizons/fife/trunk$ svn up
resp.
:~/UnknownHorizons/UnknownHorizons/trunk$ svn up

Compile FIFE

If all build dependencies are resolved successfully (see above) FIFE should compile problem-free. Because of some libraries causing troubles the FIFE SVN repository was extended with source files of some libraries which can be compiled and installed using the command scons ext=1 if wanted. (This involves guichan, openAL-soft and libpng.) In general this is the recommended procedure why this step is picked up in the following example as well.

  • To compile FIFE just switch into the /trunk directory and use the following command:
:~/UnknownHorizons/UnknownHorizons$ cd ../fife/trunk
:~/UnknownHorizons/fife/trunk$ scons ext && scons
  • Optionally, FIFE can be compiled without debug to get more performance for gameplay:
:~/UnknownHorizons/fife/trunk$ scons ext && scons debug=0
  • If FIFE is already compiled and an SVN update is made it has to be recompiled.
  • Unknown Horizons itself does not need to be compiles because it entirely acts as scripts and media (graphics, sound and so on).

The allround-script

This script downloads the current FIFE revision, compiles the engine, followed by downloading the current Unknown Horizons revision and moving it into a separate sub-folder. For all of you in hurry or to lazy to type.

Start Unknown Horizons

  • To start Unknown Horizons just the run_uh.py has to be executed. Therefor different possiblilities exist:
:~/UnknownHorizons/UnknownHorizons/trunk$ python run_uh.py
or
:~/UnknownHorizons/UnknownHorizons/trunk$ ./run_uh.py
or from anywhere
:/$ python ~/UnknownHorizons/UnknownHorizons/trunk/run_uh.py
  • If the start file run_uh.py was set executable it can be started via double click in a file manager.
  • Optionally Unknown Horizons can be integrated in you system to get started by typing unknownhorizons in command line, script or launcher only. Thereto the following commands have to be executed in terminal with root permission:
:~# echo '#!/bin/bash' > /usr/local/bin/unknownhorizons
:~# echo 'python ~/UnknownHorizons/UnknownHorizons/run_uh.py' >> /usr/local/bin/unknownhorizons
:~# chmod +x /usr/local/bin/unknownhorizons

Windows

Hinweis Note / Hinweis / Remarque:
Dieser Artikel oder Abschnitt ist nicht vollständig. Bitte erweitere ihn.

After downloading the SVN-client, create 2 or 3 directories like the following example:

~/UnknownHorizons
 |
 |- /UnknownHorizons
 |
 |- /FIFE

Resolve build dependencies

Check out SVN-Version

Right click on one of the directories -> SVN-Checkout -> paste the following URLs at "URL of repository", then press Ok.

FIFE SVN:

Size: 46,11 MB at 28.11.2008

Unknown Horizons SVN:

Size: 116,33 MB at 28.11.2008

Update SVN-Version

Right click on the directory again -> SVN-Update

Compile FIFE

Howto

Run Unknown Horizons

Click on <UnknownHorizons>\trunk\run_uh.py

Personal tools
Unknown Horizons
Design Document