2003-11-21 00:52:27 +00:00
|
|
|
Prerequisites:
|
2003-09-15 11:52:41 +00:00
|
|
|
|
2006-06-06 00:05:03 +00:00
|
|
|
You'll need to have these libraries (with equivalent devel versions) to build Wesnoth:
|
2003-10-28 09:37:37 +00:00
|
|
|
|
2007-04-25 14:37:52 +00:00
|
|
|
libsdl1.2.7
|
|
|
|
libsdl-image1.2 (with png support)
|
2003-10-28 09:37:37 +00:00
|
|
|
libsdl-mixer1.2 (with Vorbis support)
|
2006-06-05 14:00:19 +00:00
|
|
|
libsdl-net
|
2008-03-04 18:24:15 +00:00
|
|
|
libsdl-ttf2.0.8
|
2007-12-05 17:27:08 +00:00
|
|
|
libz
|
|
|
|
boost_iostreams >= 1.33.0
|
2008-03-04 16:58:45 +00:00
|
|
|
boost_regex >= 1.33.0
|
2008-03-28 13:49:18 +00:00
|
|
|
|
|
|
|
You will need the following tools:
|
2007-04-25 14:37:52 +00:00
|
|
|
|
|
|
|
python2.4
|
2008-03-28 13:49:18 +00:00
|
|
|
scons
|
2003-09-15 11:52:41 +00:00
|
|
|
|
2004-10-30 15:16:37 +00:00
|
|
|
SDL* libraries can be found at http://www.libsdl.org . libfreetype can be found
|
2007-12-05 17:27:08 +00:00
|
|
|
at http://www.freetype.org/ . python can be found at http://www.python.org .
|
|
|
|
The boost libraries can be found at http://www.boost.org .
|
2003-09-15 11:52:41 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
You will also need to have a working installation of GNU gettext to build the
|
2005-02-19 12:21:23 +00:00
|
|
|
translations.
|
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
Note: It has been reported (see https://gna.org/bugs/index.php?10326)
|
|
|
|
that under gcc 3.3.6 you need to turn off optimizations or you will
|
|
|
|
get a build that doesn't work for multiplayer. We recommend building
|
|
|
|
with gcc 4.
|
2007-12-05 17:27:08 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
If you see lots of messages like "Type 'svnversion --help' for usage.",
|
|
|
|
you have a Subversion client installed but it is not implementing the
|
|
|
|
-n option of svnversion. Time to update it.
|
2003-10-28 09:37:37 +00:00
|
|
|
|
2003-11-21 00:52:27 +00:00
|
|
|
Sourcecode:
|
2003-09-29 09:58:27 +00:00
|
|
|
|
2003-11-21 00:52:27 +00:00
|
|
|
You can get it here:
|
2003-10-28 09:37:37 +00:00
|
|
|
|
2003-11-21 00:52:27 +00:00
|
|
|
http://www.wesnoth.org/downloads
|
2003-09-29 09:58:27 +00:00
|
|
|
|
|
|
|
|
2003-11-21 00:52:27 +00:00
|
|
|
Compiling:
|
2003-09-29 09:58:27 +00:00
|
|
|
|
2003-11-21 00:52:27 +00:00
|
|
|
First untar the package:
|
2006-06-06 00:05:03 +00:00
|
|
|
|
2007-04-25 14:37:52 +00:00
|
|
|
$ tar xfjv wesnoth-x.y.z.tar.bz2
|
2003-09-29 09:58:27 +00:00
|
|
|
|
2003-11-21 00:52:27 +00:00
|
|
|
then
|
2006-06-06 00:05:03 +00:00
|
|
|
|
2006-06-05 13:37:46 +00:00
|
|
|
$ cd wesnoth-x.y.z
|
2003-10-28 09:37:37 +00:00
|
|
|
|
2008-04-08 12:18:18 +00:00
|
|
|
Simply type 'scons' in the top-level directory to build the game and
|
|
|
|
editor. It is possible to select individual targets by naming them as
|
|
|
|
scons arguments, including wesnothd (the Wesnoth multiplayer server)
|
2008-03-28 13:49:18 +00:00
|
|
|
and campaignd (the campaign server).
|
2006-06-06 00:05:03 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
scons takes a prefix= argument that says where to install the game
|
|
|
|
and its data. The prefix defaults to /usr/local; for production builds
|
|
|
|
you may want to set prefix=/usr.
|
2003-12-23 20:16:21 +00:00
|
|
|
|
2008-03-28 15:18:17 +00:00
|
|
|
The target 'all' is equivalent to 'wesnoth wesnoth_editor cutter
|
2008-04-08 12:18:18 +00:00
|
|
|
exploder wesnothd campaignd'.
|
2008-03-28 15:18:17 +00:00
|
|
|
|
2008-04-08 12:18:18 +00:00
|
|
|
So, for example, this builds game, editor, and campaign server,
|
2008-03-28 15:18:17 +00:00
|
|
|
enabling debugging on all:
|
|
|
|
|
2008-04-08 12:18:18 +00:00
|
|
|
scons debug=yes wesnoth wesnoth_editor campaignd
|
2008-03-28 15:18:17 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
To build wesnothd:
|
2007-04-23 19:23:22 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
scons server_uid=<user> server_group=<group> wesnothd
|
2005-03-21 12:54:06 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
where <user> and <group> are valid on your system. A wesnothd
|
|
|
|
subdirectory will be created under /var/run owned by
|
|
|
|
<user>:<group>. This is relevant if you want to be able to communicate
|
|
|
|
with wesnothd through a FIFO or named socket. You have to run
|
|
|
|
wesnothd with the user specified while configuring in order for it to
|
|
|
|
work. You can also specify the FIFO directory directly by using
|
|
|
|
fifodir=<directory>.
|
2003-09-29 09:58:27 +00:00
|
|
|
|
2006-06-05 13:37:46 +00:00
|
|
|
If you want to install several versions of wesnoth you should use the
|
2008-03-28 13:49:18 +00:00
|
|
|
prefsdir= parameter to get distinct preferences directories. The
|
|
|
|
default is '.wesnoth'.
|
|
|
|
|
2008-04-08 12:18:18 +00:00
|
|
|
Installation productions 'install', 'install-wesnoth_editor',
|
|
|
|
'install-wesnothd' and 'install-campaignd' are available.
|
|
|
|
|
|
|
|
A plain 'install' installs all binary executables that exist -- so
|
|
|
|
'scons install' after a plain 'scons' installs game and editor, but
|
|
|
|
after 'scons all' it will install all binaries.
|
2008-03-28 15:18:17 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
Notes on the deprecated autotools build:
|
2006-06-05 13:37:46 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
The autotools build machinery is deprecated, unsupported, and will be
|
|
|
|
removed in a future release. You will need autoconf (>= 2.60) and
|
|
|
|
automake (>= 1.9). Run './autogen.sh' to generate the configure
|
|
|
|
files. Then
|
2007-10-23 02:39:56 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
$ ./configure
|
|
|
|
$ make
|
|
|
|
$ make install
|
2003-09-18 16:32:07 +00:00
|
|
|
|
2008-03-28 13:49:18 +00:00
|
|
|
as usual. See './configure --help' for all available options.
|
2005-03-21 20:35:20 +00:00
|
|
|
You should clean your existing wesnoth release build first with:
|
|
|
|
|
|
|
|
$ make distclean
|
|
|
|
|
2006-06-05 13:37:46 +00:00
|
|
|
If you want to clean your wesnoth SVN build do:
|
2005-03-21 20:35:20 +00:00
|
|
|
|
|
|
|
$ make maintainer-clean
|
2004-03-15 18:35:59 +00:00
|
|
|
|