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