19aa2a2b5SmrgInstallation Instructions
29aa2a2b5Smrg*************************
39aa2a2b5Smrg
4a9ba4257SmrgCopyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation,
5a9ba4257SmrgInc.
69aa2a2b5Smrg
7a9ba4257Smrg   Copying and distribution of this file, with or without modification,
8a9ba4257Smrgare permitted in any medium without royalty provided the copyright
9a9ba4257Smrgnotice and this notice are preserved.  This file is offered as-is,
10a9ba4257Smrgwithout warranty of any kind.
119aa2a2b5Smrg
129aa2a2b5SmrgBasic Installation
139aa2a2b5Smrg==================
149aa2a2b5Smrg
159aa2a2b5Smrg   Briefly, the shell commands `./configure; make; make install' should
169aa2a2b5Smrgconfigure, build, and install this package.  The following
179aa2a2b5Smrgmore-detailed instructions are generic; see the `README' file for
18a9ba4257Smrginstructions specific to this package.  Some packages provide this
19a9ba4257Smrg`INSTALL' file but do not implement all of the features documented
20a9ba4257Smrgbelow.  The lack of an optional feature in a given package is not
21a9ba4257Smrgnecessarily a bug.  More recommendations for GNU packages can be found
22a9ba4257Smrgin *note Makefile Conventions: (standards)Makefile Conventions.
239aa2a2b5Smrg
249aa2a2b5Smrg   The `configure' shell script attempts to guess correct values for
259aa2a2b5Smrgvarious system-dependent variables used during compilation.  It uses
269aa2a2b5Smrgthose values to create a `Makefile' in each directory of the package.
279aa2a2b5SmrgIt may also create one or more `.h' files containing system-dependent
289aa2a2b5Smrgdefinitions.  Finally, it creates a shell script `config.status' that
299aa2a2b5Smrgyou can run in the future to recreate the current configuration, and a
309aa2a2b5Smrgfile `config.log' containing compiler output (useful mainly for
319aa2a2b5Smrgdebugging `configure').
329aa2a2b5Smrg
339aa2a2b5Smrg   It can also use an optional file (typically called `config.cache'
349aa2a2b5Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
359aa2a2b5Smrgthe results of its tests to speed up reconfiguring.  Caching is
369aa2a2b5Smrgdisabled by default to prevent problems with accidental use of stale
379aa2a2b5Smrgcache files.
389aa2a2b5Smrg
399aa2a2b5Smrg   If you need to do unusual things to compile the package, please try
409aa2a2b5Smrgto figure out how `configure' could check whether to do them, and mail
419aa2a2b5Smrgdiffs or instructions to the address given in the `README' so they can
429aa2a2b5Smrgbe considered for the next release.  If you are using the cache, and at
439aa2a2b5Smrgsome point `config.cache' contains results you don't want to keep, you
449aa2a2b5Smrgmay remove or edit it.
459aa2a2b5Smrg
469aa2a2b5Smrg   The file `configure.ac' (or `configure.in') is used to create
479aa2a2b5Smrg`configure' by a program called `autoconf'.  You need `configure.ac' if
489aa2a2b5Smrgyou want to change it or regenerate `configure' using a newer version
499aa2a2b5Smrgof `autoconf'.
509aa2a2b5Smrg
51a9ba4257Smrg   The simplest way to compile this package is:
529aa2a2b5Smrg
539aa2a2b5Smrg  1. `cd' to the directory containing the package's source code and type
549aa2a2b5Smrg     `./configure' to configure the package for your system.
559aa2a2b5Smrg
569aa2a2b5Smrg     Running `configure' might take a while.  While running, it prints
579aa2a2b5Smrg     some messages telling which features it is checking for.
589aa2a2b5Smrg
599aa2a2b5Smrg  2. Type `make' to compile the package.
609aa2a2b5Smrg
619aa2a2b5Smrg  3. Optionally, type `make check' to run any self-tests that come with
62a9ba4257Smrg     the package, generally using the just-built uninstalled binaries.
639aa2a2b5Smrg
649aa2a2b5Smrg  4. Type `make install' to install the programs and any data files and
65a9ba4257Smrg     documentation.  When installing into a prefix owned by root, it is
66a9ba4257Smrg     recommended that the package be configured and built as a regular
67a9ba4257Smrg     user, and only the `make install' phase executed with root
68a9ba4257Smrg     privileges.
69a9ba4257Smrg
70a9ba4257Smrg  5. Optionally, type `make installcheck' to repeat any self-tests, but
71a9ba4257Smrg     this time using the binaries in their final installed location.
72a9ba4257Smrg     This target does not install anything.  Running this target as a
73a9ba4257Smrg     regular user, particularly if the prior `make install' required
74a9ba4257Smrg     root privileges, verifies that the installation completed
75a9ba4257Smrg     correctly.
76a9ba4257Smrg
77a9ba4257Smrg  6. You can remove the program binaries and object files from the
789aa2a2b5Smrg     source code directory by typing `make clean'.  To also remove the
799aa2a2b5Smrg     files that `configure' created (so you can compile the package for
809aa2a2b5Smrg     a different kind of computer), type `make distclean'.  There is
819aa2a2b5Smrg     also a `make maintainer-clean' target, but that is intended mainly
829aa2a2b5Smrg     for the package's developers.  If you use it, you may have to get
839aa2a2b5Smrg     all sorts of other programs in order to regenerate files that came
849aa2a2b5Smrg     with the distribution.
859aa2a2b5Smrg
86a9ba4257Smrg  7. Often, you can also type `make uninstall' to remove the installed
87a9ba4257Smrg     files again.  In practice, not all packages have tested that
88a9ba4257Smrg     uninstallation works correctly, even though it is required by the
89a9ba4257Smrg     GNU Coding Standards.
90a9ba4257Smrg
91a9ba4257Smrg  8. Some packages, particularly those that use Automake, provide `make
92a9ba4257Smrg     distcheck', which can by used by developers to test that all other
93a9ba4257Smrg     targets like `make install' and `make uninstall' work correctly.
94a9ba4257Smrg     This target is generally not run by end users.
959aa2a2b5Smrg
969aa2a2b5SmrgCompilers and Options
979aa2a2b5Smrg=====================
989aa2a2b5Smrg
999aa2a2b5Smrg   Some systems require unusual options for compilation or linking that
1009aa2a2b5Smrgthe `configure' script does not know about.  Run `./configure --help'
1019aa2a2b5Smrgfor details on some of the pertinent environment variables.
1029aa2a2b5Smrg
1039aa2a2b5Smrg   You can give `configure' initial values for configuration parameters
1049aa2a2b5Smrgby setting variables in the command line or in the environment.  Here
1059aa2a2b5Smrgis an example:
1069aa2a2b5Smrg
1079aa2a2b5Smrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
1089aa2a2b5Smrg
1099aa2a2b5Smrg   *Note Defining Variables::, for more details.
1109aa2a2b5Smrg
1119aa2a2b5SmrgCompiling For Multiple Architectures
1129aa2a2b5Smrg====================================
1139aa2a2b5Smrg
1149aa2a2b5Smrg   You can compile the package for more than one kind of computer at the
1159aa2a2b5Smrgsame time, by placing the object files for each architecture in their
1169aa2a2b5Smrgown directory.  To do this, you can use GNU `make'.  `cd' to the
1179aa2a2b5Smrgdirectory where you want the object files and executables to go and run
1189aa2a2b5Smrgthe `configure' script.  `configure' automatically checks for the
119a9ba4257Smrgsource code in the directory that `configure' is in and in `..'.  This
120a9ba4257Smrgis known as a "VPATH" build.
1219aa2a2b5Smrg
1229aa2a2b5Smrg   With a non-GNU `make', it is safer to compile the package for one
1239aa2a2b5Smrgarchitecture at a time in the source code directory.  After you have
1249aa2a2b5Smrginstalled the package for one architecture, use `make distclean' before
1259aa2a2b5Smrgreconfiguring for another architecture.
1269aa2a2b5Smrg
1279aa2a2b5Smrg   On MacOS X 10.5 and later systems, you can create libraries and
1289aa2a2b5Smrgexecutables that work on multiple system types--known as "fat" or
1299aa2a2b5Smrg"universal" binaries--by specifying multiple `-arch' options to the
1309aa2a2b5Smrgcompiler but only a single `-arch' option to the preprocessor.  Like
1319aa2a2b5Smrgthis:
1329aa2a2b5Smrg
1339aa2a2b5Smrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1349aa2a2b5Smrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1359aa2a2b5Smrg                 CPP="gcc -E" CXXCPP="g++ -E"
1369aa2a2b5Smrg
1379aa2a2b5Smrg   This is not guaranteed to produce working output in all cases, you
1389aa2a2b5Smrgmay have to build one architecture at a time and combine the results
1399aa2a2b5Smrgusing the `lipo' tool if you have problems.
1409aa2a2b5Smrg
1419aa2a2b5SmrgInstallation Names
1429aa2a2b5Smrg==================
1439aa2a2b5Smrg
1449aa2a2b5Smrg   By default, `make install' installs the package's commands under
1459aa2a2b5Smrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
1469aa2a2b5Smrgcan specify an installation prefix other than `/usr/local' by giving
147a9ba4257Smrg`configure' the option `--prefix=PREFIX', where PREFIX must be an
148a9ba4257Smrgabsolute file name.
1499aa2a2b5Smrg
1509aa2a2b5Smrg   You can specify separate installation prefixes for
1519aa2a2b5Smrgarchitecture-specific files and architecture-independent files.  If you
1529aa2a2b5Smrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
1539aa2a2b5SmrgPREFIX as the prefix for installing programs and libraries.
1549aa2a2b5SmrgDocumentation and other data files still use the regular prefix.
1559aa2a2b5Smrg
1569aa2a2b5Smrg   In addition, if you use an unusual directory layout you can give
1579aa2a2b5Smrgoptions like `--bindir=DIR' to specify different values for particular
1589aa2a2b5Smrgkinds of files.  Run `configure --help' for a list of the directories
159a9ba4257Smrgyou can set and what kinds of files go in them.  In general, the
160a9ba4257Smrgdefault for these options is expressed in terms of `${prefix}', so that
161a9ba4257Smrgspecifying just `--prefix' will affect all of the other directory
162a9ba4257Smrgspecifications that were not explicitly provided.
163a9ba4257Smrg
164a9ba4257Smrg   The most portable way to affect installation locations is to pass the
165a9ba4257Smrgcorrect locations to `configure'; however, many packages provide one or
166a9ba4257Smrgboth of the following shortcuts of passing variable assignments to the
167a9ba4257Smrg`make install' command line to change installation locations without
168a9ba4257Smrghaving to reconfigure or recompile.
169a9ba4257Smrg
170a9ba4257Smrg   The first method involves providing an override variable for each
171a9ba4257Smrgaffected directory.  For example, `make install
172a9ba4257Smrgprefix=/alternate/directory' will choose an alternate location for all
173a9ba4257Smrgdirectory configuration variables that were expressed in terms of
174a9ba4257Smrg`${prefix}'.  Any directories that were specified during `configure',
175a9ba4257Smrgbut not in terms of `${prefix}', must each be overridden at install
176a9ba4257Smrgtime for the entire installation to be relocated.  The approach of
177a9ba4257Smrgmakefile variable overrides for each directory variable is required by
178a9ba4257Smrgthe GNU Coding Standards, and ideally causes no recompilation.
179a9ba4257SmrgHowever, some platforms have known limitations with the semantics of
180a9ba4257Smrgshared libraries that end up requiring recompilation when using this
181a9ba4257Smrgmethod, particularly noticeable in packages that use GNU Libtool.
182a9ba4257Smrg
183a9ba4257Smrg   The second method involves providing the `DESTDIR' variable.  For
184a9ba4257Smrgexample, `make install DESTDIR=/alternate/directory' will prepend
185a9ba4257Smrg`/alternate/directory' before all installation names.  The approach of
186a9ba4257Smrg`DESTDIR' overrides is not required by the GNU Coding Standards, and
187a9ba4257Smrgdoes not work on platforms that have drive letters.  On the other hand,
188a9ba4257Smrgit does better at avoiding recompilation issues, and works well even
189a9ba4257Smrgwhen some directory options were not specified in terms of `${prefix}'
190a9ba4257Smrgat `configure' time.
191a9ba4257Smrg
192a9ba4257SmrgOptional Features
193a9ba4257Smrg=================
1949aa2a2b5Smrg
1959aa2a2b5Smrg   If the package supports it, you can cause programs to be installed
1969aa2a2b5Smrgwith an extra prefix or suffix on their names by giving `configure' the
1979aa2a2b5Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
1989aa2a2b5Smrg
1999aa2a2b5Smrg   Some packages pay attention to `--enable-FEATURE' options to
2009aa2a2b5Smrg`configure', where FEATURE indicates an optional part of the package.
2019aa2a2b5SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
2029aa2a2b5Smrgis something like `gnu-as' or `x' (for the X Window System).  The
2039aa2a2b5Smrg`README' should mention any `--enable-' and `--with-' options that the
2049aa2a2b5Smrgpackage recognizes.
2059aa2a2b5Smrg
2069aa2a2b5Smrg   For packages that use the X Window System, `configure' can usually
2079aa2a2b5Smrgfind the X include and library files automatically, but if it doesn't,
2089aa2a2b5Smrgyou can use the `configure' options `--x-includes=DIR' and
2099aa2a2b5Smrg`--x-libraries=DIR' to specify their locations.
2109aa2a2b5Smrg
211a9ba4257Smrg   Some packages offer the ability to configure how verbose the
212a9ba4257Smrgexecution of `make' will be.  For these packages, running `./configure
213a9ba4257Smrg--enable-silent-rules' sets the default to minimal output, which can be
214a9ba4257Smrgoverridden with `make V=1'; while running `./configure
215a9ba4257Smrg--disable-silent-rules' sets the default to verbose, which can be
216a9ba4257Smrgoverridden with `make V=0'.
217a9ba4257Smrg
2189aa2a2b5SmrgParticular systems
2199aa2a2b5Smrg==================
2209aa2a2b5Smrg
2219aa2a2b5Smrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
2229aa2a2b5SmrgCC is not installed, it is recommended to use the following options in
2239aa2a2b5Smrgorder to use an ANSI C compiler:
2249aa2a2b5Smrg
225a9ba4257Smrg     ./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
2269aa2a2b5Smrg
2279aa2a2b5Smrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
2289aa2a2b5Smrg
229a9ba4257Smrg   HP-UX `make' updates targets which have the same time stamps as
230a9ba4257Smrgtheir prerequisites, which makes it generally unusable when shipped
231a9ba4257Smrggenerated files such as `configure' are involved.  Use GNU `make'
232a9ba4257Smrginstead.
233a9ba4257Smrg
2349aa2a2b5Smrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
2359aa2a2b5Smrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
2369aa2a2b5Smrga workaround.  If GNU CC is not installed, it is therefore recommended
2379aa2a2b5Smrgto try
2389aa2a2b5Smrg
2399aa2a2b5Smrg     ./configure CC="cc"
2409aa2a2b5Smrg
2419aa2a2b5Smrgand if that doesn't work, try
2429aa2a2b5Smrg
2439aa2a2b5Smrg     ./configure CC="cc -nodtk"
2449aa2a2b5Smrg
245a9ba4257Smrg   On Solaris, don't put `/usr/ucb' early in your `PATH'.  This
246a9ba4257Smrgdirectory contains several dysfunctional programs; working variants of
247a9ba4257Smrgthese programs are available in `/usr/bin'.  So, if you need `/usr/ucb'
248a9ba4257Smrgin your `PATH', put it _after_ `/usr/bin'.
249a9ba4257Smrg
250a9ba4257Smrg   On Haiku, software installed for all users goes in `/boot/common',
251a9ba4257Smrgnot `/usr/local'.  It is recommended to use the following options:
252a9ba4257Smrg
253a9ba4257Smrg     ./configure --prefix=/boot/common
254a9ba4257Smrg
2559aa2a2b5SmrgSpecifying the System Type
2569aa2a2b5Smrg==========================
2579aa2a2b5Smrg
2589aa2a2b5Smrg   There may be some features `configure' cannot figure out
2599aa2a2b5Smrgautomatically, but needs to determine by the type of machine the package
2609aa2a2b5Smrgwill run on.  Usually, assuming the package is built to be run on the
2619aa2a2b5Smrg_same_ architectures, `configure' can figure that out, but if it prints
2629aa2a2b5Smrga message saying it cannot guess the machine type, give it the
2639aa2a2b5Smrg`--build=TYPE' option.  TYPE can either be a short name for the system
2649aa2a2b5Smrgtype, such as `sun4', or a canonical name which has the form:
2659aa2a2b5Smrg
2669aa2a2b5Smrg     CPU-COMPANY-SYSTEM
2679aa2a2b5Smrg
2689aa2a2b5Smrgwhere SYSTEM can have one of these forms:
2699aa2a2b5Smrg
270a9ba4257Smrg     OS
271a9ba4257Smrg     KERNEL-OS
2729aa2a2b5Smrg
2739aa2a2b5Smrg   See the file `config.sub' for the possible values of each field.  If
2749aa2a2b5Smrg`config.sub' isn't included in this package, then this package doesn't
2759aa2a2b5Smrgneed to know the machine type.
2769aa2a2b5Smrg
2779aa2a2b5Smrg   If you are _building_ compiler tools for cross-compiling, you should
2789aa2a2b5Smrguse the option `--target=TYPE' to select the type of system they will
2799aa2a2b5Smrgproduce code for.
2809aa2a2b5Smrg
2819aa2a2b5Smrg   If you want to _use_ a cross compiler, that generates code for a
2829aa2a2b5Smrgplatform different from the build platform, you should specify the
2839aa2a2b5Smrg"host" platform (i.e., that on which the generated programs will
2849aa2a2b5Smrgeventually be run) with `--host=TYPE'.
2859aa2a2b5Smrg
2869aa2a2b5SmrgSharing Defaults
2879aa2a2b5Smrg================
2889aa2a2b5Smrg
2899aa2a2b5Smrg   If you want to set default values for `configure' scripts to share,
2909aa2a2b5Smrgyou can create a site shell script called `config.site' that gives
2919aa2a2b5Smrgdefault values for variables like `CC', `cache_file', and `prefix'.
2929aa2a2b5Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then
2939aa2a2b5Smrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
2949aa2a2b5Smrg`CONFIG_SITE' environment variable to the location of the site script.
2959aa2a2b5SmrgA warning: not all `configure' scripts look for a site script.
2969aa2a2b5Smrg
2979aa2a2b5SmrgDefining Variables
2989aa2a2b5Smrg==================
2999aa2a2b5Smrg
3009aa2a2b5Smrg   Variables not defined in a site shell script can be set in the
3019aa2a2b5Smrgenvironment passed to `configure'.  However, some packages may run
3029aa2a2b5Smrgconfigure again during the build, and the customized values of these
3039aa2a2b5Smrgvariables may be lost.  In order to avoid this problem, you should set
3049aa2a2b5Smrgthem in the `configure' command line, using `VAR=value'.  For example:
3059aa2a2b5Smrg
3069aa2a2b5Smrg     ./configure CC=/usr/local2/bin/gcc
3079aa2a2b5Smrg
3089aa2a2b5Smrgcauses the specified `gcc' to be used as the C compiler (unless it is
3099aa2a2b5Smrgoverridden in the site shell script).
3109aa2a2b5Smrg
3119aa2a2b5SmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
3129aa2a2b5Smrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
3139aa2a2b5Smrg
3149aa2a2b5Smrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
3159aa2a2b5Smrg
3169aa2a2b5Smrg`configure' Invocation
3179aa2a2b5Smrg======================
3189aa2a2b5Smrg
3199aa2a2b5Smrg   `configure' recognizes the following options to control how it
3209aa2a2b5Smrgoperates.
3219aa2a2b5Smrg
3229aa2a2b5Smrg`--help'
3239aa2a2b5Smrg`-h'
3249aa2a2b5Smrg     Print a summary of all of the options to `configure', and exit.
3259aa2a2b5Smrg
3269aa2a2b5Smrg`--help=short'
3279aa2a2b5Smrg`--help=recursive'
3289aa2a2b5Smrg     Print a summary of the options unique to this package's
3299aa2a2b5Smrg     `configure', and exit.  The `short' variant lists options used
3309aa2a2b5Smrg     only in the top level, while the `recursive' variant lists options
3319aa2a2b5Smrg     also present in any nested packages.
3329aa2a2b5Smrg
3339aa2a2b5Smrg`--version'
3349aa2a2b5Smrg`-V'
3359aa2a2b5Smrg     Print the version of Autoconf used to generate the `configure'
3369aa2a2b5Smrg     script, and exit.
3379aa2a2b5Smrg
3389aa2a2b5Smrg`--cache-file=FILE'
3399aa2a2b5Smrg     Enable the cache: use and save the results of the tests in FILE,
3409aa2a2b5Smrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
3419aa2a2b5Smrg     disable caching.
3429aa2a2b5Smrg
3439aa2a2b5Smrg`--config-cache'
3449aa2a2b5Smrg`-C'
3459aa2a2b5Smrg     Alias for `--cache-file=config.cache'.
3469aa2a2b5Smrg
3479aa2a2b5Smrg`--quiet'
3489aa2a2b5Smrg`--silent'
3499aa2a2b5Smrg`-q'
3509aa2a2b5Smrg     Do not print messages saying which checks are being made.  To
3519aa2a2b5Smrg     suppress all normal output, redirect it to `/dev/null' (any error
3529aa2a2b5Smrg     messages will still be shown).
3539aa2a2b5Smrg
3549aa2a2b5Smrg`--srcdir=DIR'
3559aa2a2b5Smrg     Look for the package's source code in directory DIR.  Usually
3569aa2a2b5Smrg     `configure' can determine that directory automatically.
3579aa2a2b5Smrg
3589aa2a2b5Smrg`--prefix=DIR'
359a9ba4257Smrg     Use DIR as the installation prefix.  *note Installation Names::
3609aa2a2b5Smrg     for more details, including other options available for fine-tuning
3619aa2a2b5Smrg     the installation locations.
3629aa2a2b5Smrg
3639aa2a2b5Smrg`--no-create'
3649aa2a2b5Smrg`-n'
3659aa2a2b5Smrg     Run the configure checks, but stop before creating any output
3669aa2a2b5Smrg     files.
3679aa2a2b5Smrg
3689aa2a2b5Smrg`configure' also accepts some other, not widely useful, options.  Run
3699aa2a2b5Smrg`configure --help' for more details.
3709aa2a2b5Smrg
371