1d1c293acSmrgInstallation Instructions
2d1c293acSmrg*************************
3d1c293acSmrg
404449c54SmrgCopyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation,
504449c54SmrgInc.
6d1c293acSmrg
704449c54Smrg   Copying and distribution of this file, with or without modification,
804449c54Smrgare permitted in any medium without royalty provided the copyright
904449c54Smrgnotice and this notice are preserved.  This file is offered as-is,
1004449c54Smrgwithout warranty of any kind.
11d1c293acSmrg
12d1c293acSmrgBasic Installation
13d1c293acSmrg==================
14d1c293acSmrg
15d1c293acSmrg   Briefly, the shell commands `./configure; make; make install' should
16d1c293acSmrgconfigure, build, and install this package.  The following
17d1c293acSmrgmore-detailed instructions are generic; see the `README' file for
1804449c54Smrginstructions specific to this package.  Some packages provide this
1904449c54Smrg`INSTALL' file but do not implement all of the features documented
2004449c54Smrgbelow.  The lack of an optional feature in a given package is not
2104449c54Smrgnecessarily a bug.  More recommendations for GNU packages can be found
2204449c54Smrgin *note Makefile Conventions: (standards)Makefile Conventions.
23d1c293acSmrg
24d1c293acSmrg   The `configure' shell script attempts to guess correct values for
25d1c293acSmrgvarious system-dependent variables used during compilation.  It uses
26d1c293acSmrgthose values to create a `Makefile' in each directory of the package.
27d1c293acSmrgIt may also create one or more `.h' files containing system-dependent
28d1c293acSmrgdefinitions.  Finally, it creates a shell script `config.status' that
29d1c293acSmrgyou can run in the future to recreate the current configuration, and a
30d1c293acSmrgfile `config.log' containing compiler output (useful mainly for
31d1c293acSmrgdebugging `configure').
32d1c293acSmrg
33d1c293acSmrg   It can also use an optional file (typically called `config.cache'
34d1c293acSmrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
35d1c293acSmrgthe results of its tests to speed up reconfiguring.  Caching is
36d1c293acSmrgdisabled by default to prevent problems with accidental use of stale
37d1c293acSmrgcache files.
38d1c293acSmrg
39d1c293acSmrg   If you need to do unusual things to compile the package, please try
40d1c293acSmrgto figure out how `configure' could check whether to do them, and mail
41d1c293acSmrgdiffs or instructions to the address given in the `README' so they can
42d1c293acSmrgbe considered for the next release.  If you are using the cache, and at
43d1c293acSmrgsome point `config.cache' contains results you don't want to keep, you
44d1c293acSmrgmay remove or edit it.
45d1c293acSmrg
46d1c293acSmrg   The file `configure.ac' (or `configure.in') is used to create
47d1c293acSmrg`configure' by a program called `autoconf'.  You need `configure.ac' if
48d1c293acSmrgyou want to change it or regenerate `configure' using a newer version
49d1c293acSmrgof `autoconf'.
50d1c293acSmrg
5104449c54Smrg   The simplest way to compile this package is:
52d1c293acSmrg
53d1c293acSmrg  1. `cd' to the directory containing the package's source code and type
54d1c293acSmrg     `./configure' to configure the package for your system.
55d1c293acSmrg
56d1c293acSmrg     Running `configure' might take a while.  While running, it prints
57d1c293acSmrg     some messages telling which features it is checking for.
58d1c293acSmrg
59d1c293acSmrg  2. Type `make' to compile the package.
60d1c293acSmrg
61d1c293acSmrg  3. Optionally, type `make check' to run any self-tests that come with
6204449c54Smrg     the package, generally using the just-built uninstalled binaries.
63d1c293acSmrg
64d1c293acSmrg  4. Type `make install' to install the programs and any data files and
6504449c54Smrg     documentation.  When installing into a prefix owned by root, it is
6604449c54Smrg     recommended that the package be configured and built as a regular
6704449c54Smrg     user, and only the `make install' phase executed with root
6804449c54Smrg     privileges.
6904449c54Smrg
7004449c54Smrg  5. Optionally, type `make installcheck' to repeat any self-tests, but
7104449c54Smrg     this time using the binaries in their final installed location.
7204449c54Smrg     This target does not install anything.  Running this target as a
7304449c54Smrg     regular user, particularly if the prior `make install' required
7404449c54Smrg     root privileges, verifies that the installation completed
7504449c54Smrg     correctly.
7604449c54Smrg
7704449c54Smrg  6. You can remove the program binaries and object files from the
78d1c293acSmrg     source code directory by typing `make clean'.  To also remove the
79d1c293acSmrg     files that `configure' created (so you can compile the package for
80d1c293acSmrg     a different kind of computer), type `make distclean'.  There is
81d1c293acSmrg     also a `make maintainer-clean' target, but that is intended mainly
82d1c293acSmrg     for the package's developers.  If you use it, you may have to get
83d1c293acSmrg     all sorts of other programs in order to regenerate files that came
84d1c293acSmrg     with the distribution.
85d1c293acSmrg
8604449c54Smrg  7. Often, you can also type `make uninstall' to remove the installed
8704449c54Smrg     files again.  In practice, not all packages have tested that
8804449c54Smrg     uninstallation works correctly, even though it is required by the
8904449c54Smrg     GNU Coding Standards.
9004449c54Smrg
9104449c54Smrg  8. Some packages, particularly those that use Automake, provide `make
9204449c54Smrg     distcheck', which can by used by developers to test that all other
9304449c54Smrg     targets like `make install' and `make uninstall' work correctly.
9404449c54Smrg     This target is generally not run by end users.
95d1c293acSmrg
96d1c293acSmrgCompilers and Options
97d1c293acSmrg=====================
98d1c293acSmrg
99d1c293acSmrg   Some systems require unusual options for compilation or linking that
100d1c293acSmrgthe `configure' script does not know about.  Run `./configure --help'
101d1c293acSmrgfor details on some of the pertinent environment variables.
102d1c293acSmrg
103d1c293acSmrg   You can give `configure' initial values for configuration parameters
104d1c293acSmrgby setting variables in the command line or in the environment.  Here
105d1c293acSmrgis an example:
106d1c293acSmrg
107d1c293acSmrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
108d1c293acSmrg
109d1c293acSmrg   *Note Defining Variables::, for more details.
110d1c293acSmrg
111d1c293acSmrgCompiling For Multiple Architectures
112d1c293acSmrg====================================
113d1c293acSmrg
114d1c293acSmrg   You can compile the package for more than one kind of computer at the
115d1c293acSmrgsame time, by placing the object files for each architecture in their
116d1c293acSmrgown directory.  To do this, you can use GNU `make'.  `cd' to the
117d1c293acSmrgdirectory where you want the object files and executables to go and run
118d1c293acSmrgthe `configure' script.  `configure' automatically checks for the
11904449c54Smrgsource code in the directory that `configure' is in and in `..'.  This
12004449c54Smrgis known as a "VPATH" build.
121d1c293acSmrg
122d1c293acSmrg   With a non-GNU `make', it is safer to compile the package for one
123d1c293acSmrgarchitecture at a time in the source code directory.  After you have
124d1c293acSmrginstalled the package for one architecture, use `make distclean' before
125d1c293acSmrgreconfiguring for another architecture.
126d1c293acSmrg
127d1c293acSmrg   On MacOS X 10.5 and later systems, you can create libraries and
128d1c293acSmrgexecutables that work on multiple system types--known as "fat" or
129d1c293acSmrg"universal" binaries--by specifying multiple `-arch' options to the
130d1c293acSmrgcompiler but only a single `-arch' option to the preprocessor.  Like
131d1c293acSmrgthis:
132d1c293acSmrg
133d1c293acSmrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
134d1c293acSmrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
135d1c293acSmrg                 CPP="gcc -E" CXXCPP="g++ -E"
136d1c293acSmrg
137d1c293acSmrg   This is not guaranteed to produce working output in all cases, you
138d1c293acSmrgmay have to build one architecture at a time and combine the results
139d1c293acSmrgusing the `lipo' tool if you have problems.
140d1c293acSmrg
141d1c293acSmrgInstallation Names
142d1c293acSmrg==================
143d1c293acSmrg
144d1c293acSmrg   By default, `make install' installs the package's commands under
145d1c293acSmrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
146d1c293acSmrgcan specify an installation prefix other than `/usr/local' by giving
14704449c54Smrg`configure' the option `--prefix=PREFIX', where PREFIX must be an
14804449c54Smrgabsolute file name.
149d1c293acSmrg
150d1c293acSmrg   You can specify separate installation prefixes for
151d1c293acSmrgarchitecture-specific files and architecture-independent files.  If you
152d1c293acSmrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
153d1c293acSmrgPREFIX as the prefix for installing programs and libraries.
154d1c293acSmrgDocumentation and other data files still use the regular prefix.
155d1c293acSmrg
156d1c293acSmrg   In addition, if you use an unusual directory layout you can give
157d1c293acSmrgoptions like `--bindir=DIR' to specify different values for particular
158d1c293acSmrgkinds of files.  Run `configure --help' for a list of the directories
15904449c54Smrgyou can set and what kinds of files go in them.  In general, the
16004449c54Smrgdefault for these options is expressed in terms of `${prefix}', so that
16104449c54Smrgspecifying just `--prefix' will affect all of the other directory
16204449c54Smrgspecifications that were not explicitly provided.
16304449c54Smrg
16404449c54Smrg   The most portable way to affect installation locations is to pass the
16504449c54Smrgcorrect locations to `configure'; however, many packages provide one or
16604449c54Smrgboth of the following shortcuts of passing variable assignments to the
16704449c54Smrg`make install' command line to change installation locations without
16804449c54Smrghaving to reconfigure or recompile.
16904449c54Smrg
17004449c54Smrg   The first method involves providing an override variable for each
17104449c54Smrgaffected directory.  For example, `make install
17204449c54Smrgprefix=/alternate/directory' will choose an alternate location for all
17304449c54Smrgdirectory configuration variables that were expressed in terms of
17404449c54Smrg`${prefix}'.  Any directories that were specified during `configure',
17504449c54Smrgbut not in terms of `${prefix}', must each be overridden at install
17604449c54Smrgtime for the entire installation to be relocated.  The approach of
17704449c54Smrgmakefile variable overrides for each directory variable is required by
17804449c54Smrgthe GNU Coding Standards, and ideally causes no recompilation.
17904449c54SmrgHowever, some platforms have known limitations with the semantics of
18004449c54Smrgshared libraries that end up requiring recompilation when using this
18104449c54Smrgmethod, particularly noticeable in packages that use GNU Libtool.
18204449c54Smrg
18304449c54Smrg   The second method involves providing the `DESTDIR' variable.  For
18404449c54Smrgexample, `make install DESTDIR=/alternate/directory' will prepend
18504449c54Smrg`/alternate/directory' before all installation names.  The approach of
18604449c54Smrg`DESTDIR' overrides is not required by the GNU Coding Standards, and
18704449c54Smrgdoes not work on platforms that have drive letters.  On the other hand,
18804449c54Smrgit does better at avoiding recompilation issues, and works well even
18904449c54Smrgwhen some directory options were not specified in terms of `${prefix}'
19004449c54Smrgat `configure' time.
19104449c54Smrg
19204449c54SmrgOptional Features
19304449c54Smrg=================
194d1c293acSmrg
195d1c293acSmrg   If the package supports it, you can cause programs to be installed
196d1c293acSmrgwith an extra prefix or suffix on their names by giving `configure' the
197d1c293acSmrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
198d1c293acSmrg
199d1c293acSmrg   Some packages pay attention to `--enable-FEATURE' options to
200d1c293acSmrg`configure', where FEATURE indicates an optional part of the package.
201d1c293acSmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
202d1c293acSmrgis something like `gnu-as' or `x' (for the X Window System).  The
203d1c293acSmrg`README' should mention any `--enable-' and `--with-' options that the
204d1c293acSmrgpackage recognizes.
205d1c293acSmrg
206d1c293acSmrg   For packages that use the X Window System, `configure' can usually
207d1c293acSmrgfind the X include and library files automatically, but if it doesn't,
208d1c293acSmrgyou can use the `configure' options `--x-includes=DIR' and
209d1c293acSmrg`--x-libraries=DIR' to specify their locations.
210d1c293acSmrg
21104449c54Smrg   Some packages offer the ability to configure how verbose the
21204449c54Smrgexecution of `make' will be.  For these packages, running `./configure
21304449c54Smrg--enable-silent-rules' sets the default to minimal output, which can be
21404449c54Smrgoverridden with `make V=1'; while running `./configure
21504449c54Smrg--disable-silent-rules' sets the default to verbose, which can be
21604449c54Smrgoverridden with `make V=0'.
21704449c54Smrg
218d1c293acSmrgParticular systems
219d1c293acSmrg==================
220d1c293acSmrg
221d1c293acSmrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
222d1c293acSmrgCC is not installed, it is recommended to use the following options in
223d1c293acSmrgorder to use an ANSI C compiler:
224d1c293acSmrg
22504449c54Smrg     ./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
226d1c293acSmrg
227d1c293acSmrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
228d1c293acSmrg
22904449c54Smrg   HP-UX `make' updates targets which have the same time stamps as
23004449c54Smrgtheir prerequisites, which makes it generally unusable when shipped
23104449c54Smrggenerated files such as `configure' are involved.  Use GNU `make'
23204449c54Smrginstead.
23304449c54Smrg
234d1c293acSmrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
235d1c293acSmrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
236d1c293acSmrga workaround.  If GNU CC is not installed, it is therefore recommended
237d1c293acSmrgto try
238d1c293acSmrg
239d1c293acSmrg     ./configure CC="cc"
240d1c293acSmrg
241d1c293acSmrgand if that doesn't work, try
242d1c293acSmrg
243d1c293acSmrg     ./configure CC="cc -nodtk"
244d1c293acSmrg
24504449c54Smrg   On Solaris, don't put `/usr/ucb' early in your `PATH'.  This
24604449c54Smrgdirectory contains several dysfunctional programs; working variants of
24704449c54Smrgthese programs are available in `/usr/bin'.  So, if you need `/usr/ucb'
24804449c54Smrgin your `PATH', put it _after_ `/usr/bin'.
24904449c54Smrg
25004449c54Smrg   On Haiku, software installed for all users goes in `/boot/common',
25104449c54Smrgnot `/usr/local'.  It is recommended to use the following options:
25204449c54Smrg
25304449c54Smrg     ./configure --prefix=/boot/common
25404449c54Smrg
255d1c293acSmrgSpecifying the System Type
256d1c293acSmrg==========================
257d1c293acSmrg
258d1c293acSmrg   There may be some features `configure' cannot figure out
259d1c293acSmrgautomatically, but needs to determine by the type of machine the package
260d1c293acSmrgwill run on.  Usually, assuming the package is built to be run on the
261d1c293acSmrg_same_ architectures, `configure' can figure that out, but if it prints
262d1c293acSmrga message saying it cannot guess the machine type, give it the
263d1c293acSmrg`--build=TYPE' option.  TYPE can either be a short name for the system
264d1c293acSmrgtype, such as `sun4', or a canonical name which has the form:
265d1c293acSmrg
266d1c293acSmrg     CPU-COMPANY-SYSTEM
267d1c293acSmrg
268d1c293acSmrgwhere SYSTEM can have one of these forms:
269d1c293acSmrg
27004449c54Smrg     OS
27104449c54Smrg     KERNEL-OS
272d1c293acSmrg
273d1c293acSmrg   See the file `config.sub' for the possible values of each field.  If
274d1c293acSmrg`config.sub' isn't included in this package, then this package doesn't
275d1c293acSmrgneed to know the machine type.
276d1c293acSmrg
277d1c293acSmrg   If you are _building_ compiler tools for cross-compiling, you should
278d1c293acSmrguse the option `--target=TYPE' to select the type of system they will
279d1c293acSmrgproduce code for.
280d1c293acSmrg
281d1c293acSmrg   If you want to _use_ a cross compiler, that generates code for a
282d1c293acSmrgplatform different from the build platform, you should specify the
283d1c293acSmrg"host" platform (i.e., that on which the generated programs will
284d1c293acSmrgeventually be run) with `--host=TYPE'.
285d1c293acSmrg
286d1c293acSmrgSharing Defaults
287d1c293acSmrg================
288d1c293acSmrg
289d1c293acSmrg   If you want to set default values for `configure' scripts to share,
290d1c293acSmrgyou can create a site shell script called `config.site' that gives
291d1c293acSmrgdefault values for variables like `CC', `cache_file', and `prefix'.
292d1c293acSmrg`configure' looks for `PREFIX/share/config.site' if it exists, then
293d1c293acSmrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
294d1c293acSmrg`CONFIG_SITE' environment variable to the location of the site script.
295d1c293acSmrgA warning: not all `configure' scripts look for a site script.
296d1c293acSmrg
297d1c293acSmrgDefining Variables
298d1c293acSmrg==================
299d1c293acSmrg
300d1c293acSmrg   Variables not defined in a site shell script can be set in the
301d1c293acSmrgenvironment passed to `configure'.  However, some packages may run
302d1c293acSmrgconfigure again during the build, and the customized values of these
303d1c293acSmrgvariables may be lost.  In order to avoid this problem, you should set
304d1c293acSmrgthem in the `configure' command line, using `VAR=value'.  For example:
305d1c293acSmrg
306d1c293acSmrg     ./configure CC=/usr/local2/bin/gcc
307d1c293acSmrg
308d1c293acSmrgcauses the specified `gcc' to be used as the C compiler (unless it is
309d1c293acSmrgoverridden in the site shell script).
310d1c293acSmrg
311d1c293acSmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
312d1c293acSmrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
313d1c293acSmrg
314d1c293acSmrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
315d1c293acSmrg
316d1c293acSmrg`configure' Invocation
317d1c293acSmrg======================
318d1c293acSmrg
319d1c293acSmrg   `configure' recognizes the following options to control how it
320d1c293acSmrgoperates.
321d1c293acSmrg
322d1c293acSmrg`--help'
323d1c293acSmrg`-h'
324d1c293acSmrg     Print a summary of all of the options to `configure', and exit.
325d1c293acSmrg
326d1c293acSmrg`--help=short'
327d1c293acSmrg`--help=recursive'
328d1c293acSmrg     Print a summary of the options unique to this package's
329d1c293acSmrg     `configure', and exit.  The `short' variant lists options used
330d1c293acSmrg     only in the top level, while the `recursive' variant lists options
331d1c293acSmrg     also present in any nested packages.
332d1c293acSmrg
333d1c293acSmrg`--version'
334d1c293acSmrg`-V'
335d1c293acSmrg     Print the version of Autoconf used to generate the `configure'
336d1c293acSmrg     script, and exit.
337d1c293acSmrg
338d1c293acSmrg`--cache-file=FILE'
339d1c293acSmrg     Enable the cache: use and save the results of the tests in FILE,
340d1c293acSmrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
341d1c293acSmrg     disable caching.
342d1c293acSmrg
343d1c293acSmrg`--config-cache'
344d1c293acSmrg`-C'
345d1c293acSmrg     Alias for `--cache-file=config.cache'.
346d1c293acSmrg
347d1c293acSmrg`--quiet'
348d1c293acSmrg`--silent'
349d1c293acSmrg`-q'
350d1c293acSmrg     Do not print messages saying which checks are being made.  To
351d1c293acSmrg     suppress all normal output, redirect it to `/dev/null' (any error
352d1c293acSmrg     messages will still be shown).
353d1c293acSmrg
354d1c293acSmrg`--srcdir=DIR'
355d1c293acSmrg     Look for the package's source code in directory DIR.  Usually
356d1c293acSmrg     `configure' can determine that directory automatically.
357d1c293acSmrg
358d1c293acSmrg`--prefix=DIR'
35904449c54Smrg     Use DIR as the installation prefix.  *note Installation Names::
360d1c293acSmrg     for more details, including other options available for fine-tuning
361d1c293acSmrg     the installation locations.
362d1c293acSmrg
363d1c293acSmrg`--no-create'
364d1c293acSmrg`-n'
365d1c293acSmrg     Run the configure checks, but stop before creating any output
366d1c293acSmrg     files.
367d1c293acSmrg
368d1c293acSmrg`configure' also accepts some other, not widely useful, options.  Run
369d1c293acSmrg`configure --help' for more details.
370d1c293acSmrg
371