# Chapter 9. The X Window System

#### Contents:

Installing X11
Running XDarwin
Desktops and Window Managers
X11-based Applications and Libraries
Making X11 Applications More Aqua-like
AquaTerm
Connecting to Other X Window Systems
Virtual Network Computers
Conclusion

Although the X in "Mac OS X" is not the same X as in "The X Window System," you can get them to play nice together.

Most Unix systems use the X Window System as their GUI. (We'll refer to the X Window System as X11, to avoid confusion with Mac OS X.) X11 includes development tools and libraries for creating graphical applications for Unix-based systems. Mac OS X does not use X11 as its GUI, relying instead on Quartz (and, on compatible hardware, Quartz Extreme), a completely different graphics system. However, an implementation of X11 for Mac OS X is available from the XFree86 Project (http://www.xfree86.org/). The XDarwin project (http://www.xdarwin.org/) provides an easy-to-install binary distribution of XFree86.

## 9.1. Installing X11

The XFree86 site contains instructions for downloading and installing the X11R6 binaries on a Mac OS X system. The site also provides instructions for compiling the X11R6 suite from source. The easiest way to get X11 for Mac OS X is through either XDarwin or Fink, both of which contain easy-to-install binary distributions of X11. Fink also includes the system-xfree86 package, which is a placeholder package that lets you use the X11 distribution of your choice with Fink. (The placeholder package satisfies the same dependencies as the Fink X11 package.)

### 9.1.1. Manually Installing X11

If you want to install the XFree86 distribution manually, download the distribution (see the instructions on the XFree86 web site) and run the Xinstall.sh script to install the XFree86 suite.

This script will prompt you for some configuration details, although it includes defaults that should work for most Mac OS X users. The XFree86 web site has an extensive set of instructions explaining how to install XFree86 for the first time, how to install the suite over an older XFree86 installation, and how to uninstall XFree86. There are specific instructions for Mac OS X and Darwin.

The installer script will install the X11 binaries, libraries, header files, manpages, configuration files, etc., in /usr/X11R6 and /etc/X11.

There is very little difference between manually installing XFree86 on Mac OS X and manually installing it on other Unix systems. The main difference is that some files required on other Unix systems are not required on Darwin. For example, there is no separate Xvar.tgz file to download. Another difference with Mac OS X is that the double-clickable XDarwin application is placed in the /Applications folder.

Copyright © 2003 O'Reilly & Associates. All rights reserved.