This page should mention everything you need to know to run Freeciv on a Windows system. Please let Todd Goodman know if something is unclear or wrong.
Note: If you are looking for the simplest way to run Freeciv on Windows,
please look here.
latest modification: September 03, 2002
There are a number of choices when one wants to run Freeciv on Windows. As with most things in life, more choices leads to potential confusion.
If you want the most straightforward method then I recommend that you use Andreas Kemnade's native port. If you don't understand what a port or native port is, don't worry about it, just download from the link above. The next question gives more information on how to retrieve and set it up.
The steps to take to download, unpack, and run the native Windows Freeciv are:
The file with sound support is available here (4,002 Kbytes). Save it in a directory and remember where that is (for example, C:\WINDOWS)
The file without sound support is available here (2,993 Kbytes). Save it in a directory and remember where that is (for example, C:\WINDOWS)
That's it! You've downloaded and unzipped Freeciv for Windows!
The following steps are one way of running it (there are others, but I find this way easy):
That's it! Enjoy!
You save the game by clicking the Save Game button at the bottom right of the client window.
To load the saved game, click the Load Game button in step three or four above. (The name you saved under will have a .gz added to the end of it when you look in the file list.)
The first thing to do is to download the tileset you want to use from http://www.freeciv.org/download.phtml#tilesets. Ensure that you download the *-png.tar.gz version (you'll have to go to the dir link for the tileset you're intersted in to locate the *-png.tar.gz file.)
Then you have to unpack the tileset into the DATA directory in your Freeciv directory (so if your Freeciv directory is C:\FREECIV-1.13.0, then you'd tell WinZip to extract to C:\FREECIV-1.13.0\DATA.) Make sure you tell your extraction program to extract into the subdirectories in the file.
Once that's done you can start using the new tileset (FINALLY!) You have to pass an argument to CIVCLIENT.EXE so the easiest way to do that is to open a Command Prompt (from Start->Programs->Accessories->Command Prompt in my case, sometimes called an MS-DOS Window). Change to the Freeciv directory (for example, CD \FREECIV-1.13.0) and start the client with the -tiles tilesetname option. For example, CIVCLIENT -tiles ft.
You should be good to go then!
The graphic format used by Freeciv on UNIX systems (.xpm) differs from that used on Windows systems (.png.)
The *.tar.gz tileset files contain the .xpm files and the *-png.tar.gz tileset files contain the .png files.
If you're running the Windows client use the *-png.tar.gz file.
First of all, if there's a tileset on www.freeciv.org and there's not a tilesetname-png.tar.gz please bring it to the attention of the webmasters.
Next, you'll have to convert all the .xpm files in the tileset directory you installed to .png files. If you don't already have a utility to do this, I have used and can recommend ImageMagick which can be downloaded from http://www.imagemagick.org.
Once ImageMagick is downloaded and installed, go to the tileset directory (C:\FREECIV-1.13.0\DATA\FT for example if you installed the ft tileset here.)
Next, you have to run the CONVERT.EXE program from where you installed ImageMagick (in my case it's in C:\PROGRA~1\ImageMagick-5.4.8-Q16) to convert each .xpm to a .png.
For example, I ran the following commands:
C:\PROGRA~1\ImageMagick-5.4.8-Q16\CONVERT chiefs.xpm chiefs.png
C:\PROGRA~1\ImageMagick-5.4.8-Q16\CONVERT cities.xpm cities.png
(and so on for the rest of the files with .xpm extensions.)
A different ruleset can be used by downloading the ruleset and extracting it in the Freeciv data directory (C:\FREECIV-1.13.0\DATA, for example). This should create a subdirectory with the ruleset name (ancients, for example.)
Currently (due to an issue in the Freeciv code), you need to create a regular file in the SHARE directory (C:\FREECIV-1.13.0\SHARE for example) with the same name as the ruleset directory (ancients, for example.) You can create this with NOTEPAD.EXE (or any other editor, or even COPY CON: ANCIENTS followed by a ^Z.) The contents of the file doesn't matter.
Then you need to tell the server to use it. This is done by typing /rulesetdir ruleset directory in the chat line of the client before pressing the Start Game button.
Andreas Kemnade
posted the following method that he uses to do this on a LINUX system:
for name in *.xpm ; do convert $name $(echo $name | sed 's|xpm$|png|') ; done ;
and then I tried
file *.png
and looked for files which do not show up as RGBA.
I have opened the ones, which are not converted correctly, with gimp and saved
+them as pngs. Then again file *.png.
And finally
for name in *.png ; do mv $name $name.bak ; pngquant 256 <$name.bak >$name ;
+done
And a final look at them (with freeciv). Cleanup:
rm *.xpm
rm *.bak
Then I have created the tarball.
Andreas Kemnade has patched Freeciv to build with the Cygnus compilers (with -mno-cygwin which produces an executable that uses Microsofts runtime instead of Cygwin's runtime) and use native windows for display (no need for an X server!).
He has two different .ZIP files available (one with sound support and one without).
The .ZIP with sound support is available at freeciv-1.13.0-win32-sdlsound.zip (4,002 Kbytes).
The .ZIP without sound support is available at freeciv-1.13.0-win32.zip (3096576 bytes).
His patch to build the 1.12.0 version is available at freeciv-1.12.0-gtk-win-1.diff.gz (< 38248 bytes).
Also see http://www.informatik.uni-bremen.de/~akemnade/civhome.html, and his latest message dated March, 21.
Freeciv was written for Unix and the X window system. It is, in fact, extremely portable across Unix versions. One option is to install a Unix variant on your PC (such as Linux) and use that.
However, it also runs on other platforms, such as Amiga and OS/2, and there are several ways to make the game run on MS Windows 95/98/NT:
For a list of supported Freeciv platforms, see the requirements and download pages.
Before you complain to us about how this stupid game won't just install and run the way you're used to, please bear in mind that we have been seeing a strong correlation between use of abusive or indecent language in complaints, and use of the MS Windows platform. Try to be the exception. You're drawing attention from a crowd of volunteers, and most of us aren't much interested in the MS Windows platform to begin with.
This isn't to say that you should be afraid to contact Todd Goodman or the packager if you're having a problem installing or playing with a Windows version of the game. If you're polite then you'll get a polite answer back. Remember that you're not talking to some large commercial company. We're all gamers that are volunteering our help.
In Todd's opinion, the easiest and best way to play Freeciv on Windows is with Andreas Kemnade's .ZIP package.
Instructions for installing this are provided below.
Here is a .ZIP file package of Freeciv 1.12.0 optimized for the i586 freeciv-windows-1.12.0-i586.zip (3139673 bytes). And here is a .ZIP file package of Freeciv 1.12.0 optimized for the i686 freeciv-windows-1.12.0-i686.zip (3139021 bytes).
Anders has written a HOWTO to help you set up Freeciv to run under Windows with Cygwin and an X-Server. A text version of the howto is available in each of the packages above and also here.
An HTML version of this howto is available here.
The packages were built using Cygwin http://sourceware.cygnus.com/cygwin to provide a POSIX layer for Windows and to enable the use of GCC as the compiler.
The freeciv source used to build this was direct from CVS. However, it is also available here to comply with the GPL. ( csrc-*.tar.bz2 as a bzip2 tar file.
You can get the source to the Cygwin DLL (cygwin1.dll) that is being distributed as cygwin-src-*.tar.bz2.
However, it is strongly recommend that you get source directly from Cygnus! This source is included to comply with the GPL. No support will be provided for building it.
Please note that this version of the Freeciv client requires an X Server. Please see below for a discussion of possible X Servers. The HOWTO describes how to download the Cygwin X-Server.
Send email with questions/comments/criticisms regarding this version to Todd Goodman.
Most operating systems provide an API (Applications Programming Interface) that provides a mechanism for a program to display graphics.
On UNIX systems this is typically done via the X Window System. With this system client programs make requests to an X Server (possibly on a different physical machine) that handles conversion of the graphics primitives into instructions to the graphics hardware (or device drivers).
On Windows systems this can be done via the native Windows API. There are also X Servers that have been written/ported to Windows.
Freeciv was initially written for UNIX systems and uses X Window system primitives (via either the XAW or GTK Toolkits) to display the graphics.
The package provided by Anders Bruun Olsen is a straightforward port of the UNIX code to Windows. He didn't have to change anything in the source code because he used Cygwin to provide the POSIX layer (system calls used by the code) and X Libraries to provide the graphical display.
Because of this, that package requires an X Server to run.
Andreas Kemnade has made a patch (against 1.12.0 sources) to allow the use of a GTK that has been built to display using the native Windows API. This does not require an X Server.
Todd has been looking into this option, but is not able to build everything using the freely available compilers (from Cygnus) at this time (though Andreas reports that he is using all freely available compilers for his build).
Todd Goodman uses a commercial X Server package called Exceed from Hummingbird. Information is available here .
Jiri Zelinka reports that a trial version of the Netmanage server is available from Netmanage at ul8win95.zip. He said that a form may be filled out for the serial number and key code at this page but that he didn't need it.
Starnet is another server that is known to work and provides a demo version of the server (it runs for two hours at a time and then must be restarted).
WinaXe is another commercial server. In email from the company they mentioned that they changed the name from X-WinPro.
MI/X, a free server (or possibly low cost) is known not to work. It implements an outdated version of X (X11R5) and fails with this message:
X Error: BadLength Request Major code 72 () Error Serial #131 Current Serial #134
Two lists of X servers for MS Windows:
VNC server for UNIX (which provides an X API) has been ported to Cygwin. With this method you would run the X VNC Server and the Windows VNC client.
Todd has done this but has experienced problems running it (hangs of the server).
The Cygwin Xfree group is working on a port of XFree86 to Cygwin/Windows. The versions they currently have are reported to be of pretty good quality.
If you're getting a "cannot open display :0" then it means the client cannot talk to the X Server running on your machine or the Server is not letting it display on the default display.
First make sure that the X Server is really running. Then make sure the server creates Display (or Screen) number 0. The batch files that are run from the Freeciv program group have a line in them that says 'SET DISPLAY=:0'. This line tells the client to connect to the X Display number 0 on the local machine. If your X Server provides a different display number (for example, 1) then you'll need to change that line in the client batch files.
If you get a "Your getpwuid() call failed, please report" then you can safely ignore the message. Under Cygwin this routine does not do anything and returns failure. It's not really needed under Windows.
You can ignore any messages like "1: Could not open path/.civclientrc".