163847c39SmrgInstallation Instructions
263847c39Smrg*************************
363847c39Smrg
49586ba5aSmrgCopyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation,
59586ba5aSmrgInc.
663847c39Smrg
79586ba5aSmrg   Copying and distribution of this file, with or without modification,
89586ba5aSmrgare permitted in any medium without royalty provided the copyright
99586ba5aSmrgnotice and this notice are preserved.  This file is offered as-is,
109586ba5aSmrgwithout warranty of any kind.
1163847c39Smrg
1263847c39SmrgBasic Installation
1363847c39Smrg==================
1463847c39Smrg
1563847c39Smrg   Briefly, the shell commands `./configure; make; make install' should
1663847c39Smrgconfigure, build, and install this package.  The following
1763847c39Smrgmore-detailed instructions are generic; see the `README' file for
189586ba5aSmrginstructions specific to this package.  Some packages provide this
199586ba5aSmrg`INSTALL' file but do not implement all of the features documented
209586ba5aSmrgbelow.  The lack of an optional feature in a given package is not
219586ba5aSmrgnecessarily a bug.  More recommendations for GNU packages can be found
229586ba5aSmrgin *note Makefile Conventions: (standards)Makefile Conventions.
2363847c39Smrg
2463847c39Smrg   The `configure' shell script attempts to guess correct values for
2563847c39Smrgvarious system-dependent variables used during compilation.  It uses
2663847c39Smrgthose values to create a `Makefile' in each directory of the package.
2763847c39SmrgIt may also create one or more `.h' files containing system-dependent
2863847c39Smrgdefinitions.  Finally, it creates a shell script `config.status' that
2963847c39Smrgyou can run in the future to recreate the current configuration, and a
3063847c39Smrgfile `config.log' containing compiler output (useful mainly for
3163847c39Smrgdebugging `configure').
3263847c39Smrg
3363847c39Smrg   It can also use an optional file (typically called `config.cache'
3463847c39Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
3563847c39Smrgthe results of its tests to speed up reconfiguring.  Caching is
3663847c39Smrgdisabled by default to prevent problems with accidental use of stale
3763847c39Smrgcache files.
3863847c39Smrg
3963847c39Smrg   If you need to do unusual things to compile the package, please try
4063847c39Smrgto figure out how `configure' could check whether to do them, and mail
4163847c39Smrgdiffs or instructions to the address given in the `README' so they can
4263847c39Smrgbe considered for the next release.  If you are using the cache, and at
4363847c39Smrgsome point `config.cache' contains results you don't want to keep, you
4463847c39Smrgmay remove or edit it.
4563847c39Smrg
4663847c39Smrg   The file `configure.ac' (or `configure.in') is used to create
4763847c39Smrg`configure' by a program called `autoconf'.  You need `configure.ac' if
4863847c39Smrgyou want to change it or regenerate `configure' using a newer version
4963847c39Smrgof `autoconf'.
5063847c39Smrg
519586ba5aSmrg   The simplest way to compile this package is:
5263847c39Smrg
5363847c39Smrg  1. `cd' to the directory containing the package's source code and type
5463847c39Smrg     `./configure' to configure the package for your system.
5563847c39Smrg
5663847c39Smrg     Running `configure' might take a while.  While running, it prints
5763847c39Smrg     some messages telling which features it is checking for.
5863847c39Smrg
5963847c39Smrg  2. Type `make' to compile the package.
6063847c39Smrg
6163847c39Smrg  3. Optionally, type `make check' to run any self-tests that come with
629586ba5aSmrg     the package, generally using the just-built uninstalled binaries.
6363847c39Smrg
6463847c39Smrg  4. Type `make install' to install the programs and any data files and
659586ba5aSmrg     documentation.  When installing into a prefix owned by root, it is
669586ba5aSmrg     recommended that the package be configured and built as a regular
679586ba5aSmrg     user, and only the `make install' phase executed with root
689586ba5aSmrg     privileges.
699586ba5aSmrg
709586ba5aSmrg  5. Optionally, type `make installcheck' to repeat any self-tests, but
719586ba5aSmrg     this time using the binaries in their final installed location.
729586ba5aSmrg     This target does not install anything.  Running this target as a
739586ba5aSmrg     regular user, particularly if the prior `make install' required
749586ba5aSmrg     root privileges, verifies that the installation completed
759586ba5aSmrg     correctly.
769586ba5aSmrg
779586ba5aSmrg  6. You can remove the program binaries and object files from the
7863847c39Smrg     source code directory by typing `make clean'.  To also remove the
7963847c39Smrg     files that `configure' created (so you can compile the package for
8063847c39Smrg     a different kind of computer), type `make distclean'.  There is
8163847c39Smrg     also a `make maintainer-clean' target, but that is intended mainly
8263847c39Smrg     for the package's developers.  If you use it, you may have to get
8363847c39Smrg     all sorts of other programs in order to regenerate files that came
8463847c39Smrg     with the distribution.
8563847c39Smrg
869586ba5aSmrg  7. Often, you can also type `make uninstall' to remove the installed
879586ba5aSmrg     files again.  In practice, not all packages have tested that
889586ba5aSmrg     uninstallation works correctly, even though it is required by the
899586ba5aSmrg     GNU Coding Standards.
909586ba5aSmrg
919586ba5aSmrg  8. Some packages, particularly those that use Automake, provide `make
929586ba5aSmrg     distcheck', which can by used by developers to test that all other
939586ba5aSmrg     targets like `make install' and `make uninstall' work correctly.
949586ba5aSmrg     This target is generally not run by end users.
9563847c39Smrg
9663847c39SmrgCompilers and Options
9763847c39Smrg=====================
9863847c39Smrg
9963847c39Smrg   Some systems require unusual options for compilation or linking that
10063847c39Smrgthe `configure' script does not know about.  Run `./configure --help'
10163847c39Smrgfor details on some of the pertinent environment variables.
10263847c39Smrg
10363847c39Smrg   You can give `configure' initial values for configuration parameters
10463847c39Smrgby setting variables in the command line or in the environment.  Here
10563847c39Smrgis an example:
10663847c39Smrg
10763847c39Smrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
10863847c39Smrg
10963847c39Smrg   *Note Defining Variables::, for more details.
11063847c39Smrg
11163847c39SmrgCompiling For Multiple Architectures
11263847c39Smrg====================================
11363847c39Smrg
11463847c39Smrg   You can compile the package for more than one kind of computer at the
11563847c39Smrgsame time, by placing the object files for each architecture in their
11663847c39Smrgown directory.  To do this, you can use GNU `make'.  `cd' to the
11763847c39Smrgdirectory where you want the object files and executables to go and run
11863847c39Smrgthe `configure' script.  `configure' automatically checks for the
1199586ba5aSmrgsource code in the directory that `configure' is in and in `..'.  This
1209586ba5aSmrgis known as a "VPATH" build.
12163847c39Smrg
12263847c39Smrg   With a non-GNU `make', it is safer to compile the package for one
12363847c39Smrgarchitecture at a time in the source code directory.  After you have
12463847c39Smrginstalled the package for one architecture, use `make distclean' before
12563847c39Smrgreconfiguring for another architecture.
12663847c39Smrg
12763847c39Smrg   On MacOS X 10.5 and later systems, you can create libraries and
12863847c39Smrgexecutables that work on multiple system types--known as "fat" or
12963847c39Smrg"universal" binaries--by specifying multiple `-arch' options to the
13063847c39Smrgcompiler but only a single `-arch' option to the preprocessor.  Like
13163847c39Smrgthis:
13263847c39Smrg
13363847c39Smrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
13463847c39Smrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
13563847c39Smrg                 CPP="gcc -E" CXXCPP="g++ -E"
13663847c39Smrg
13763847c39Smrg   This is not guaranteed to produce working output in all cases, you
13863847c39Smrgmay have to build one architecture at a time and combine the results
13963847c39Smrgusing the `lipo' tool if you have problems.
14063847c39Smrg
14163847c39SmrgInstallation Names
14263847c39Smrg==================
14363847c39Smrg
14463847c39Smrg   By default, `make install' installs the package's commands under
14563847c39Smrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
14663847c39Smrgcan specify an installation prefix other than `/usr/local' by giving
1479586ba5aSmrg`configure' the option `--prefix=PREFIX', where PREFIX must be an
1489586ba5aSmrgabsolute file name.
14963847c39Smrg
15063847c39Smrg   You can specify separate installation prefixes for
15163847c39Smrgarchitecture-specific files and architecture-independent files.  If you
15263847c39Smrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
15363847c39SmrgPREFIX as the prefix for installing programs and libraries.
15463847c39SmrgDocumentation and other data files still use the regular prefix.
15563847c39Smrg
15663847c39Smrg   In addition, if you use an unusual directory layout you can give
15763847c39Smrgoptions like `--bindir=DIR' to specify different values for particular
15863847c39Smrgkinds of files.  Run `configure --help' for a list of the directories
1599586ba5aSmrgyou can set and what kinds of files go in them.  In general, the
1609586ba5aSmrgdefault for these options is expressed in terms of `${prefix}', so that
1619586ba5aSmrgspecifying just `--prefix' will affect all of the other directory
1629586ba5aSmrgspecifications that were not explicitly provided.
1639586ba5aSmrg
1649586ba5aSmrg   The most portable way to affect installation locations is to pass the
1659586ba5aSmrgcorrect locations to `configure'; however, many packages provide one or
1669586ba5aSmrgboth of the following shortcuts of passing variable assignments to the
1679586ba5aSmrg`make install' command line to change installation locations without
1689586ba5aSmrghaving to reconfigure or recompile.
1699586ba5aSmrg
1709586ba5aSmrg   The first method involves providing an override variable for each
1719586ba5aSmrgaffected directory.  For example, `make install
1729586ba5aSmrgprefix=/alternate/directory' will choose an alternate location for all
1739586ba5aSmrgdirectory configuration variables that were expressed in terms of
1749586ba5aSmrg`${prefix}'.  Any directories that were specified during `configure',
1759586ba5aSmrgbut not in terms of `${prefix}', must each be overridden at install
1769586ba5aSmrgtime for the entire installation to be relocated.  The approach of
1779586ba5aSmrgmakefile variable overrides for each directory variable is required by
1789586ba5aSmrgthe GNU Coding Standards, and ideally causes no recompilation.
1799586ba5aSmrgHowever, some platforms have known limitations with the semantics of
1809586ba5aSmrgshared libraries that end up requiring recompilation when using this
1819586ba5aSmrgmethod, particularly noticeable in packages that use GNU Libtool.
1829586ba5aSmrg
1839586ba5aSmrg   The second method involves providing the `DESTDIR' variable.  For
1849586ba5aSmrgexample, `make install DESTDIR=/alternate/directory' will prepend
1859586ba5aSmrg`/alternate/directory' before all installation names.  The approach of
1869586ba5aSmrg`DESTDIR' overrides is not required by the GNU Coding Standards, and
1879586ba5aSmrgdoes not work on platforms that have drive letters.  On the other hand,
1889586ba5aSmrgit does better at avoiding recompilation issues, and works well even
1899586ba5aSmrgwhen some directory options were not specified in terms of `${prefix}'
1909586ba5aSmrgat `configure' time.
1919586ba5aSmrg
1929586ba5aSmrgOptional Features
1939586ba5aSmrg=================
19463847c39Smrg
19563847c39Smrg   If the package supports it, you can cause programs to be installed
19663847c39Smrgwith an extra prefix or suffix on their names by giving `configure' the
19763847c39Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
19863847c39Smrg
19963847c39Smrg   Some packages pay attention to `--enable-FEATURE' options to
20063847c39Smrg`configure', where FEATURE indicates an optional part of the package.
20163847c39SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
20263847c39Smrgis something like `gnu-as' or `x' (for the X Window System).  The
20363847c39Smrg`README' should mention any `--enable-' and `--with-' options that the
20463847c39Smrgpackage recognizes.
20563847c39Smrg
20663847c39Smrg   For packages that use the X Window System, `configure' can usually
20763847c39Smrgfind the X include and library files automatically, but if it doesn't,
20863847c39Smrgyou can use the `configure' options `--x-includes=DIR' and
20963847c39Smrg`--x-libraries=DIR' to specify their locations.
21063847c39Smrg
2119586ba5aSmrg   Some packages offer the ability to configure how verbose the
2129586ba5aSmrgexecution of `make' will be.  For these packages, running `./configure
2139586ba5aSmrg--enable-silent-rules' sets the default to minimal output, which can be
2149586ba5aSmrgoverridden with `make V=1'; while running `./configure
2159586ba5aSmrg--disable-silent-rules' sets the default to verbose, which can be
2169586ba5aSmrgoverridden with `make V=0'.
2179586ba5aSmrg
21863847c39SmrgParticular systems
21963847c39Smrg==================
22063847c39Smrg
22163847c39Smrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
22263847c39SmrgCC is not installed, it is recommended to use the following options in
22363847c39Smrgorder to use an ANSI C compiler:
22463847c39Smrg
2259586ba5aSmrg     ./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
22663847c39Smrg
22763847c39Smrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
22863847c39Smrg
2299586ba5aSmrg   HP-UX `make' updates targets which have the same time stamps as
2309586ba5aSmrgtheir prerequisites, which makes it generally unusable when shipped
2319586ba5aSmrggenerated files such as `configure' are involved.  Use GNU `make'
2329586ba5aSmrginstead.
2339586ba5aSmrg
23463847c39Smrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
23563847c39Smrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
23663847c39Smrga workaround.  If GNU CC is not installed, it is therefore recommended
23763847c39Smrgto try
23863847c39Smrg
23963847c39Smrg     ./configure CC="cc"
24063847c39Smrg
24163847c39Smrgand if that doesn't work, try
24263847c39Smrg
24363847c39Smrg     ./configure CC="cc -nodtk"
24463847c39Smrg
2459586ba5aSmrg   On Solaris, don't put `/usr/ucb' early in your `PATH'.  This
2469586ba5aSmrgdirectory contains several dysfunctional programs; working variants of
2479586ba5aSmrgthese programs are available in `/usr/bin'.  So, if you need `/usr/ucb'
2489586ba5aSmrgin your `PATH', put it _after_ `/usr/bin'.
2499586ba5aSmrg
2509586ba5aSmrg   On Haiku, software installed for all users goes in `/boot/common',
2519586ba5aSmrgnot `/usr/local'.  It is recommended to use the following options:
2529586ba5aSmrg
2539586ba5aSmrg     ./configure --prefix=/boot/common
2549586ba5aSmrg
25563847c39SmrgSpecifying the System Type
25663847c39Smrg==========================
25763847c39Smrg
25863847c39Smrg   There may be some features `configure' cannot figure out
25963847c39Smrgautomatically, but needs to determine by the type of machine the package
26063847c39Smrgwill run on.  Usually, assuming the package is built to be run on the
26163847c39Smrg_same_ architectures, `configure' can figure that out, but if it prints
26263847c39Smrga message saying it cannot guess the machine type, give it the
26363847c39Smrg`--build=TYPE' option.  TYPE can either be a short name for the system
26463847c39Smrgtype, such as `sun4', or a canonical name which has the form:
26563847c39Smrg
26663847c39Smrg     CPU-COMPANY-SYSTEM
26763847c39Smrg
26863847c39Smrgwhere SYSTEM can have one of these forms:
26963847c39Smrg
2709586ba5aSmrg     OS
2719586ba5aSmrg     KERNEL-OS
27263847c39Smrg
27363847c39Smrg   See the file `config.sub' for the possible values of each field.  If
27463847c39Smrg`config.sub' isn't included in this package, then this package doesn't
27563847c39Smrgneed to know the machine type.
27663847c39Smrg
27763847c39Smrg   If you are _building_ compiler tools for cross-compiling, you should
27863847c39Smrguse the option `--target=TYPE' to select the type of system they will
27963847c39Smrgproduce code for.
28063847c39Smrg
28163847c39Smrg   If you want to _use_ a cross compiler, that generates code for a
28263847c39Smrgplatform different from the build platform, you should specify the
28363847c39Smrg"host" platform (i.e., that on which the generated programs will
28463847c39Smrgeventually be run) with `--host=TYPE'.
28563847c39Smrg
28663847c39SmrgSharing Defaults
28763847c39Smrg================
28863847c39Smrg
28963847c39Smrg   If you want to set default values for `configure' scripts to share,
29063847c39Smrgyou can create a site shell script called `config.site' that gives
29163847c39Smrgdefault values for variables like `CC', `cache_file', and `prefix'.
29263847c39Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then
29363847c39Smrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
29463847c39Smrg`CONFIG_SITE' environment variable to the location of the site script.
29563847c39SmrgA warning: not all `configure' scripts look for a site script.
29663847c39Smrg
29763847c39SmrgDefining Variables
29863847c39Smrg==================
29963847c39Smrg
30063847c39Smrg   Variables not defined in a site shell script can be set in the
30163847c39Smrgenvironment passed to `configure'.  However, some packages may run
30263847c39Smrgconfigure again during the build, and the customized values of these
30363847c39Smrgvariables may be lost.  In order to avoid this problem, you should set
30463847c39Smrgthem in the `configure' command line, using `VAR=value'.  For example:
30563847c39Smrg
30663847c39Smrg     ./configure CC=/usr/local2/bin/gcc
30763847c39Smrg
30863847c39Smrgcauses the specified `gcc' to be used as the C compiler (unless it is
30963847c39Smrgoverridden in the site shell script).
31063847c39Smrg
31163847c39SmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
31263847c39Smrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
31363847c39Smrg
31463847c39Smrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
31563847c39Smrg
31663847c39Smrg`configure' Invocation
31763847c39Smrg======================
31863847c39Smrg
31963847c39Smrg   `configure' recognizes the following options to control how it
32063847c39Smrgoperates.
32163847c39Smrg
32263847c39Smrg`--help'
32363847c39Smrg`-h'
32463847c39Smrg     Print a summary of all of the options to `configure', and exit.
32563847c39Smrg
32663847c39Smrg`--help=short'
32763847c39Smrg`--help=recursive'
32863847c39Smrg     Print a summary of the options unique to this package's
32963847c39Smrg     `configure', and exit.  The `short' variant lists options used
33063847c39Smrg     only in the top level, while the `recursive' variant lists options
33163847c39Smrg     also present in any nested packages.
33263847c39Smrg
33363847c39Smrg`--version'
33463847c39Smrg`-V'
33563847c39Smrg     Print the version of Autoconf used to generate the `configure'
33663847c39Smrg     script, and exit.
33763847c39Smrg
33863847c39Smrg`--cache-file=FILE'
33963847c39Smrg     Enable the cache: use and save the results of the tests in FILE,
34063847c39Smrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
34163847c39Smrg     disable caching.
34263847c39Smrg
34363847c39Smrg`--config-cache'
34463847c39Smrg`-C'
34563847c39Smrg     Alias for `--cache-file=config.cache'.
34663847c39Smrg
34763847c39Smrg`--quiet'
34863847c39Smrg`--silent'
34963847c39Smrg`-q'
35063847c39Smrg     Do not print messages saying which checks are being made.  To
35163847c39Smrg     suppress all normal output, redirect it to `/dev/null' (any error
35263847c39Smrg     messages will still be shown).
35363847c39Smrg
35463847c39Smrg`--srcdir=DIR'
35563847c39Smrg     Look for the package's source code in directory DIR.  Usually
35663847c39Smrg     `configure' can determine that directory automatically.
35763847c39Smrg
35863847c39Smrg`--prefix=DIR'
3599586ba5aSmrg     Use DIR as the installation prefix.  *note Installation Names::
36063847c39Smrg     for more details, including other options available for fine-tuning
36163847c39Smrg     the installation locations.
36263847c39Smrg
36363847c39Smrg`--no-create'
36463847c39Smrg`-n'
36563847c39Smrg     Run the configure checks, but stop before creating any output
36663847c39Smrg     files.
36763847c39Smrg
36863847c39Smrg`configure' also accepts some other, not widely useful, options.  Run
36963847c39Smrg`configure --help' for more details.
37063847c39Smrg
371