User:Harm/Debian

From FreeOrionWiki
Revision as of 18:44, 5 February 2006 by Harm (Talk | contribs) (Compiling FO 0.3 on Debian)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Compiling FreeOrion on Debain unstable (5 Februari 2006)

The old way to compile FreeOrion, as described in the section Compile, did not work at all for me. But as FreeOrion is under heavy development these frequent changes are understandable. The version I compiled was revision 1727 from the sourceforge Subversion server.

Getting the right version(s)

This proved harder than I thought the downloads from the sourceforge website didn't work for me. Neither did the version from CVS. I believe FreeOrion and perhaps even sourceforge are moving toward Subversion(SVN), this is great and this is thus the way I got my version.

GiGi

Note that FO needs GiGi to compile, more on this later but first get the most recent revision(mine was 507).

svn co https://svn.sourceforge.net/svnroot/gigi/trunk gigi

FreeOrion

Go to an other dir and do

svn co https://svn.sourceforge.net/svnroot/freeorion/trunk freeorion

Required Libraries

The easy

This was the fun part. This is a list of packages which I could just apt-get. Note that perhaps (even likely) not all packages (or better their dependancies) are necessary!

  • bcp, this is the boost thingy. I got version 1.33 and that worked in contrast to other material you might read.
  • libdevil-dev, the dependancies fix the rest.
  • freeglut3-dev, some GL stuff
  • libsdl1.2-dev
  • autoconf, to use scons
  • automake, idem
  • graphviz-dev, important, I will get back on this.

The not-so-easy to downright nightmarish

As top ranking bad library I would pick log4cpp. The package in apt was version 0.2.8 which didn't work when compiling GiGi. Scons actually complained about not having a version higher then 0.3.4b. So I went to the sourceforge page and downloaded the latest version 0.3.5rc3. This however has a bug in it regarding a semicolon at the end of the Manipulator.hh file, see this nasty bug, luckily this could be easily repaired by removing the semicolon. This bug can be circumvented by using an gcc compiler older than 4.x, like 3.3. This will result in a correct compilation but you must make sure that you use the same version to compile GiGi and FO as well. Otherwise everything might compile just fine but execution will result in a segmentation fault.

Better was FMOD. Just grab it from [www.fmod.org] and dump it somewhere you can find. All material you really need is in the api subdirectory.

Compile already

GiGi

This was easy, just run

scons
scons install

The latter you want to run as root.

FreeOrion

More of a challenge. First of all be sure to point to the correct paths with scons. This basicly entails you tell scons where to find FMOD and Graphviz. The content of my option.cache file looked something like:

with_fmod = '/path_to/fmodapi375linux'
with_fmod_include = '/path_to/fmodapi375linux/api/inc'
with_fmod_libdir = '/path_to/fmodapi375linux/api'
with_graphviz_libdir = '/usr/lib/graphviz'

Second also change the build_config.py file in the root directory of FreeOrion to read

fmod_version = '3.75'

instead of

fmod_version = '3.74'

Now you should be in the clear. Run

scons

from the root directory and cross your fingers. If all is done run from the root directory

./freeorion

to start a brave, young empire.

Notes

Rerun scons

It might (and probably will) happen that something went wrong. In such a case try to rerun the scons configuration steps with

scons configure

otherwise you might end up with using stale cached parameters.

System requirements

FO needs a screen resolution of at least 1024x768, better to find that out now then after a couple of days trying to compile the thing like I did (running 800x600). It did run however on my LifeBook P3 500Mhz Celeron M with 256MB and was even quite responsive.

Compile requirements

Be sure to have a lot of time and a lot of internal memory (more than 256MB is highly recommended, did finish some books though).