This is a rough attempt at a HOW-TO for setting up OpenUT with a G400/200/Voodoo 3/5/Banshee/ATI Rage 128/Intel i810 or basically any other 3D accelerator that is supported by the XFree86 4.0 DRI developed by Precision Insight. NVIDIA/Glide support for Voodoo 1/2 is beyond the scope of this document. Voodoo 1/2 owners should refer to the literature included with the Linux UT distribution archives. NVIDIA users should refer to NVIDIA's web sitefor Linux drivers. The author assumes that the reader possesses some prior Linux experience such as using CVS, archivers (such as tar and gzip), and compiling programs from source code.
Every effort has been made to insure that the information contained within this document is accurate as of the time of writing. I cannot be held responsible for any damage, lost time, lost wages, etc. that may arise by using the information contained within this page.
There is a general troubleshooting Q & A at the end of this document.
Some or much of the information contained within this document may contradict the instructions provided by Precision Insight. This document attempts to streamline the installation of XFree86 4.0.1 and the DRI with many different video card configurations. There is more than one way to go about this procedure. If you encounter difficulty in installing XFree86 4.0.1/DRI with these procedures, please try the procedures provided by Precision Insight before reporting problems to the DRI mailing lists. A complete system backup is recommended before undertaking this procedure!
Please keep in mind that the DRI is still in its infancy - it will take some time for the "smoke" to clear.
(NOTE: The DRI contains no support for OpenGL acceleration for Voodoo 1/2 series 3D accelerators. However, Voodoo 1/2 support is still available in XFree86 4.0.x through the use of Glide. Upgrading to XFree86 4.0.1/DRI will not affect Glide or dependent software on Voodoo 1/2 hardware. OpenUT will continue to function with Glide on Voodoo 1/2 even after an installation of XFree86 4.0.x/DRI. Glide under Voodoo 3/4/5 Banshee will not function after an installation of XFree86 4.0.x/DRI).
(NOTE: Utah-GLX/Mesa3D will no longer function in XFree86 4.0.x. The efforts of the Mesa3D and Utah-GLX projects have been/are being incorporated into the DRI.)
Late breaking news:
Matrox: Matrox has made public a partial-source and binary release of the MGA server based on work from the XFree86 Project and Precision Insight. This server provides access to advanced capabilities of Matrox G-Series hardware such as dual-head and television output through a closed-source module. The DRI does not currently support accelerated OpenGL across multiple heads. While the Matrox provided server will provide acceleration when used in a single-head environment, it is the author's opinion (and experience) that the MGA server from CVS will provide for a more stable and functional X setup.
The Matrox provided server is not "in-sync" with the release of XFree86 4.0.1 or the version currently in CVS. The XF86 snapshot which was used in the production of this module is unknown. You are likely to encouter difficulties using hardware accelerated OpenGL through the DRI when using the Matrox provided server.
Multitexturing is now enabled on the G400.
3dfx: Current versions of the DRI do not allow for the use of multiple VSA-100 chips simultaneously on Voodoo 4/5 hardware. This issue should be addressed in a future release of XF86/DRI.
Intel: The i810 DRM will now build in current CVS
versions of XF86/DRI.
(It is recommended to familiarize yourself with the OpenUT project and browse the mailing lists. This is the best source of information on the OpenUT project.)
The XFree86 Project: http://www.xfree86.org
The Direct Rendering Infrastructure (DRI) project: http://dri.sourceforge.net
Precision Insight (developers of the DRI): http://www.precisioninsight.com
The Linux Documentation Project: http://www.kernel.org/LDP
Compiling a kernel is beyond the scope of this document. Furthermore, using a development kernel is advised against due to the instability of development code.
You will also need XFree86 4.0.x. Prior versions do not utilize the DRI (nor do third party X servers such as Accelerated X, etc.).
XFree86 4.0.1: http://www.xfree86.org. (NOTE: It is not necessary to install XFree86 4.0.1 as we will be using the DRI CVS snapshot which includes most of the functionality offered with XFree86 4.0.1. However, it has been my experience that starting with an XFree86 4.0.1 installation will lead to a more complete upgrade to the new version of X. The DRI CVS snapshot seems to take a minimalist approach to the inclusion of all features of XFree86 4.0.1.)
XDelta patch system: http://www.XCF.Berkeley.EDU/~jmacd/xdelta.html
SDL version >1.1.1 http://www.devolution.com/~slouken/SDL/
SDL mixer library: http://www.devolution.com/~slouken/SDL/projects/SDL_mixer
Libmikmod: http://mikmod.darkorb.net
UT Linux distribution archives version 400 and the 402B patch (413 patch will notwork): http://www.unrealtournament.com
For 3Dfx Voodoo 3/5/Banshee users ONLY: Glide3 library and headers: http://dri.sourceforge.net/resources/resources.html
XFree86 4.0.1/DRI configuration files: http://dri.sourceforge.net/resources/resources.html
The UT Windows CD.
(IMPORTANT: DO NOT select "Direct Rendering Manager" or any of the supported chipsets. The DRM code in even the latest kernel is outdated.)
Reboot with your new kernel and install any other modules that you may require such as sound card drivers, lm_sensors, etc. Please make sure you are not in X for the following steps.
cd /usr/include
tar xzvf /{path to Glide 3 Headers archive}/glide3headers.tar.gz
cd /usr/lib
cp /{path to Glide 3 library}/libglide3x.so .
cd /usr
mkdir X11R6.orig
cd X11R6.orig
cp -rdp ../X11R6/* .
(NOTE: The following commands are suitable for Debian, Slackware, and other distributions that place the X configuration files in /etc/X11. If you have Red Hat or SuSE user, please disregard the following steps.)
cd /etc
mkdir X11.orig
cd X11.orig
cp -rdp ../X11/* .
Change to your source directory (usually /usr/src/) and create the DRI-CVS directory by executing the following commands:
cd /usr/src
mkdir DRI-CVS
cd DRI-CVS
(When asked for a password, simply hit "return")
cvs -d:pserver:anonymous@cvs.dri.sourceforge.net:/cvsroot/dri
login
cvs -z3 -d:pserver:anonymous@cvs.dri.sourceforge.net:/cvsroot/dri co xc
cd /usr/src
tar xzvf /{path to xfree86 archives}/X401src-1.tgz
tar xzvf /{path to xfree86 archives}/X401src-2.tgz
tar xzvf /{path to xfree86 archives}/X401src-3.tgz
The resulting XFree86 4.0.1 distribution will be placed in /usr/src/xc.
Change to the /usr/src/xc directory and build XFree86 4.0.1 by executing the following commands:
cd /usr/src/xc
make World
(This will take a long time. Please be patient.)
make install
ldconfig
(Please DO NOT try to start X at this time. It won't work. Continue on through the following steps:)
cd /usr/src/DRI-CVS/xc/xc/config/cf
Edit the host.def file (ie. emacs/vi host.def) and make sure the following lines exist and are uncommented:
#define XF86CardDrivers vga mga i810 tdfx r128
#define BuildXF86DRI
YES
#define HasGlide3 YES (For 3Dfx hardware only)
#define BuildXF86DRM YES
Saved the changes and execute the following commands:
cd /usr/src/DRI-CVS/xc/xc
make World; make install; ldconfig
cd nls
xmkmf -a
make; make install; ldconfig
cd /usr/src/DRI-CVS/xc/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel
cp *.o /lib/modules/{kernel version}/misc
depmod -a
cd /var/X11R6/bin
ln -s /usr/X11R6/bin/XFree86 X
Copy the XF86Config file you downloaded from dri.sourceforge.net/resources/resources.htmlto /usr/X11/XF86Config. Make sure there is no suffix at the end of the filename.
Edit /usr/X11/XF86Config to suit your needs (screen resolutions, color depths, mouse, etc.) and save the changes. The default configuration files should work well with most systems.
Reboot the system and fire up X with the following command to test your configuration(usually with startx).
(If the configuration is not working as expected please see the Troubleshooting Q&A at the end of this document.)
Untar, compile and install XDelta according to the included README file. It should compile with the usual:
./configure; make; make install; ldconfig
Mount your CD-ROM to /mnt/cdrom.(This is essential, as there is a bug in the installer. /cdrom mountpoint or any other mountpoint will fail.)
Run the installer directly. (DO NOT run the install script as it also contains a bug.)
Unselect 3Dfx support in the installer and Click "Install".
Untar the UT linux 400B patch into the UT home directory created by the installer (/usr/local/games/UnrealTournament/).
Change to the directory containing the patch and follow the directions in the included README file for patching UT with XDelta.
Change to your source directory (usually /usr/src/) and execute the following commands:
(When asked for a password, simply hit "return")
cvs -d:pserver:anonymous@cvs.OpenUT.sourceforge.net:/cvsroot/OpenUT
login
cvs -z3 -d:pserver:anonymous@cvs.OpenUT.sourceforge.net:/cvsroot/OpenUT co
OpenUT
View the included READMEs. Copy the appropriate directories from the UT linux directory as outlined in the README.
Build SDL with the following commands:
./configure; make; make install; ldconfig
Build SDL mixer and libmikmod in the usual manner:
./configure; make; make install; ldconfig
make
Change to your OpenUT/System directory (usually /usr/src/OpenUT/System) and execute the following command:
./UnrealTornament.
If all went well, you'll be playing UT under linux!
A) Delete the entire /usr/X11R6 directory structure and restore your backup by executing the following commands:
cd
/usr
rm -r X11R6
mv X11R6.orig X11R6
rm /lib/modules/{kernel version}/misc/{DRM modules}
(If your distribution places X configuration files in /etc/X11, carry out the following steps:)
cd
/etc
rm -r X11
mv X11.orig X11
(Otherwise, simple remove the /etc/X11 directory:)
cd /etc
rm -r
X11
cd /var/X11R6/bin
ln -s /usr/X11R6/bin/XF86_SVGA X
{NOTE: If you are using a special accelerated X server S3, SIS, etc.,
the symbolic link "X" points to should reflect the location of the
accelerated server instead of XF86_SVGA}
Q) X will not start, my mouse does not work, or my monitor goes into "power save" mode.
A) There are many possibilities, most of which revolve around a misconfigured XF86Config. Please review /etc/X11/XF86Config and make sure that all setting are correct.
Q) X starts, but my window manager or Gnome/KDE/GDM/XDM will not.
A) Some or all of your X init scripts were probably overwritten. Try typing "startx gnome", "startx kde", etc to start with your normal configuration. You may need to hunt down the init scripts and edit them manually.
Q) My mouse is too sensitive in UT after upgrading to XFree86 4.0.1/DRI (it works fine in Quake III though).
A) Edit UnrealTournament.ini and set DGAMOUSE=FALSE in either the XDrv or SDLDrv section of the configuration file.
Q) When launching UT, I see the intro through a narrow "band" in the middle of the screen. Switching to a window does not fix the problem.
A) Launch UT with -defaultres on the command line. You should only need to do this once.
Q) I see the splash screen and the game terminates immediately afterward with no error message on my console.
A) Try -nosplash -nosoundon the command line. Try running as root.
Q) How come there is no music?
A) Edit OpenUT/System/UnrealTournament.ini and change UseDigitalMusic=FALSE to UseDigialMusic=TRUE (section Audio.GenericAudioSubsystem).