11cca5e29SmrgInstallation Instructions
21cca5e29Smrg*************************
31cca5e29Smrg
41cca5e29SmrgCopyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
51cca5e29Smrg2006, 2007, 2008 Free Software Foundation, Inc.
61cca5e29Smrg
71cca5e29Smrg   This file is free documentation; the Free Software Foundation gives
81cca5e29Smrgunlimited permission to copy, distribute and modify it.
91cca5e29Smrg
101cca5e29SmrgBasic Installation
111cca5e29Smrg==================
121cca5e29Smrg
131cca5e29Smrg   Briefly, the shell commands `./configure; make; make install' should
141cca5e29Smrgconfigure, build, and install this package.  The following
151cca5e29Smrgmore-detailed instructions are generic; see the `README' file for
161cca5e29Smrginstructions specific to this package.
171cca5e29Smrg
181cca5e29Smrg   The `configure' shell script attempts to guess correct values for
191cca5e29Smrgvarious system-dependent variables used during compilation.  It uses
201cca5e29Smrgthose values to create a `Makefile' in each directory of the package.
211cca5e29SmrgIt may also create one or more `.h' files containing system-dependent
221cca5e29Smrgdefinitions.  Finally, it creates a shell script `config.status' that
231cca5e29Smrgyou can run in the future to recreate the current configuration, and a
241cca5e29Smrgfile `config.log' containing compiler output (useful mainly for
251cca5e29Smrgdebugging `configure').
261cca5e29Smrg
271cca5e29Smrg   It can also use an optional file (typically called `config.cache'
281cca5e29Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
291cca5e29Smrgthe results of its tests to speed up reconfiguring.  Caching is
301cca5e29Smrgdisabled by default to prevent problems with accidental use of stale
311cca5e29Smrgcache files.
321cca5e29Smrg
331cca5e29Smrg   If you need to do unusual things to compile the package, please try
341cca5e29Smrgto figure out how `configure' could check whether to do them, and mail
351cca5e29Smrgdiffs or instructions to the address given in the `README' so they can
361cca5e29Smrgbe considered for the next release.  If you are using the cache, and at
371cca5e29Smrgsome point `config.cache' contains results you don't want to keep, you
381cca5e29Smrgmay remove or edit it.
391cca5e29Smrg
401cca5e29Smrg   The file `configure.ac' (or `configure.in') is used to create
411cca5e29Smrg`configure' by a program called `autoconf'.  You need `configure.ac' if
421cca5e29Smrgyou want to change it or regenerate `configure' using a newer version
431cca5e29Smrgof `autoconf'.
441cca5e29Smrg
451cca5e29SmrgThe simplest way to compile this package is:
461cca5e29Smrg
471cca5e29Smrg  1. `cd' to the directory containing the package's source code and type
481cca5e29Smrg     `./configure' to configure the package for your system.
491cca5e29Smrg
501cca5e29Smrg     Running `configure' might take a while.  While running, it prints
511cca5e29Smrg     some messages telling which features it is checking for.
521cca5e29Smrg
531cca5e29Smrg  2. Type `make' to compile the package.
541cca5e29Smrg
551cca5e29Smrg  3. Optionally, type `make check' to run any self-tests that come with
561cca5e29Smrg     the package.
571cca5e29Smrg
581cca5e29Smrg  4. Type `make install' to install the programs and any data files and
591cca5e29Smrg     documentation.
601cca5e29Smrg
611cca5e29Smrg  5. You can remove the program binaries and object files from the
621cca5e29Smrg     source code directory by typing `make clean'.  To also remove the
631cca5e29Smrg     files that `configure' created (so you can compile the package for
641cca5e29Smrg     a different kind of computer), type `make distclean'.  There is
651cca5e29Smrg     also a `make maintainer-clean' target, but that is intended mainly
661cca5e29Smrg     for the package's developers.  If you use it, you may have to get
671cca5e29Smrg     all sorts of other programs in order to regenerate files that came
681cca5e29Smrg     with the distribution.
691cca5e29Smrg
701cca5e29Smrg  6. Often, you can also type `make uninstall' to remove the installed
711cca5e29Smrg     files again.
721cca5e29Smrg
731cca5e29SmrgCompilers and Options
741cca5e29Smrg=====================
751cca5e29Smrg
761cca5e29Smrg   Some systems require unusual options for compilation or linking that
771cca5e29Smrgthe `configure' script does not know about.  Run `./configure --help'
781cca5e29Smrgfor details on some of the pertinent environment variables.
791cca5e29Smrg
801cca5e29Smrg   You can give `configure' initial values for configuration parameters
811cca5e29Smrgby setting variables in the command line or in the environment.  Here
821cca5e29Smrgis an example:
831cca5e29Smrg
841cca5e29Smrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
851cca5e29Smrg
861cca5e29Smrg   *Note Defining Variables::, for more details.
871cca5e29Smrg
881cca5e29SmrgCompiling For Multiple Architectures
891cca5e29Smrg====================================
901cca5e29Smrg
911cca5e29Smrg   You can compile the package for more than one kind of computer at the
921cca5e29Smrgsame time, by placing the object files for each architecture in their
931cca5e29Smrgown directory.  To do this, you can use GNU `make'.  `cd' to the
941cca5e29Smrgdirectory where you want the object files and executables to go and run
951cca5e29Smrgthe `configure' script.  `configure' automatically checks for the
961cca5e29Smrgsource code in the directory that `configure' is in and in `..'.
971cca5e29Smrg
981cca5e29Smrg   With a non-GNU `make', it is safer to compile the package for one
991cca5e29Smrgarchitecture at a time in the source code directory.  After you have
1001cca5e29Smrginstalled the package for one architecture, use `make distclean' before
1011cca5e29Smrgreconfiguring for another architecture.
1021cca5e29Smrg
1031cca5e29Smrg   On MacOS X 10.5 and later systems, you can create libraries and
1041cca5e29Smrgexecutables that work on multiple system types--known as "fat" or
1051cca5e29Smrg"universal" binaries--by specifying multiple `-arch' options to the
1061cca5e29Smrgcompiler but only a single `-arch' option to the preprocessor.  Like
1071cca5e29Smrgthis:
1081cca5e29Smrg
1091cca5e29Smrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1101cca5e29Smrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1111cca5e29Smrg                 CPP="gcc -E" CXXCPP="g++ -E"
1121cca5e29Smrg
1131cca5e29Smrg   This is not guaranteed to produce working output in all cases, you
1141cca5e29Smrgmay have to build one architecture at a time and combine the results
1151cca5e29Smrgusing the `lipo' tool if you have problems.
1161cca5e29Smrg
1171cca5e29SmrgInstallation Names
1181cca5e29Smrg==================
1191cca5e29Smrg
1201cca5e29Smrg   By default, `make install' installs the package's commands under
1211cca5e29Smrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
1221cca5e29Smrgcan specify an installation prefix other than `/usr/local' by giving
1231cca5e29Smrg`configure' the option `--prefix=PREFIX'.
1241cca5e29Smrg
1251cca5e29Smrg   You can specify separate installation prefixes for
1261cca5e29Smrgarchitecture-specific files and architecture-independent files.  If you
1271cca5e29Smrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
1281cca5e29SmrgPREFIX as the prefix for installing programs and libraries.
1291cca5e29SmrgDocumentation and other data files still use the regular prefix.
1301cca5e29Smrg
1311cca5e29Smrg   In addition, if you use an unusual directory layout you can give
1321cca5e29Smrgoptions like `--bindir=DIR' to specify different values for particular
1331cca5e29Smrgkinds of files.  Run `configure --help' for a list of the directories
1341cca5e29Smrgyou can set and what kinds of files go in them.
1351cca5e29Smrg
1361cca5e29Smrg   If the package supports it, you can cause programs to be installed
1371cca5e29Smrgwith an extra prefix or suffix on their names by giving `configure' the
1381cca5e29Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
1391cca5e29Smrg
1401cca5e29SmrgOptional Features
1411cca5e29Smrg=================
1421cca5e29Smrg
1431cca5e29Smrg   Some packages pay attention to `--enable-FEATURE' options to
1441cca5e29Smrg`configure', where FEATURE indicates an optional part of the package.
1451cca5e29SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
1461cca5e29Smrgis something like `gnu-as' or `x' (for the X Window System).  The
1471cca5e29Smrg`README' should mention any `--enable-' and `--with-' options that the
1481cca5e29Smrgpackage recognizes.
1491cca5e29Smrg
1501cca5e29Smrg   For packages that use the X Window System, `configure' can usually
1511cca5e29Smrgfind the X include and library files automatically, but if it doesn't,
1521cca5e29Smrgyou can use the `configure' options `--x-includes=DIR' and
1531cca5e29Smrg`--x-libraries=DIR' to specify their locations.
1541cca5e29Smrg
1551cca5e29SmrgParticular systems
1561cca5e29Smrg==================
1571cca5e29Smrg
1581cca5e29Smrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
1591cca5e29SmrgCC is not installed, it is recommended to use the following options in
1601cca5e29Smrgorder to use an ANSI C compiler:
1611cca5e29Smrg
1621cca5e29Smrg     ./configure CC="cc -Ae"
1631cca5e29Smrg
1641cca5e29Smrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
1651cca5e29Smrg
1661cca5e29Smrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
1671cca5e29Smrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
1681cca5e29Smrga workaround.  If GNU CC is not installed, it is therefore recommended
1691cca5e29Smrgto try
1701cca5e29Smrg
1711cca5e29Smrg     ./configure CC="cc"
1721cca5e29Smrg
1731cca5e29Smrgand if that doesn't work, try
1741cca5e29Smrg
1751cca5e29Smrg     ./configure CC="cc -nodtk"
1761cca5e29Smrg
1771cca5e29SmrgSpecifying the System Type
1781cca5e29Smrg==========================
1791cca5e29Smrg
1801cca5e29Smrg   There may be some features `configure' cannot figure out
1811cca5e29Smrgautomatically, but needs to determine by the type of machine the package
1821cca5e29Smrgwill run on.  Usually, assuming the package is built to be run on the
1831cca5e29Smrg_same_ architectures, `configure' can figure that out, but if it prints
1841cca5e29Smrga message saying it cannot guess the machine type, give it the
1851cca5e29Smrg`--build=TYPE' option.  TYPE can either be a short name for the system
1861cca5e29Smrgtype, such as `sun4', or a canonical name which has the form:
1871cca5e29Smrg
1881cca5e29Smrg     CPU-COMPANY-SYSTEM
1891cca5e29Smrg
1901cca5e29Smrgwhere SYSTEM can have one of these forms:
1911cca5e29Smrg
1921cca5e29Smrg     OS KERNEL-OS
1931cca5e29Smrg
1941cca5e29Smrg   See the file `config.sub' for the possible values of each field.  If
1951cca5e29Smrg`config.sub' isn't included in this package, then this package doesn't
1961cca5e29Smrgneed to know the machine type.
1971cca5e29Smrg
1981cca5e29Smrg   If you are _building_ compiler tools for cross-compiling, you should
1991cca5e29Smrguse the option `--target=TYPE' to select the type of system they will
2001cca5e29Smrgproduce code for.
2011cca5e29Smrg
2021cca5e29Smrg   If you want to _use_ a cross compiler, that generates code for a
2031cca5e29Smrgplatform different from the build platform, you should specify the
2041cca5e29Smrg"host" platform (i.e., that on which the generated programs will
2051cca5e29Smrgeventually be run) with `--host=TYPE'.
2061cca5e29Smrg
2071cca5e29SmrgSharing Defaults
2081cca5e29Smrg================
2091cca5e29Smrg
2101cca5e29Smrg   If you want to set default values for `configure' scripts to share,
2111cca5e29Smrgyou can create a site shell script called `config.site' that gives
2121cca5e29Smrgdefault values for variables like `CC', `cache_file', and `prefix'.
2131cca5e29Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then
2141cca5e29Smrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
2151cca5e29Smrg`CONFIG_SITE' environment variable to the location of the site script.
2161cca5e29SmrgA warning: not all `configure' scripts look for a site script.
2171cca5e29Smrg
2181cca5e29SmrgDefining Variables
2191cca5e29Smrg==================
2201cca5e29Smrg
2211cca5e29Smrg   Variables not defined in a site shell script can be set in the
2221cca5e29Smrgenvironment passed to `configure'.  However, some packages may run
2231cca5e29Smrgconfigure again during the build, and the customized values of these
2241cca5e29Smrgvariables may be lost.  In order to avoid this problem, you should set
2251cca5e29Smrgthem in the `configure' command line, using `VAR=value'.  For example:
2261cca5e29Smrg
2271cca5e29Smrg     ./configure CC=/usr/local2/bin/gcc
2281cca5e29Smrg
2291cca5e29Smrgcauses the specified `gcc' to be used as the C compiler (unless it is
2301cca5e29Smrgoverridden in the site shell script).
2311cca5e29Smrg
2321cca5e29SmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
2331cca5e29Smrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
2341cca5e29Smrg
2351cca5e29Smrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
2361cca5e29Smrg
2371cca5e29Smrg`configure' Invocation
2381cca5e29Smrg======================
2391cca5e29Smrg
2401cca5e29Smrg   `configure' recognizes the following options to control how it
2411cca5e29Smrgoperates.
2421cca5e29Smrg
2431cca5e29Smrg`--help'
2441cca5e29Smrg`-h'
2451cca5e29Smrg     Print a summary of all of the options to `configure', and exit.
2461cca5e29Smrg
2471cca5e29Smrg`--help=short'
2481cca5e29Smrg`--help=recursive'
2491cca5e29Smrg     Print a summary of the options unique to this package's
2501cca5e29Smrg     `configure', and exit.  The `short' variant lists options used
2511cca5e29Smrg     only in the top level, while the `recursive' variant lists options
2521cca5e29Smrg     also present in any nested packages.
2531cca5e29Smrg
2541cca5e29Smrg`--version'
2551cca5e29Smrg`-V'
2561cca5e29Smrg     Print the version of Autoconf used to generate the `configure'
2571cca5e29Smrg     script, and exit.
2581cca5e29Smrg
2591cca5e29Smrg`--cache-file=FILE'
2601cca5e29Smrg     Enable the cache: use and save the results of the tests in FILE,
2611cca5e29Smrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
2621cca5e29Smrg     disable caching.
2631cca5e29Smrg
2641cca5e29Smrg`--config-cache'
2651cca5e29Smrg`-C'
2661cca5e29Smrg     Alias for `--cache-file=config.cache'.
2671cca5e29Smrg
2681cca5e29Smrg`--quiet'
2691cca5e29Smrg`--silent'
2701cca5e29Smrg`-q'
2711cca5e29Smrg     Do not print messages saying which checks are being made.  To
2721cca5e29Smrg     suppress all normal output, redirect it to `/dev/null' (any error
2731cca5e29Smrg     messages will still be shown).
2741cca5e29Smrg
2751cca5e29Smrg`--srcdir=DIR'
2761cca5e29Smrg     Look for the package's source code in directory DIR.  Usually
2771cca5e29Smrg     `configure' can determine that directory automatically.
2781cca5e29Smrg
2791cca5e29Smrg`--prefix=DIR'
2801cca5e29Smrg     Use DIR as the installation prefix.  *Note Installation Names::
2811cca5e29Smrg     for more details, including other options available for fine-tuning
2821cca5e29Smrg     the installation locations.
2831cca5e29Smrg
2841cca5e29Smrg`--no-create'
2851cca5e29Smrg`-n'
2861cca5e29Smrg     Run the configure checks, but stop before creating any output
2871cca5e29Smrg     files.
2881cca5e29Smrg
2891cca5e29Smrg`configure' also accepts some other, not widely useful, options.  Run
2901cca5e29Smrg`configure --help' for more details.
2911cca5e29Smrg
292