3.2. Install XFree86
Installation of the software packages requires root login, which can be obtained easily via the superuser/setuser command: su - (see, man su).
The following explains the installation of XFree86 from source in only the most basic terms. Make sure to read all the XFree86 documentation to learn about special options.
If you have a version of XFree86 installed already, you may want to move it or delete it. However, installing over an existing X is generally OK and preserves any programs or libraries you might have installed into the X directories (not that you should really do that):
cd /usr mv X11R6 X11R6-old cd /etc mv X11 X11-old # you may have an X directory in /var also cd /var mv X11R6 X11R6-old |
If these locations are not correct for your distribution of Linux, you will have to look around your filesystem a bit - try looking in /var
cd /usr/src mkdir release cd release tar -xvzf X420src-1.tgz tar -xvzf X420src-2.tgz tar -xvzf X420src-3.tgz tar -xvzf doctools-1.3.tar.gz |
If you are using an old version of XFree86 for some reason, you may want to use the man page packages. XFree 4.2.0 and later has all these man pages already. Skip using the man page packages if you don't need them. Check in /usr/src/release/xc/doc/man to see what all is included with your XFree86.
# unpack the man pages if they are missing. cd /usr/src tar -xvzf mangl.tar.Z tar -xvzf manglu.tar.Z |
A file has to be edited to allow these man pages to compile/install with the rest of the distribution:
cd /usr/src/release/xc/doc/man/GL # Edit the file: Imakefile # SUBDIRS = glx gl glu |
When you unpacked the man*.tar.Z files above, two new directories where added: gl glu
cd /usr/src/release cd doctools # Having this variable set confuses the sgml docs build. # With it unset, the build uses the proper defaults. unset $SGML_CATALOG_FILES make make install # Note: doctools installs the perl program sgmlfmt to # /usr/local/bin. It looks for the perl executable # at /usr/local/bin/perl. If perl is installed # on your system at /usr/bin/perl, then it will not # find perl and the sgml docs build will fail! # Make a symlink if needed (or edit the script): cd /usr/local/bin ln -s /usr/bin/perl perl cd /usr/src/release cd xc/config/cf vi host.def # add the following three lines to host.def: # #define HasSgmlFmt YES # #define BuildAllDocs YES # #define HasZlib YES # See the README file in doctools and xc/config/cf. # HasZlib YES instructs XFree86 not to build and install # it's own old zlib. If you do not have zlib installed # (check /usr/lib/libz*), then omit the HasZlib line or # go download it and install it first: # http://www.info-zip.org/pub/infozip/zlib/ # A common zlib conflict occurs when a system already # has zlib installed and XFree86 installs it's also. # In this case, deleting /usr/X11R6/lib/libz.a fixes # the problem. cd /usr/src/release/xc make World # before installing, make sure you have moved # or deleted prior installation of X # unless you are sure you want to just overwrite make install make install.man # make symlinks cd /usr/include ln -s ../X11R6/include/DPS DPS ln -s ../X11R6/include/GL GL ln -s ../X11R6/include/X11 X11 ln -s ../X11R6/include/bitmaps bitmaps cd .. ln -s X11R6 X11 |
Add /usr/X11R6/lib to your /etc/ld.so.conf file, then run the command ldconfig to update /etc/ld.so.cache so the libraries will be visible.
The GL/GLX/GLU HTML documentation is located at /usr/src/release/xc/doc/hardcopy/GL. This directory can be copied as follows:
cd /usr/src/release/xc/doc/hardcopy cp -r GL /usr/X11R6/lib/X11/doc/html |
cd /usr/X11R6/lib/X11/doc/html ln -s manindex5.html manindex5x.html |
When X is up and running (later), try using the xman program to see that the gl,glx,glu and glut man pages are in section 3. If you have KDE2, khelpcenter allows man-page browsing.