[Crossfire-wiki] [Crossfire DokuWiki] page added: crossfire_client_compile_guide

no-reply_wiki at metalforge.org no-reply_wiki at metalforge.org
Sat Sep 1 20:39:03 CDT 2007


A page in your DokuWiki was added or changed. Here are the details:

Date        : 2007/09/01 20:39
User        : 
Edit Summary: Created an initial outline.  It is mostly relevant, but needs work.

This is a quide on how to download crossfire-client sources from SVN and basic instructions on compiling a crossfire client for local use or testing.  Please post build instructions for various operating environments.

===== *nix =====

==== Requirements ==== 

FIXME -- requirements list needs some fine tuning

Many of these packages (listed alphabetically) may already be installed on your system, but this list may help with setup of a build environment.  When in doubt, carefully look over the results of the ./configure step as it will often imply when packages are missing.  Everything is not always required, but without everything, certain functionality may be disabled.

===General===

  * autoconf2.5 - A tool for building configure scripts.
    * Normally autoconf is not required for building, but the current SVN client trunk does require it.
  * automake1.9 - A tool for generating GNU Standards-compliant Makefiles.
  * flex - A fast lexical analyzer generator
    * m4 - a macro processing language (required by flex)
  * gcc - The GNU C compiler
  * libgd-tools - GD command line tools and example code
    * libgd2-noxpm - GD Graphics Library version 2 (without XPM support) (required by libgd-tools)
  * libgd2-xpm-dev - GD Graphics Library version 2 (development version)
  * libtool - Generic library support script
  * make - The GNU version of the "make" utility
  * subversion - advanced version control system (aka. svn)
      * libapr0 - the Apache Portable Runtime (required by subversion)
      * libsvn0 - shared libraries used by Subversion (aka. svn) (required by subversion)

===X11 Client===

  * FIXME (more...)

===First GTK Client===

  * FIXME (more...)

===Second GTK Client===

  * libglade2.0_0-devel
  * libglade-2.0
  * libgtk-x11-2.0
  * libxml2
  * libz
  * libgdk-x11-2.0
  * libatk-1.0
  * libgdk_pixbuf-2.0
  * libm
  * libpangocairo-1.0
  * libpango-1.0
  * libcairo
  * libgobject-2.0
  * libgmodule-2.0
  * libdl
  * lglib-2

Note:  For x86_64 systems, do not mix 64-bit and 32-bit libraries unless it cannot be helped.  For example, libsvn0 is a 32-bit library, but lib64svn0 is the 64-bit equivalent.  The build process may fail in the linkage stage if a 32-bit library is linked during a 64-bit build.
 
==== Recommended Packages ====

Recommended packages provide additional add-ons or functionality to the client, or allow more than one client to be built.  It is quite possible to get a perfectly acceptable client functional without having all of the recommended packages.

  * libSDL
  * libSDL_image
  * FIXME (more...)

==== Useful Packages ====

These useful packages are not normally required for end-user builds, but they come in handy in cases where developers may have forgotten to check in changes to build scripts, etc.

  * cproto - supports `make proto` to automatically update prototype files.
  * sudo - Provide limited super user privileges to specific users
    * Not required, but `sudo make install` is useful for installing to system directories.
    * sudo is also useful for installing packages that are missing.
    * Do not run `make` as the root user for security reasons.

==== START HERE ====

This is the starting point and confirms you are located in your home directory

   $ cd ~
   $ pwd
   /home/<username>

==== DOWNLOAD ====

  * Trunk contains the newest features and development for the game
  * Branch contains the most recent "stable" version of the game
  * Tags is an official & stable release of the game

**IMPORTANT** - One should be consistent with what is checked out; meaning use all trunk server & archetypes & maps or branches/1.x server & archetypes & maps or tags/1.10.0 server & archetypes & maps otherwise a strong risk of failure due to incompatibilities exists (broken maps, missing graphics, etc.)

The follow steps may be used to download the client source files to your computer.

=== Trunk ===

  $ svn co https://crossfire.svn.sourceforge.net/svnroot/crossfire/client/trunk client.svn

=== Branch ===

These steps have you download branches/1.x

  $ svn co https://crossfire.svn.sourceforge.net/svnroot/crossfire/client/branches/1.x client.svn

=== Tag ===

Here's how to download Tag using the 1.10.0 release as an example

  $ svn co https://crossfire.svn.sourceforge.net/svnroot/crossfire/client/tags/1.10.0 client.svn

==== SETUP ====

Confirm that you are still in your home directory

   $ cd ~
   $ pwd
   /home/<username>

Now change the working directory to the directory where the client sources were downloaded.

   $ cd client.svn

Confirm that you are in the client source directory

   $ pwd
   /home/<username>/client.svn

A "fool-proof" build preparation that should always work.  By "fool" we're talking about a forgetful developer, not the builder, though nobody can really fool-proof software against bugs, so your mileage may vary.

   $ export CFLAGS="-ggdb -g -O0"; ./autogen.sh --prefix=${HOME}

The export statement enables debugging and disables optimization to facilitate debugging.  These settings are useful when running software that has not been released, and is the recommended practice so that if a bug is encountered, it will be possible to collect more data about the bug.

The autogen.sh script re-creates the configure (./configure) script.  It accepts the same options as would normally be pass to ./configure.  This command requires both autoconf and automake to be installed.

This process attempts to locate required resources, and also discover whether or not required resources are installed.  It is okay to proceed directly to compilation, but almost certainly the output of the ./configure process needs to be review, and packages may need to be installed based upon what features or functionality is desired.  The ./configure output generally indicates whether it will  or will not build particular clients.
  
==== COMPILE ====

Now, begin the compile process; choose one of the following:

  $ make && make install

==== LAUNCH ====

Once the server has been successfully built (aka compiled), you need to launch the Crossfire Server application

Double check that you are in the correct directory which is the server directory

   $ pwd
   /home/<username>/client.svn

Note:  For the GTK clients, the version numbers are sometimes confusing.  The first client to use GTK is often called the GTK 1 client because it was originally compiled with GTK+-1.x, but now it is often compiled with  GTK+-2.x.  The second client developed with GTK is called the gtk-v2 client.  It used to be built with GTK+-2.x, but has now been converted to build against libglade-2.0 (which requires GTK+-2.0 and other related libraries).  The gtk-v2 client is designed to build with GTK+1.0 libraries.

===X11 Client===

FIXME

===Version 1 GTK Client===

FIXME

===Version 2 GTK Client===

Change directory the gtk-v2 directory

  $ cd gtk-v2/src

Your file directory path should look like this:

   $ pwd
   /home/<username>/client.svn/gtk-v2/src

Run this command to launch the server:

  $ ./crossfire-client-gtk2 &

The command runs the Crossfire Client and returns you back to a shell prompt

FIXME Add gdb instructions and discuss possible issues regarding .glade layout files.

===== Microsoft (c) Windows =====

FIXME


IP-Address  : 66.137.82.229
Old Revision: none
New Revision: http://wiki.metalforge.net/doku.php/crossfire_client_compile_guide

-- 
This mail was generated by DokuWiki at
http://wiki.metalforge.net/




More information about the crossfire-wiki mailing list