README for XFree86 on FreeBSD : Building X Clients
Previous: Rebuilding Kernels for X
Next: Thanks

7. Building X Clients

The easiest way to build a new client (X application) is to use xmkmf if an Imakefile is included with it. Type ``xmkmf -a'' to create the Makefiles, then type ``make''. Whenever you install additional man pages you should update whatis.db by running ``makewhatis /usr/X11R6/man''.

Note: Starting with XFree86 2.1 and FreeBSD 1.1, the symbol __386BSD__ no longer gets defined either by the compiler or via the X config files for FreeBSD systems. When porting clients to BSD systems, make use of the symbol BSD for code which is truly BSD-specific. The value of the symbol can be used to distinguish different BSD releases. For example, code specific to the Net-2 and later releases can use:

#if (BSD >= 199103)

To ensure that this symbol is correctly defined, include <sys/param.h> in the source that requires it. Note that the symbol CSRG_BASED is defined for *BSD systems in XFree86 3.1.1 and later. This should be used to protect the inclusion of <sys/param.h>.

For code that really is specific to a particular i386 BSD port, use __FreeBSD__ for FreeBSD, __NetBSD__ for NetBSD, __OpenBSD__ for OpenBSD, __386BSD__ for 386BSD, and __bsdi__ for BSD/386.


README for XFree86 on FreeBSD : Building X Clients
Previous: Rebuilding Kernels for X
Next: Thanks