111a29bacSmrgInstallation Instructions
211a29bacSmrg*************************
311a29bacSmrg
46b526288SmrgCopyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation,
56b526288SmrgInc.
611a29bacSmrg
76b526288Smrg   Copying and distribution of this file, with or without modification,
86b526288Smrgare permitted in any medium without royalty provided the copyright
96b526288Smrgnotice and this notice are preserved.  This file is offered as-is,
106b526288Smrgwithout warranty of any kind.
1111a29bacSmrg
1211a29bacSmrgBasic Installation
1311a29bacSmrg==================
1411a29bacSmrg
1511a29bacSmrg   Briefly, the shell commands `./configure; make; make install' should
1611a29bacSmrgconfigure, build, and install this package.  The following
1711a29bacSmrgmore-detailed instructions are generic; see the `README' file for
186b526288Smrginstructions specific to this package.  Some packages provide this
196b526288Smrg`INSTALL' file but do not implement all of the features documented
206b526288Smrgbelow.  The lack of an optional feature in a given package is not
216b526288Smrgnecessarily a bug.  More recommendations for GNU packages can be found
226b526288Smrgin *note Makefile Conventions: (standards)Makefile Conventions.
2311a29bacSmrg
2411a29bacSmrg   The `configure' shell script attempts to guess correct values for
2511a29bacSmrgvarious system-dependent variables used during compilation.  It uses
2611a29bacSmrgthose values to create a `Makefile' in each directory of the package.
2711a29bacSmrgIt may also create one or more `.h' files containing system-dependent
2811a29bacSmrgdefinitions.  Finally, it creates a shell script `config.status' that
2911a29bacSmrgyou can run in the future to recreate the current configuration, and a
3011a29bacSmrgfile `config.log' containing compiler output (useful mainly for
3111a29bacSmrgdebugging `configure').
3211a29bacSmrg
3311a29bacSmrg   It can also use an optional file (typically called `config.cache'
3411a29bacSmrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
3511a29bacSmrgthe results of its tests to speed up reconfiguring.  Caching is
3611a29bacSmrgdisabled by default to prevent problems with accidental use of stale
3711a29bacSmrgcache files.
3811a29bacSmrg
3911a29bacSmrg   If you need to do unusual things to compile the package, please try
4011a29bacSmrgto figure out how `configure' could check whether to do them, and mail
4111a29bacSmrgdiffs or instructions to the address given in the `README' so they can
4211a29bacSmrgbe considered for the next release.  If you are using the cache, and at
4311a29bacSmrgsome point `config.cache' contains results you don't want to keep, you
4411a29bacSmrgmay remove or edit it.
4511a29bacSmrg
4611a29bacSmrg   The file `configure.ac' (or `configure.in') is used to create
4711a29bacSmrg`configure' by a program called `autoconf'.  You need `configure.ac' if
4811a29bacSmrgyou want to change it or regenerate `configure' using a newer version
4911a29bacSmrgof `autoconf'.
5011a29bacSmrg
516b526288Smrg   The simplest way to compile this package is:
5211a29bacSmrg
5311a29bacSmrg  1. `cd' to the directory containing the package's source code and type
5411a29bacSmrg     `./configure' to configure the package for your system.
5511a29bacSmrg
5611a29bacSmrg     Running `configure' might take a while.  While running, it prints
5711a29bacSmrg     some messages telling which features it is checking for.
5811a29bacSmrg
5911a29bacSmrg  2. Type `make' to compile the package.
6011a29bacSmrg
6111a29bacSmrg  3. Optionally, type `make check' to run any self-tests that come with
626b526288Smrg     the package, generally using the just-built uninstalled binaries.
6311a29bacSmrg
6411a29bacSmrg  4. Type `make install' to install the programs and any data files and
656b526288Smrg     documentation.  When installing into a prefix owned by root, it is
666b526288Smrg     recommended that the package be configured and built as a regular
676b526288Smrg     user, and only the `make install' phase executed with root
686b526288Smrg     privileges.
696b526288Smrg
706b526288Smrg  5. Optionally, type `make installcheck' to repeat any self-tests, but
716b526288Smrg     this time using the binaries in their final installed location.
726b526288Smrg     This target does not install anything.  Running this target as a
736b526288Smrg     regular user, particularly if the prior `make install' required
746b526288Smrg     root privileges, verifies that the installation completed
756b526288Smrg     correctly.
766b526288Smrg
776b526288Smrg  6. You can remove the program binaries and object files from the
7811a29bacSmrg     source code directory by typing `make clean'.  To also remove the
7911a29bacSmrg     files that `configure' created (so you can compile the package for
8011a29bacSmrg     a different kind of computer), type `make distclean'.  There is
8111a29bacSmrg     also a `make maintainer-clean' target, but that is intended mainly
8211a29bacSmrg     for the package's developers.  If you use it, you may have to get
8311a29bacSmrg     all sorts of other programs in order to regenerate files that came
8411a29bacSmrg     with the distribution.
8511a29bacSmrg
866b526288Smrg  7. Often, you can also type `make uninstall' to remove the installed
876b526288Smrg     files again.  In practice, not all packages have tested that
886b526288Smrg     uninstallation works correctly, even though it is required by the
896b526288Smrg     GNU Coding Standards.
906b526288Smrg
916b526288Smrg  8. Some packages, particularly those that use Automake, provide `make
926b526288Smrg     distcheck', which can by used by developers to test that all other
936b526288Smrg     targets like `make install' and `make uninstall' work correctly.
946b526288Smrg     This target is generally not run by end users.
9511a29bacSmrg
9611a29bacSmrgCompilers and Options
9711a29bacSmrg=====================
9811a29bacSmrg
9911a29bacSmrg   Some systems require unusual options for compilation or linking that
10011a29bacSmrgthe `configure' script does not know about.  Run `./configure --help'
10111a29bacSmrgfor details on some of the pertinent environment variables.
10211a29bacSmrg
10311a29bacSmrg   You can give `configure' initial values for configuration parameters
10411a29bacSmrgby setting variables in the command line or in the environment.  Here
10511a29bacSmrgis an example:
10611a29bacSmrg
10711a29bacSmrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
10811a29bacSmrg
10911a29bacSmrg   *Note Defining Variables::, for more details.
11011a29bacSmrg
11111a29bacSmrgCompiling For Multiple Architectures
11211a29bacSmrg====================================
11311a29bacSmrg
11411a29bacSmrg   You can compile the package for more than one kind of computer at the
11511a29bacSmrgsame time, by placing the object files for each architecture in their
11611a29bacSmrgown directory.  To do this, you can use GNU `make'.  `cd' to the
11711a29bacSmrgdirectory where you want the object files and executables to go and run
11811a29bacSmrgthe `configure' script.  `configure' automatically checks for the
1196b526288Smrgsource code in the directory that `configure' is in and in `..'.  This
1206b526288Smrgis known as a "VPATH" build.
12111a29bacSmrg
12211a29bacSmrg   With a non-GNU `make', it is safer to compile the package for one
12311a29bacSmrgarchitecture at a time in the source code directory.  After you have
12411a29bacSmrginstalled the package for one architecture, use `make distclean' before
12511a29bacSmrgreconfiguring for another architecture.
12611a29bacSmrg
12711a29bacSmrg   On MacOS X 10.5 and later systems, you can create libraries and
12811a29bacSmrgexecutables that work on multiple system types--known as "fat" or
12911a29bacSmrg"universal" binaries--by specifying multiple `-arch' options to the
13011a29bacSmrgcompiler but only a single `-arch' option to the preprocessor.  Like
13111a29bacSmrgthis:
13211a29bacSmrg
13311a29bacSmrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
13411a29bacSmrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
13511a29bacSmrg                 CPP="gcc -E" CXXCPP="g++ -E"
13611a29bacSmrg
13711a29bacSmrg   This is not guaranteed to produce working output in all cases, you
13811a29bacSmrgmay have to build one architecture at a time and combine the results
13911a29bacSmrgusing the `lipo' tool if you have problems.
14011a29bacSmrg
14111a29bacSmrgInstallation Names
14211a29bacSmrg==================
14311a29bacSmrg
14411a29bacSmrg   By default, `make install' installs the package's commands under
14511a29bacSmrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
14611a29bacSmrgcan specify an installation prefix other than `/usr/local' by giving
1476b526288Smrg`configure' the option `--prefix=PREFIX', where PREFIX must be an
1486b526288Smrgabsolute file name.
14911a29bacSmrg
15011a29bacSmrg   You can specify separate installation prefixes for
15111a29bacSmrgarchitecture-specific files and architecture-independent files.  If you
15211a29bacSmrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
15311a29bacSmrgPREFIX as the prefix for installing programs and libraries.
15411a29bacSmrgDocumentation and other data files still use the regular prefix.
15511a29bacSmrg
15611a29bacSmrg   In addition, if you use an unusual directory layout you can give
15711a29bacSmrgoptions like `--bindir=DIR' to specify different values for particular
15811a29bacSmrgkinds of files.  Run `configure --help' for a list of the directories
1596b526288Smrgyou can set and what kinds of files go in them.  In general, the
1606b526288Smrgdefault for these options is expressed in terms of `${prefix}', so that
1616b526288Smrgspecifying just `--prefix' will affect all of the other directory
1626b526288Smrgspecifications that were not explicitly provided.
1636b526288Smrg
1646b526288Smrg   The most portable way to affect installation locations is to pass the
1656b526288Smrgcorrect locations to `configure'; however, many packages provide one or
1666b526288Smrgboth of the following shortcuts of passing variable assignments to the
1676b526288Smrg`make install' command line to change installation locations without
1686b526288Smrghaving to reconfigure or recompile.
1696b526288Smrg
1706b526288Smrg   The first method involves providing an override variable for each
1716b526288Smrgaffected directory.  For example, `make install
1726b526288Smrgprefix=/alternate/directory' will choose an alternate location for all
1736b526288Smrgdirectory configuration variables that were expressed in terms of
1746b526288Smrg`${prefix}'.  Any directories that were specified during `configure',
1756b526288Smrgbut not in terms of `${prefix}', must each be overridden at install
1766b526288Smrgtime for the entire installation to be relocated.  The approach of
1776b526288Smrgmakefile variable overrides for each directory variable is required by
1786b526288Smrgthe GNU Coding Standards, and ideally causes no recompilation.
1796b526288SmrgHowever, some platforms have known limitations with the semantics of
1806b526288Smrgshared libraries that end up requiring recompilation when using this
1816b526288Smrgmethod, particularly noticeable in packages that use GNU Libtool.
1826b526288Smrg
1836b526288Smrg   The second method involves providing the `DESTDIR' variable.  For
1846b526288Smrgexample, `make install DESTDIR=/alternate/directory' will prepend
1856b526288Smrg`/alternate/directory' before all installation names.  The approach of
1866b526288Smrg`DESTDIR' overrides is not required by the GNU Coding Standards, and
1876b526288Smrgdoes not work on platforms that have drive letters.  On the other hand,
1886b526288Smrgit does better at avoiding recompilation issues, and works well even
1896b526288Smrgwhen some directory options were not specified in terms of `${prefix}'
1906b526288Smrgat `configure' time.
1916b526288Smrg
1926b526288SmrgOptional Features
1936b526288Smrg=================
19411a29bacSmrg
19511a29bacSmrg   If the package supports it, you can cause programs to be installed
19611a29bacSmrgwith an extra prefix or suffix on their names by giving `configure' the
19711a29bacSmrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
19811a29bacSmrg
19911a29bacSmrg   Some packages pay attention to `--enable-FEATURE' options to
20011a29bacSmrg`configure', where FEATURE indicates an optional part of the package.
20111a29bacSmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
20211a29bacSmrgis something like `gnu-as' or `x' (for the X Window System).  The
20311a29bacSmrg`README' should mention any `--enable-' and `--with-' options that the
20411a29bacSmrgpackage recognizes.
20511a29bacSmrg
20611a29bacSmrg   For packages that use the X Window System, `configure' can usually
20711a29bacSmrgfind the X include and library files automatically, but if it doesn't,
20811a29bacSmrgyou can use the `configure' options `--x-includes=DIR' and
20911a29bacSmrg`--x-libraries=DIR' to specify their locations.
21011a29bacSmrg
2116b526288Smrg   Some packages offer the ability to configure how verbose the
2126b526288Smrgexecution of `make' will be.  For these packages, running `./configure
2136b526288Smrg--enable-silent-rules' sets the default to minimal output, which can be
2146b526288Smrgoverridden with `make V=1'; while running `./configure
2156b526288Smrg--disable-silent-rules' sets the default to verbose, which can be
2166b526288Smrgoverridden with `make V=0'.
2176b526288Smrg
21811a29bacSmrgParticular systems
21911a29bacSmrg==================
22011a29bacSmrg
22111a29bacSmrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
22211a29bacSmrgCC is not installed, it is recommended to use the following options in
22311a29bacSmrgorder to use an ANSI C compiler:
22411a29bacSmrg
2256b526288Smrg     ./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
22611a29bacSmrg
22711a29bacSmrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
22811a29bacSmrg
2296b526288Smrg   HP-UX `make' updates targets which have the same time stamps as
2306b526288Smrgtheir prerequisites, which makes it generally unusable when shipped
2316b526288Smrggenerated files such as `configure' are involved.  Use GNU `make'
2326b526288Smrginstead.
2336b526288Smrg
23411a29bacSmrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
23511a29bacSmrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
23611a29bacSmrga workaround.  If GNU CC is not installed, it is therefore recommended
23711a29bacSmrgto try
23811a29bacSmrg
23911a29bacSmrg     ./configure CC="cc"
24011a29bacSmrg
24111a29bacSmrgand if that doesn't work, try
24211a29bacSmrg
24311a29bacSmrg     ./configure CC="cc -nodtk"
24411a29bacSmrg
2456b526288Smrg   On Solaris, don't put `/usr/ucb' early in your `PATH'.  This
2466b526288Smrgdirectory contains several dysfunctional programs; working variants of
2476b526288Smrgthese programs are available in `/usr/bin'.  So, if you need `/usr/ucb'
2486b526288Smrgin your `PATH', put it _after_ `/usr/bin'.
2496b526288Smrg
2506b526288Smrg   On Haiku, software installed for all users goes in `/boot/common',
2516b526288Smrgnot `/usr/local'.  It is recommended to use the following options:
2526b526288Smrg
2536b526288Smrg     ./configure --prefix=/boot/common
2546b526288Smrg
25511a29bacSmrgSpecifying the System Type
25611a29bacSmrg==========================
25711a29bacSmrg
25811a29bacSmrg   There may be some features `configure' cannot figure out
25911a29bacSmrgautomatically, but needs to determine by the type of machine the package
26011a29bacSmrgwill run on.  Usually, assuming the package is built to be run on the
26111a29bacSmrg_same_ architectures, `configure' can figure that out, but if it prints
26211a29bacSmrga message saying it cannot guess the machine type, give it the
26311a29bacSmrg`--build=TYPE' option.  TYPE can either be a short name for the system
26411a29bacSmrgtype, such as `sun4', or a canonical name which has the form:
26511a29bacSmrg
26611a29bacSmrg     CPU-COMPANY-SYSTEM
26711a29bacSmrg
26811a29bacSmrgwhere SYSTEM can have one of these forms:
26911a29bacSmrg
2706b526288Smrg     OS
2716b526288Smrg     KERNEL-OS
27211a29bacSmrg
27311a29bacSmrg   See the file `config.sub' for the possible values of each field.  If
27411a29bacSmrg`config.sub' isn't included in this package, then this package doesn't
27511a29bacSmrgneed to know the machine type.
27611a29bacSmrg
27711a29bacSmrg   If you are _building_ compiler tools for cross-compiling, you should
27811a29bacSmrguse the option `--target=TYPE' to select the type of system they will
27911a29bacSmrgproduce code for.
28011a29bacSmrg
28111a29bacSmrg   If you want to _use_ a cross compiler, that generates code for a
28211a29bacSmrgplatform different from the build platform, you should specify the
28311a29bacSmrg"host" platform (i.e., that on which the generated programs will
28411a29bacSmrgeventually be run) with `--host=TYPE'.
28511a29bacSmrg
28611a29bacSmrgSharing Defaults
28711a29bacSmrg================
28811a29bacSmrg
28911a29bacSmrg   If you want to set default values for `configure' scripts to share,
29011a29bacSmrgyou can create a site shell script called `config.site' that gives
29111a29bacSmrgdefault values for variables like `CC', `cache_file', and `prefix'.
29211a29bacSmrg`configure' looks for `PREFIX/share/config.site' if it exists, then
29311a29bacSmrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
29411a29bacSmrg`CONFIG_SITE' environment variable to the location of the site script.
29511a29bacSmrgA warning: not all `configure' scripts look for a site script.
29611a29bacSmrg
29711a29bacSmrgDefining Variables
29811a29bacSmrg==================
29911a29bacSmrg
30011a29bacSmrg   Variables not defined in a site shell script can be set in the
30111a29bacSmrgenvironment passed to `configure'.  However, some packages may run
30211a29bacSmrgconfigure again during the build, and the customized values of these
30311a29bacSmrgvariables may be lost.  In order to avoid this problem, you should set
30411a29bacSmrgthem in the `configure' command line, using `VAR=value'.  For example:
30511a29bacSmrg
30611a29bacSmrg     ./configure CC=/usr/local2/bin/gcc
30711a29bacSmrg
30811a29bacSmrgcauses the specified `gcc' to be used as the C compiler (unless it is
30911a29bacSmrgoverridden in the site shell script).
31011a29bacSmrg
31111a29bacSmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
31211a29bacSmrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
31311a29bacSmrg
31411a29bacSmrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
31511a29bacSmrg
31611a29bacSmrg`configure' Invocation
31711a29bacSmrg======================
31811a29bacSmrg
31911a29bacSmrg   `configure' recognizes the following options to control how it
32011a29bacSmrgoperates.
32111a29bacSmrg
32211a29bacSmrg`--help'
32311a29bacSmrg`-h'
32411a29bacSmrg     Print a summary of all of the options to `configure', and exit.
32511a29bacSmrg
32611a29bacSmrg`--help=short'
32711a29bacSmrg`--help=recursive'
32811a29bacSmrg     Print a summary of the options unique to this package's
32911a29bacSmrg     `configure', and exit.  The `short' variant lists options used
33011a29bacSmrg     only in the top level, while the `recursive' variant lists options
33111a29bacSmrg     also present in any nested packages.
33211a29bacSmrg
33311a29bacSmrg`--version'
33411a29bacSmrg`-V'
33511a29bacSmrg     Print the version of Autoconf used to generate the `configure'
33611a29bacSmrg     script, and exit.
33711a29bacSmrg
33811a29bacSmrg`--cache-file=FILE'
33911a29bacSmrg     Enable the cache: use and save the results of the tests in FILE,
34011a29bacSmrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
34111a29bacSmrg     disable caching.
34211a29bacSmrg
34311a29bacSmrg`--config-cache'
34411a29bacSmrg`-C'
34511a29bacSmrg     Alias for `--cache-file=config.cache'.
34611a29bacSmrg
34711a29bacSmrg`--quiet'
34811a29bacSmrg`--silent'
34911a29bacSmrg`-q'
35011a29bacSmrg     Do not print messages saying which checks are being made.  To
35111a29bacSmrg     suppress all normal output, redirect it to `/dev/null' (any error
35211a29bacSmrg     messages will still be shown).
35311a29bacSmrg
35411a29bacSmrg`--srcdir=DIR'
35511a29bacSmrg     Look for the package's source code in directory DIR.  Usually
35611a29bacSmrg     `configure' can determine that directory automatically.
35711a29bacSmrg
35811a29bacSmrg`--prefix=DIR'
3596b526288Smrg     Use DIR as the installation prefix.  *note Installation Names::
36011a29bacSmrg     for more details, including other options available for fine-tuning
36111a29bacSmrg     the installation locations.
36211a29bacSmrg
36311a29bacSmrg`--no-create'
36411a29bacSmrg`-n'
36511a29bacSmrg     Run the configure checks, but stop before creating any output
36611a29bacSmrg     files.
36711a29bacSmrg
36811a29bacSmrg`configure' also accepts some other, not widely useful, options.  Run
36911a29bacSmrg`configure --help' for more details.
37011a29bacSmrg
371