XEmacs 21.4.9 "Informed Management".
[chise/xemacs-chise.git.1] / INSTALL
1 XEmacs Installation Guide
2 Copyright (c) 1994, 1995, 1996 Board of Trustees, University of Illinois
3 Copyright (c) 1994-1999 Free Software Foundation, Inc.
4
5    Permission is granted to anyone to make or distribute verbatim copies
6    of this document as received, in any medium, provided that the
7    copyright notice and permission notice are preserved,
8    and that the distributor grants the recipient permission
9    for further redistribution as permitted by this notice.
10
11    Permission is granted to distribute modified versions
12    of this document, or of portions of it,
13    under the above conditions, provided also that they
14    carry prominent notices stating who last changed them,
15    and that any new or changed statements about the activities
16    of the Free Software Foundation are approved by the Foundation.
17
18
19 BUILDING AND INSTALLATION FOR UNIX AND CYGWIN
20
21 (for Microsoft Windows, see nt/README also.)
22
23 PREREQUISITES
24 =============
25
26 Make sure your system has enough swapping space allocated to handle a
27 program whose pure code is 900k bytes and whose data area is at least
28 400k and can reach 8Mb or more. Note that a typical XEmacs build is
29 much bigger. If the swapping space is insufficient, you will get an
30 error in the command `temacs -batch -l loadup dump', found in
31 `./src/Makefile.in.in', or possibly when running the final dumped
32 XEmacs.
33
34 Verify that your users have a high enough stack limit. On some systems
35 such as OpenBSD and OSF/Tru64 the default is 2MB which is too low. See
36 'PROBLEMS' for details.
37
38 Building XEmacs requires about 100 Mb of disk space (including the
39 XEmacs sources).  Once installed, XEmacs occupies between 20 and 100 Mb
40 in the file system where it is installed; this includes the executable files,
41 Lisp libraries, miscellaneous data files, and on-line documentation. The
42 exact amount depends greatly on the number of extra lisp packages that are
43 installed 
44
45 XEmacs requires an ANSI C compiler, such as GCC.  If you wish to build
46 the documentation yourself, you will need at least version 1.68 of
47 makeinfo (GNU texinfo-3.11).
48
49 ADD-ON LIBRARIES
50 ================
51
52 Decide on what other software packages you would like to use with
53 XEmacs, but are not yet available on your system.  On some systems,
54 Motif and CDE are optional additions.  On Solaris, the SUNWaudmo
55 package enables native sound support.  There are also a number of free
56 software packages that XEmacs can use.  If these are not yet available
57 on your system, obtain, build and install those external packages
58 before building XEmacs.  The packages XEmacs can use are:
59
60    Xaw3d, XPM, JPEG, compface, PNG, zlib, GNU DBM, Berkeley DB, socks,
61    term, NAS, Canna, Kinput2, SJ3, Wnn.
62
63 You can get (most of) them from the XEmacs ftp site at
64 ftp://ftp.xemacs.org/pub/xemacs/aux
65
66 If you want users on other systems to be able to use the XEmacs you
67 have built, try to build those packages so that the generated
68 libraries are statically linked.
69
70 Use the --site-includes and --site-libraries options when building
71 XEmacs to allow configure to find the external software packages.
72 If you link with dynamic (``.so'') external package libraries, which
73 is not recommended, you will also need to add the library directories
74 to the --site-runtime-libraries option. For your convenience these can
75 be set together by using the --with-site-prefix command. This will set
76 these variables as needed assuming your libraries are organised as a
77 typical /usr tree.
78
79 PACKAGE SYSTEM
80 ==============
81
82 The file README.packages contain information vital to have a fully
83 working XEmacs. This information was not included in this file only
84 because it is too large for this terse INSTALL.  Please read
85 README.packages now!
86
87 CONFIGURATION OPTIONS
88 =====================
89
90 In the top level directory of the XEmacs distribution, run the
91 program `configure' as follows:
92
93     ./configure [CONFIGURATION-NAME] [--OPTION[=VALUE]] ...
94
95 Almost always, you should let `configure' (actually the shell script
96 `config.guess') guess your host type, by omitting the
97 CONFIGURATION-NAME argument.  If you like to experiment, specify a
98 configuration name in the form MACHINE-VENDOR-OPSYS, for example:
99
100 sparc-sun-solaris2.6
101
102 See config.guess and configure.in for valid values for MACHINE,
103 VENDOR, and OPSYS.  Also check `./etc/MACHINES' for advice on building
104 on particular machines.
105
106 If you don't want X support, specify `--without-x'.  If you omit this
107 option, `configure' will try to autodetect whether your system has X,
108 and arrange to use it if present.
109
110 The `--x-includes=DIR' and `--x-libraries=DIR' options tell the build
111 process where the compiler should look for the include files and
112 object libraries used with the X Window System.  Normally, `configure'
113 is able to find them; these options are necessary if you have your X
114 Window System files installed in unusual places.
115
116 The `--site-includes=DIR' and `--site-libraries=DIR' options allow you
117 to specify additional places the compiler should look for include
118 files and object libraries.  You may specify multiple DIR's by
119 enclosing the list in quotes.  All the external packages you want to
120 use with XEmacs (e.g. xpm, wnn, ...) described later should have their
121 include and library directories defined using these options.
122
123 The `--site-runtime-libraries=DIR' option specifies directories to
124 search for shared libraries at run time.  This may be necessary if you
125 link with dynamic libraries that are installed in non-standard
126 directories, or if you expect some of the libraries used to build
127 XEmacs to be in a different directory at run time than at build time.
128 Usually this will add a `-R' to each directory specified and use that
129 when linking XEmacs.  If you use this option, you must specify ALL of
130 the directories containing shared libraries at run time, including
131 system directories.
132
133 Rationale: Some people think that directories in --site-libraries
134 should be automatically used to update --site-runtime-libraries.
135 Here's a real-life scenario that explains why this is not done: You
136 build binaries for your company using static libs in
137 /net/toy/hack/lib.  XEmacs adds /net/toy/hack/lib to the runpath of
138 the executable you've built.  Since there are only static libs there,
139 the system runtime loader will look in this dir, and ignore it,
140 causing only a .01 second delay in starting XEmacs.  You leave the
141 company for a job at a small Silicon Valley startup.  Time passes.
142 The next guy who inherits your machine objects to working on a machine
143 named `toy', and gets the sysadmin to rename the machine `godzilla'.
144 The SA forgets to remove the old entry for `toy' from the hosts file.
145 Now the system loader will still try to access /net/toy/, and the
146 automounter will hang trying to access /net/toy.  XEmacs suddenly
147 takes 30 seconds longer to start up, no one can figure out why, and
148 everyone at your old company curses your name, thinking that you've
149 put a time bomb into XEmacs.  And they're right!
150
151 The `--with-gcc' option specifies that the build process should
152 compile XEmacs using GCC.  The `--compiler' option allows you to
153 specify some other compiler to be used to compile XEmacs.  If neither
154 option is specified, the environment variable CC is used instead.
155 Otherwise the compiler will then default to 'cc'.
156
157 The `--cflags' option specifies the CFLAGS the build process should
158 use when compiling XEmacs.  Otherwise the value of the environment
159 variable CFLAGS is consulted.  If that is also undefined, CFLAGS
160 defaults to "-g -O" for gcc and "-g" for all other compilers.
161
162 The `--dynamic' option specifies that configure should try to link
163 emacs dynamically rather than statically.
164
165 You can build XEmacs for several different machine types from a single
166 source directory.  To do this, you must use a version of `make' that
167 supports the `VPATH' variable, such as GNU `make'.  Create separate
168 build directories for the different configuration types, and in each
169 one, run the XEmacs `configure' script.  `configure' looks for the
170 Emacs source code in the directory that `configure' is in.
171
172 The `--prefix=PREFIXDIR' option specifies where the installation process
173 should put XEmacs and its data files.  This defaults to `/usr/local'.
174 - XEmacs (and the other utilities users run) go in PREFIXDIR/bin
175   (unless the `--exec-prefix' option says otherwise).
176 - The architecture-independent files go in PREFIXDIR/lib/xemacs-VERSION
177   (where VERSION is the version number of XEmacs, like `21.0').
178 - The architecture-dependent files go in
179   PREFIXDIR/lib/xemacs-VERSION/CONFIGURATION-NAME
180   (where CONFIGURATION-NAME is the host type, like mips-dec-ultrix4.2),
181   unless the `--exec-prefix' option says otherwise.
182
183 The `--exec-prefix=EXECDIR' option allows you to specify a separate
184 portion of the directory tree for installing architecture-specific
185 files, like executables and utility programs.  If specified,
186 - XEmacs (and the other utilities users run) go in EXECDIR/bin, and
187 - The architecture-dependent files go in
188   EXECDIR/lib/xemacs-VERSION/CONFIGURATION-NAME.
189 EXECDIR/bin should be a directory that is normally in users' PATHs.
190
191 If you specify --prefix (or any of the other installation directory
192 options), they will get compiled into the xemacs executable so it will
193 be able to find its various associated file.  However, XEmacs has
194 quite elaborate logic to find out the locations of these directories
195 dynamically.  Sometimes, it is desirable *not* to compile these
196 directories into the executable so you can move the XEmacs
197 installation around (as whole) at will.  This is true for binary kits,
198 for instance.  Therefore, you can specify --without-prefix on the
199 configure command line to prevent the installation prefix to become
200 part of the generated executable; everything else will continue to
201 work as usual.
202
203 The `--with-menubars=TYPE' option allows you to specify which X
204 toolkit you wish to use for the menubar.  The valid options are
205 `lucid', `motif' and `no'.  The default is `lucid' which is a
206 Motif-lookalike menubar.  We highly recommend its usage over the real
207 Motif menubar. (In fact, the Motif menubar is currently broken.)  If
208 `no' is specified then support for menubars will not be compiled in.
209
210 The `--with-scrollbars=TYPE' option allows you to specify which X
211 toolkit you wish to use for the scrollbars.  The valid options are
212 `lucid', `motif', `athena', `athena3d', and `no'.  The default is
213 `lucid' which is a Motif-lookalike scrollbar.  If `no' is specified
214 then support for scrollbars will not be compiled in.
215
216 The `--with-dialogs=TYPE' option allows you to specify which X toolkit
217 you wish to use for the dialog boxes.  The valid options are `athena',
218 `athena3d', `motif, and `no.  The `lucid' option is accepted and will
219 result in the `athena' toolkit being used.  If the Motif toolkit can be
220 found the default is `motif'.  Otherwise, the default is `athena'.  If
221 `no' is specified then support for dialog boxes will not be compiled
222 in.
223
224 The `--with-toolbars' option allows you to enable or disable toolbar
225 support.  The default is `yes' as long as support for a windowing
226 system is included.
227
228 The `--with-xpm' option specifies that XEmacs should support X11
229 Pixmaps.  `configure' will attempt to detect if you have the Xpm
230 libraries and define `--with-xpm' for you.
231
232 The `--with-xface' option specifies that XEmacs should support
233 X-Faces.  `configure' will attempt to detect if you have the compface
234 library and define `--with-xface' for you.
235
236 The `--with-database' option specifies that XEmacs should be built
237 with additional database support.  The valid options are `no' or a
238 comma-separated list of one or more of `dbm', `gnudbm' or `berkdb'.
239 `configure' will attempt to detect the necessary libraries and header
240 files and define `--with-database' for you.
241
242 The `--with-socks' option specifies that XEmacs should be built with
243 SOCKS support.  This requires the libsocks library.
244
245 The `--with-tooltalk' option specifies that XEmacs should be built
246 with ToolTalk support for interconnecting with other applications.
247 ToolTalk is not yet supported on all architectures.  If you use this
248 option, you should have the tooltalk package (see etc/PACKAGES)
249 installed prior to building XEmacs.
250
251 The `--with-sparcworks' option specifies that XEmacs should be built
252 with support for Sun Sparcworks 3.0.1 and up (including Sun WorkShop).
253 This functionality is only of use on SunOS 4.1.x and Solaris 2.x
254 systems.  If you use this option, you should have the Sun package (see
255 etc/PACKAGES) installed prior to building XEmacs.
256
257 The `--with-cde' option allows you to enable or disable CDE drag and
258 drop support.  `configure' will attempt to detect this option and
259 define `--with-cde' for you.
260
261 The `--with-offix' option allows you to enable or disable OffiX drag
262 and drop support.  This requires no external library support, so if
263 X11 support is available, then this option defaults to `yes'.  OffiX
264 support can be explicitly disabled via the `--with-offix=no' option.
265
266 The `--external-widget' option specifies that XEmacs should be built
267 with support for being used as a widget by other X11 applications.
268 This functionality should be considered beta.
269
270 The `--without-xmu' option can be used if your vendor doesn't ship
271 the Xmu library.
272
273 The `--puresize' option can be used to change the amount of purespace
274 allocated for the dumped XEmacs.  As of XEmacs 20.1 usage of this
275 parameter is deprecated and will be ignored.
276
277 The `--with-sound=TYPE' option specifies that XEmacs should be built
278 with sound support.  Native (`--with-sound=native') sound support is
279 currently available only on Sun SparcStations, SGI's, HP9000s, and
280 systems (such as Linux) with soundcard.h.  Network Audio Support (NAS)
281 (`--with-sound=nas' or `--with-sound=both') is an extension to X that
282 you may or may not have for your system.  For NAS, you will probably
283 need to provide the paths to the nas include and library directories
284 to configure.  If `--with-sound' is not specified, `configure' will
285 attempt to determine if your configuration supports native sound and
286 define --with-sound for you.  If your native sound library is not in a
287 standard location you can specify it with the `--native-sound-lib=LIB'
288 flag.  For Linux, `/dev/audio' is required for SunAudio files and
289 `/dev/dsp' is required for raw data and WAVE format files.
290
291 The `--rel-alloc' option can be used to either enable or disable use
292 of the relocating allocator.  Turning on --rel-alloc will allow XEmacs
293 to return unused memory to the operating system, thereby reducing its
294 memory footprint.  However, it may make XEmacs runs more slowly,
295 especially if your system's `mmap' implementation is missing or
296 inefficient.  Generally, it's best to go with the default
297 configuration for your system.  You can tweak this based on how you
298 use XEmacs, and the memory and cpu resources available on your system.
299
300 The `--with-system-malloc' option can be use to either enable or
301 disable use of the system malloc.  Generally, it's best to go with the
302 default configuration for your system.  Note that on many systems
303 using the system malloc disables the use of the relocating allocator.
304
305 The `--with-debug-malloc' option can be used to link a special debugging
306 version of malloc.  Debug Malloc is not included with XEmacs, is
307 intended for use only by the developers and may be obtained from
308 <URL:http://www.letters.com/dmalloc/>.
309
310 The `--debug' and `--error-checking' options are intended for use only
311 by the developers.  `--debug' adds code to be compiled in for
312 performing various tests.  `--error-checking' adds additional tests to
313 many of the commonly used macros.
314
315 The `--verbose' and `--extra-verbose' options are intended for use
316 only by the developers.  `--verbose' causes the results of all
317 configure tests to be displayed.  `--extra-verbose' displays
318 additional information, useful for debugging.  Another help for
319 determining configure failures is the file `config.log', which
320 contains the results of the compile and link tests used by configure.
321
322 The `--with-mule' option enables (MUlti-Lingual Emacs) support, needed
323 to support non-Latin-1 (including Asian) languages.  The Mule support
324 is not yet as stable or efficient as the `Latin1' support.   Enabling
325 Mule support requires the mule-base package installed prior to
326 building XEmacs.  The following options require Mule support:
327
328 The `--with-xim' option enables use of the X11 XIM mechanism to allow
329 an input method to input text into XEmacs.  The input method is shared
330 among all the X applications sharing an X display and using the same
331 language.  The XIM support comes in two flavors: `motif' and `xlib'.
332 The Motif support (the XmIm* functions) is preferred when available.
333 The xlib XIM support works reasonably well so long as the X11 libraries
334 are recent enough.  It has been fairly well tested on Linux with glibc
335 2.0.5 and 2.0.6 and Kinput2 as an XIM server.  In this configuration
336 X11 must be recompiled with X_LOCALE defined because glibc is lacking
337 localization for Japanese.  The XIM support defaults to `no' except
338 when Motif is detected where it is stable with OSF libraries.  The XIM
339 support in Lesstif (a Free Motif replacement) does not work as of
340 v0.82.  If you enable this option, you will probably wish to install
341 the `locale' package which contains localized Splash screens and
342 Menubars.
343
344 The `--with-xfs' option enables use of a multilingual Menubar.  At the
345 present time, only Japanese and French locales are supported.  In
346 order to use a multilingual Menubar you must have the `locale' package
347 installed.  The `locale' package does not have to be installed when
348 building XEmacs.
349
350 The `--with-canna' option enables the use of the Canna Japanese input
351 method.  This is stable code and fairly well tested.  In order to use
352 it, you will have to have the Canna server installed and running.
353 Canna versions 3.2pl2 and 3.5b2 are known to work.  Version 3.2pl2 is
354 considered most stable than version 3.5b2.  If Canna is already
355 installed, configure will autodetect it, so you never need to
356 explicitly use this option unless your Canna libraries are somewhere
357 strange.  Canna run time support is currently bundled with the
358 `mule-base' package so there is nothing additional to install in order
359 to use it.
360
361 The `--with-wnn' and `--with-wnn6' options are for compiling with the Wnn
362 multi-language input method.  `--with-wnn' is for compiling with Wnn-4.2,
363 the Free version of WNN.  `--with-wnn6' is for compiling against WNN6,
364 the commercial version of WNN available from OMRON Corporation.  This is
365 stable code and fairly well tested.  In order to build with this
366 option, you will need to have the `egg-its' lisp package already
367 installed.
368
369 Please note that it is safe to build with as many of the options
370 `--with-xim', `--with-canna' and `--with-wnn' as your system
371 supports.
372
373 MAIL LOCKING
374 ============
375
376 For most platforms, configure or the src/s file have the preferred
377 method for locking mail spool files preconfigured.  Otherwise you must
378 find out for youself.  Do not choose a locking protocol "on the
379 objective merits."  XEmacs must use the same method as other mail
380 utilities on your system, or you will lose mail.
381
382 Presently, XEmacs supports lockf, flock, and dot locking.  Specify the
383 locking method via the --mail-locking=METHOD option to configure.
384 Valid values for METHOD are --mail-locking are `lockf', `flock', and
385 `dot'.
386
387 RUNNING CONFIGURE
388 =================
389
390 `configure' doesn't do any compilation or installation itself.  It
391 just creates the files that influence those things: `./src/config.h',
392 and all the Makefile's in the build tree.
393
394 When it is done, `configure' prints a description of what it did and
395 creates a shell script `config.status' which, when run, recreates the
396 same configuration.  If `configure' exits with an error after
397 disturbing the status quo, it removes `config.status'.
398
399 AUXILIARY PATHS
400 ===============
401
402 Look at `./lisp/paths.el'; if some of those values are not right for
403 your system, set up the file `./lisp/site-init.el' with XEmacs Lisp
404 code to override them; it is not a good idea to edit paths.el itself.
405 YOU MUST USE THE LISP FUNCTION `setq' TO ASSIGN VALUES, rather than
406 `defvar', as used by `./lisp/paths.el'.  For example,
407
408      (setq news-inews-program "/usr/bin/inews")
409
410 is how you would override the default value of the variable
411 news-inews-program (which is "/usr/local/inews").
412
413 Before you override a variable this way, *look at the value* that the
414 variable gets by default!  Make sure you know what kind of value the
415 variable should have.  If you don't pay attention to what you are
416 doing, you'll make a mistake.
417
418 Things may malfunction if the variable `directory-abbrev-alist' is not
419 set up to translate "temporary" automounter mount points into the
420 canonical form.  XEmacs tries to detect how your automounter is
421 configured.  If you have an unusual automounter configuration that
422 XEmacs cannot detect, you may need to change the value of
423 `directory-abbrev-alist'.
424
425 SITE-SPECIFIC STARTUP CODE
426 ==========================
427
428 Put into `./lisp/site-init.el' or `./lisp/site-load.el' any Emacs Lisp
429 code you want XEmacs to load before it is dumped out.  Use
430 site-load.el for additional libraries if you arrange for their
431 documentation strings to be in the lib-src/DOC file (see
432 src/Makefile.in.in if you wish to figure out how to do that).  For all
433 else, use site-init.el.
434
435 Note that, on some systems, the code you place in site-init.el must
436 not use expand-file-name or any other function which may look
437 something up in the system's password and user information database.
438 See `./PROBLEMS' for more details on which systems this affects.
439
440 The `site-*.el' files are nonexistent in the distribution.  You do not
441 need to create them if you have nothing to put in them.
442
443 TERMCAP CONFIGURATION
444 =====================
445
446 Refer to the file `./etc/TERMS' for information on fields you may
447 wish to add to various termcap entries.  The files `./etc/termcap.ucb'
448 and `./etc/termcap.dat' may already contain appropriately-modified
449 entries.
450
451 RUNNING MAKE
452 ============
453
454 Run `make' in the top directory of the XEmacs distribution to finish
455 building XEmacs in the standard way.  The final executable file is
456 named `src/emacs'.  You can execute this file "in place" without
457 copying it, if you wish; then it automatically uses the sibling
458 directories ../lisp, ../lib-src, ../info.
459
460 Or you can "install" the executable and the other XEmacs into their
461 installed locations, with `make install'.  By default, XEmacs's files
462 are installed in the following directories:
463
464 By default, XEmacs installs its files in the following directories:
465
466 `/usr/local/bin' holds the executable programs users normally run -
467                 `xemacs', `etags', `ctags', `b2m', `emacsclient', `ellcc',
468                 `gnuclient', `gnudoit', `gnuattach', and `rcs-checkin'.
469
470 `/usr/local/lib/xemacs-VERSION/lisp' holds the Emacs Lisp libraries;
471                 `VERSION' stands for the number of the XEmacs version
472                 you are installing, like `18.59' or `19.14'.  Since
473                 the lisp libraries change from one version of XEmacs to
474                 another, including the version number in the path
475                 allows you to have several versions of XEmacs installed
476                 at the same time; this means that you don't have to
477                 make XEmacs unavailable while installing a new version.
478
479                 XEmacs searches for its lisp files in these
480                 directories, and then in
481                 `/usr/local/lib/xemacs/site-lisp/*'.
482
483 `/usr/local/lib/xemacs-VERSION/etc' holds the XEmacs tutorial, the
484                 `yow' database, and other architecture-independent
485                 files XEmacs might need while running.  VERSION is as
486                 specified for `.../lisp'.
487
488 `/usr/local/lib/xemacs/lock' contains files indicating who is
489                 editing what, so XEmacs can detect editing clashes
490                 between users.
491
492 `/usr/local/lib/xemacs-VERSION/CONFIGURATION-NAME' contains executable
493                 programs used by XEmacs that users are not expected to
494                 run themselves, and the DOC file. `VERSION' is the
495                 number of the XEmacs version you are installing, and
496                 `CONFIGURATION-NAME' is the host type of your system.
497                 Since these files are specific to the version of
498                 XEmacs, operating system, and architecture in use,
499                 including the configuration name in the path allows
500                 you to have several versions of XEmacs for any mix of
501                 machines and operating systems installed at the same
502                 time; this is useful for sites at which different
503                 kinds of machines share the file system XEmacs is
504                 installed on.
505
506 `/usr/local/lib/xemacs-VERSION/CONFIGURATION-NAME/modules' holds the Emacs
507                 dynamically loadable modules.  These are special programs
508                 typically written in C that can be loaded in much the same
509                 way that Lisp packages are.  Not all systems support
510                 dynamic modules, so do not be alarmed if this directory
511                 does not exist or is empty.
512
513                 XEmacs searches for modules in this directory, or any
514                 sub-directory of it, and then in
515                 `/usr/local/lib/xemacs/site-modules/*'.
516
517 `/usr/local/lib/xemacs-VERSION/info' holds the on-line documentation
518                 for XEmacs, known as "info files".
519
520 `/usr/local/man/man1' holds the man pages for the programs installed
521                 in `/usr/local/bin'.
522
523 If these directories are not what you want, you can specify where to
524 install XEmacs's libraries and data files or where XEmacs should search
525 for its lisp files by giving values for `make' variables as part of
526 the command.
527
528 You can change where the build process installs XEmacs and its data
529 files by specifying values for `make' variables as part of the `make'
530 command line.  For example, if you type
531
532     make install bindir=/usr/local/gnubin
533
534 the `bindir=/usr/local/gnubin' argument indicates that the XEmacs
535 executable files should go in `/usr/local/gnubin', not
536 `/usr/local/bin'.
537
538 Here is a complete list of the variables you may want to set.
539
540 `bindir' indicates where to put executable programs that users can
541         run.  This defaults to /usr/local/bin.
542
543 `datadir' indicates where to put the architecture-independent
544         read-only data files that XEmacs refers to while it runs; it
545         defaults to /usr/local/lib.  We create the following
546         subdirectories under `datadir':
547         - `xemacs-VERSION/lisp', containing the XEmacs lisp libraries, and
548
549         - `xemacs-VERSION/etc', containing the XEmacs tutorial and the
550                 `yow' database.
551         `VERSION' is the number of the XEmacs version you are installing,
552         like `18.59' or `19.14'.  Since these files vary from one version
553         of XEmacs to another, including the version number in the path
554         allows you to have several versions of XEmacs installed at the
555         same time; this means that you don't have to make XEmacs
556         unavailable while installing a new version.
557
558 `statedir' indicates where to put architecture-independent data files
559         that XEmacs modifies while it runs; it defaults to
560         /usr/local/lib as well.  We create the following
561         subdirectories under `statedir':
562         - `xemacs/lock', containing files indicating who is editing
563                 what, so XEmacs can detect editing clashes between
564                 users.
565
566 `libdir' indicates where to put architecture-specific data files that
567         XEmacs refers to as it runs; it too defaults to `/usr/local/lib'.
568         We create the following subdirectories under `libdir':
569         - `xemacs-VERSION/CONFIGURATION-NAME', containing executable
570                 programs used by XEmacs that users are not expected to run
571                 themselves and the DOC file.
572         `VERSION' is the number of the XEmacs version you are installing,
573         and `CONFIGURATION-NAME' is the host type of your system.
574         Since these files are specific to the version of XEmacs,
575         operating system, and architecture in use, including the
576         configuration name in the path allows you to have several
577         versions of XEmacs for any mix of machines and operating
578         systems installed at the same time; this is useful for sites
579         at which different kinds of machines share the file system
580         XEmacs is installed on.
581
582 `infodir' indicates where to put the info files distributed with
583         XEmacs; it defaults to `/usr/local/lib/xemacs-VERSION/info'.
584
585 `mandir' indicates where to put the man pages for XEmacs and its
586         utilities (like `etags'); it defaults to
587         `/usr/local/man/man1'.
588
589 `prefix' doesn't give a path for any specific part of XEmacs; instead,
590         its value is used to determine the defaults for all the
591         architecture-independent path variables - `datadir',
592         `statedir', `infodir', and `mandir'.  Its default value is
593         `/usr/local'; the other variables add on `lib' or `man' to it
594         by default.
595
596         For example, suppose your site generally places GNU software
597         under `/usr/users/software/gnusoft' instead of `/usr/local'.
598         By including
599             `prefix=/usr/users/software/gnusoft'
600         in the arguments to `make', you can instruct the build process
601         to place all of the XEmacs data files in the appropriate
602         directories under that path.
603
604 `exec_prefix' serves the same purpose as `prefix', but instead
605         determines the default values for the architecture-dependent
606         path variables - `bindir' and `libdir'.
607
608 The above variables serve analogous purposes in the makefiles for all
609 GNU software; here are some variables specific to XEmacs.
610
611 `lispdir' indicates where XEmacs installs and expects its lisp
612         libraries.  Its default value, based on `datadir' (see above),
613         is `/usr/local/lib/xemacs-VERSION/lisp' (where `VERSION' is as
614         described above).
615
616 `sitelispdir' indicates where XEmacs should search for lisp libraries
617         specific to your site. XEmacs checks them in order before
618         checking `lispdir'.  Its default value, based on `datadir'
619         (see above), is `/usr/local/lib/xemacs/site-lisp'.
620
621 `etcdir' indicates where XEmacs should install and expect the rest of
622         its architecture-independent data, like the tutorial and yow
623         database.  Its default value, based on `datadir'
624         (see above), is `/usr/local/lib/xemacs-VERSION/etc' (where
625         `VERSION' is as described above).
626
627 `lockdir' indicates the directory where XEmacs keeps track of its
628         locking information.  Its default value, based on `statedir'
629         (see above), is `/usr/local/lib/xemacs/lock'.
630
631 `archlibdir' indicates where XEmacs installs and expects the
632         executable files and other architecture-dependent data it uses
633         while running.  Its default value, based on `libdir' (see
634         above), is `/usr/local/lib/xemacs-VERSION/CONFIGURATION-NAME'
635         (where VERSION and CONFIGURATION-NAME are as described above).
636
637 `docdir' indicates where to put Lisp documentation strings that XEmacs
638         refers to as it runs.  It defaults to the value of `archlibdir'
639         (see above).
640
641 `moduledir' indicates where XEmacs installs and expects to find
642         any dynamic modules.  Its default value, based on
643         `archlibdir' (see above) is
644         `/usr/local/lib/xemacs-VERSION/CONFIGURATION-NAME/modules'
645         (where VERSION and CONFIGURATION-NAME are as described above).
646         By their very nature, dynamic loadable modules are architecture-
647         dependent, and care should be taken not to set this directory
648         to a system- or architecture-independent directory.
649
650 Remember that you must specify any variable values you need each time
651 you run `make' in the top directory.  If you run `make' once to build
652 xemacs, test it, and then run `make' again to install the files, you
653 must provide the same variable settings each time.  To make the
654 settings persist, you can edit them into the `Makefile' in the top
655 directory, but be aware that running the `configure' program erases
656 `Makefile' and rebuilds it from `Makefile.in'.
657
658 The top-level Makefile stores the variable settings it used in the
659 Makefiles for the subdirectories, so you don't have to specify them
660 when running make in the subdirectories.
661
662 Using GNU Make allows for simultaneous builds with and without the
663 --srcdir option.
664
665 MAIL-LOCKING POST-INSTALLATION
666 ==============================
667
668 If your system uses dot-locking to interlock access to mailer inbox
669 files, then you might need to make the movemail program setuid or
670 setgid to enable it to write the lock files.  We believe this is safe.
671 The setuid/setgid bits need not be set on any other XEmacs-related
672 executables.
673
674 CLEANING UP
675 ==========
676
677 You are done with the hard part!  You can remove executables and
678 object files from the build directory by typing `make clean'.  To also
679 remove the files that `configure' created (so you can compile XEmacs
680 for a different configuration), type `make distclean'.
681
682 READ README.packages
683 ====================
684
685 Do it!
686
687 PROBLEMS
688 ========
689
690 The most likely problem is that you forgot to read and follow the
691 directions in README.packages.  You can not have a working XEmacs
692 without downloading some additional packages.
693
694 See the file PROBLEMS in this directory for a list of various
695 problems sometimes encountered, and what to do about them.