INSTALL revision 7a2631fc
17a2631fcSmrgInstallation Instructions
27a2631fcSmrg*************************
37a2631fcSmrg
47a2631fcSmrgCopyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
57a2631fcSmrg2006, 2007, 2008 Free Software Foundation, Inc.
67a2631fcSmrg
77a2631fcSmrg   This file is free documentation; the Free Software Foundation gives
87a2631fcSmrgunlimited permission to copy, distribute and modify it.
97a2631fcSmrg
107a2631fcSmrgBasic Installation
117a2631fcSmrg==================
127a2631fcSmrg
137a2631fcSmrg   Briefly, the shell commands `./configure; make; make install' should
147a2631fcSmrgconfigure, build, and install this package.  The following
157a2631fcSmrgmore-detailed instructions are generic; see the `README' file for
167a2631fcSmrginstructions specific to this package.
177a2631fcSmrg
187a2631fcSmrg   The `configure' shell script attempts to guess correct values for
197a2631fcSmrgvarious system-dependent variables used during compilation.  It uses
207a2631fcSmrgthose values to create a `Makefile' in each directory of the package.
217a2631fcSmrgIt may also create one or more `.h' files containing system-dependent
227a2631fcSmrgdefinitions.  Finally, it creates a shell script `config.status' that
237a2631fcSmrgyou can run in the future to recreate the current configuration, and a
247a2631fcSmrgfile `config.log' containing compiler output (useful mainly for
257a2631fcSmrgdebugging `configure').
267a2631fcSmrg
277a2631fcSmrg   It can also use an optional file (typically called `config.cache'
287a2631fcSmrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
297a2631fcSmrgthe results of its tests to speed up reconfiguring.  Caching is
307a2631fcSmrgdisabled by default to prevent problems with accidental use of stale
317a2631fcSmrgcache files.
327a2631fcSmrg
337a2631fcSmrg   If you need to do unusual things to compile the package, please try
347a2631fcSmrgto figure out how `configure' could check whether to do them, and mail
357a2631fcSmrgdiffs or instructions to the address given in the `README' so they can
367a2631fcSmrgbe considered for the next release.  If you are using the cache, and at
377a2631fcSmrgsome point `config.cache' contains results you don't want to keep, you
387a2631fcSmrgmay remove or edit it.
397a2631fcSmrg
407a2631fcSmrg   The file `configure.ac' (or `configure.in') is used to create
417a2631fcSmrg`configure' by a program called `autoconf'.  You need `configure.ac' if
427a2631fcSmrgyou want to change it or regenerate `configure' using a newer version
437a2631fcSmrgof `autoconf'.
447a2631fcSmrg
457a2631fcSmrgThe simplest way to compile this package is:
467a2631fcSmrg
477a2631fcSmrg  1. `cd' to the directory containing the package's source code and type
487a2631fcSmrg     `./configure' to configure the package for your system.
497a2631fcSmrg
507a2631fcSmrg     Running `configure' might take a while.  While running, it prints
517a2631fcSmrg     some messages telling which features it is checking for.
527a2631fcSmrg
537a2631fcSmrg  2. Type `make' to compile the package.
547a2631fcSmrg
557a2631fcSmrg  3. Optionally, type `make check' to run any self-tests that come with
567a2631fcSmrg     the package.
577a2631fcSmrg
587a2631fcSmrg  4. Type `make install' to install the programs and any data files and
597a2631fcSmrg     documentation.
607a2631fcSmrg
617a2631fcSmrg  5. You can remove the program binaries and object files from the
627a2631fcSmrg     source code directory by typing `make clean'.  To also remove the
637a2631fcSmrg     files that `configure' created (so you can compile the package for
647a2631fcSmrg     a different kind of computer), type `make distclean'.  There is
657a2631fcSmrg     also a `make maintainer-clean' target, but that is intended mainly
667a2631fcSmrg     for the package's developers.  If you use it, you may have to get
677a2631fcSmrg     all sorts of other programs in order to regenerate files that came
687a2631fcSmrg     with the distribution.
697a2631fcSmrg
707a2631fcSmrg  6. Often, you can also type `make uninstall' to remove the installed
717a2631fcSmrg     files again.
727a2631fcSmrg
737a2631fcSmrgCompilers and Options
747a2631fcSmrg=====================
757a2631fcSmrg
767a2631fcSmrg   Some systems require unusual options for compilation or linking that
777a2631fcSmrgthe `configure' script does not know about.  Run `./configure --help'
787a2631fcSmrgfor details on some of the pertinent environment variables.
797a2631fcSmrg
807a2631fcSmrg   You can give `configure' initial values for configuration parameters
817a2631fcSmrgby setting variables in the command line or in the environment.  Here
827a2631fcSmrgis an example:
837a2631fcSmrg
847a2631fcSmrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
857a2631fcSmrg
867a2631fcSmrg   *Note Defining Variables::, for more details.
877a2631fcSmrg
887a2631fcSmrgCompiling For Multiple Architectures
897a2631fcSmrg====================================
907a2631fcSmrg
917a2631fcSmrg   You can compile the package for more than one kind of computer at the
927a2631fcSmrgsame time, by placing the object files for each architecture in their
937a2631fcSmrgown directory.  To do this, you can use GNU `make'.  `cd' to the
947a2631fcSmrgdirectory where you want the object files and executables to go and run
957a2631fcSmrgthe `configure' script.  `configure' automatically checks for the
967a2631fcSmrgsource code in the directory that `configure' is in and in `..'.
977a2631fcSmrg
987a2631fcSmrg   With a non-GNU `make', it is safer to compile the package for one
997a2631fcSmrgarchitecture at a time in the source code directory.  After you have
1007a2631fcSmrginstalled the package for one architecture, use `make distclean' before
1017a2631fcSmrgreconfiguring for another architecture.
1027a2631fcSmrg
1037a2631fcSmrg   On MacOS X 10.5 and later systems, you can create libraries and
1047a2631fcSmrgexecutables that work on multiple system types--known as "fat" or
1057a2631fcSmrg"universal" binaries--by specifying multiple `-arch' options to the
1067a2631fcSmrgcompiler but only a single `-arch' option to the preprocessor.  Like
1077a2631fcSmrgthis:
1087a2631fcSmrg
1097a2631fcSmrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1107a2631fcSmrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1117a2631fcSmrg                 CPP="gcc -E" CXXCPP="g++ -E"
1127a2631fcSmrg
1137a2631fcSmrg   This is not guaranteed to produce working output in all cases, you
1147a2631fcSmrgmay have to build one architecture at a time and combine the results
1157a2631fcSmrgusing the `lipo' tool if you have problems.
1167a2631fcSmrg
1177a2631fcSmrgInstallation Names
1187a2631fcSmrg==================
1197a2631fcSmrg
1207a2631fcSmrg   By default, `make install' installs the package's commands under
1217a2631fcSmrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
1227a2631fcSmrgcan specify an installation prefix other than `/usr/local' by giving
1237a2631fcSmrg`configure' the option `--prefix=PREFIX'.
1247a2631fcSmrg
1257a2631fcSmrg   You can specify separate installation prefixes for
1267a2631fcSmrgarchitecture-specific files and architecture-independent files.  If you
1277a2631fcSmrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
1287a2631fcSmrgPREFIX as the prefix for installing programs and libraries.
1297a2631fcSmrgDocumentation and other data files still use the regular prefix.
1307a2631fcSmrg
1317a2631fcSmrg   In addition, if you use an unusual directory layout you can give
1327a2631fcSmrgoptions like `--bindir=DIR' to specify different values for particular
1337a2631fcSmrgkinds of files.  Run `configure --help' for a list of the directories
1347a2631fcSmrgyou can set and what kinds of files go in them.
1357a2631fcSmrg
1367a2631fcSmrg   If the package supports it, you can cause programs to be installed
1377a2631fcSmrgwith an extra prefix or suffix on their names by giving `configure' the
1387a2631fcSmrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
1397a2631fcSmrg
1407a2631fcSmrgOptional Features
1417a2631fcSmrg=================
1427a2631fcSmrg
1437a2631fcSmrg   Some packages pay attention to `--enable-FEATURE' options to
1447a2631fcSmrg`configure', where FEATURE indicates an optional part of the package.
1457a2631fcSmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
1467a2631fcSmrgis something like `gnu-as' or `x' (for the X Window System).  The
1477a2631fcSmrg`README' should mention any `--enable-' and `--with-' options that the
1487a2631fcSmrgpackage recognizes.
1497a2631fcSmrg
1507a2631fcSmrg   For packages that use the X Window System, `configure' can usually
1517a2631fcSmrgfind the X include and library files automatically, but if it doesn't,
1527a2631fcSmrgyou can use the `configure' options `--x-includes=DIR' and
1537a2631fcSmrg`--x-libraries=DIR' to specify their locations.
1547a2631fcSmrg
1557a2631fcSmrgParticular systems
1567a2631fcSmrg==================
1577a2631fcSmrg
1587a2631fcSmrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
1597a2631fcSmrgCC is not installed, it is recommended to use the following options in
1607a2631fcSmrgorder to use an ANSI C compiler:
1617a2631fcSmrg
1627a2631fcSmrg     ./configure CC="cc -Ae"
1637a2631fcSmrg
1647a2631fcSmrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
1657a2631fcSmrg
1667a2631fcSmrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
1677a2631fcSmrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
1687a2631fcSmrga workaround.  If GNU CC is not installed, it is therefore recommended
1697a2631fcSmrgto try
1707a2631fcSmrg
1717a2631fcSmrg     ./configure CC="cc"
1727a2631fcSmrg
1737a2631fcSmrgand if that doesn't work, try
1747a2631fcSmrg
1757a2631fcSmrg     ./configure CC="cc -nodtk"
1767a2631fcSmrg
1777a2631fcSmrgSpecifying the System Type
1787a2631fcSmrg==========================
1797a2631fcSmrg
1807a2631fcSmrg   There may be some features `configure' cannot figure out
1817a2631fcSmrgautomatically, but needs to determine by the type of machine the package
1827a2631fcSmrgwill run on.  Usually, assuming the package is built to be run on the
1837a2631fcSmrg_same_ architectures, `configure' can figure that out, but if it prints
1847a2631fcSmrga message saying it cannot guess the machine type, give it the
1857a2631fcSmrg`--build=TYPE' option.  TYPE can either be a short name for the system
1867a2631fcSmrgtype, such as `sun4', or a canonical name which has the form:
1877a2631fcSmrg
1887a2631fcSmrg     CPU-COMPANY-SYSTEM
1897a2631fcSmrg
1907a2631fcSmrgwhere SYSTEM can have one of these forms:
1917a2631fcSmrg
1927a2631fcSmrg     OS KERNEL-OS
1937a2631fcSmrg
1947a2631fcSmrg   See the file `config.sub' for the possible values of each field.  If
1957a2631fcSmrg`config.sub' isn't included in this package, then this package doesn't
1967a2631fcSmrgneed to know the machine type.
1977a2631fcSmrg
1987a2631fcSmrg   If you are _building_ compiler tools for cross-compiling, you should
1997a2631fcSmrguse the option `--target=TYPE' to select the type of system they will
2007a2631fcSmrgproduce code for.
2017a2631fcSmrg
2027a2631fcSmrg   If you want to _use_ a cross compiler, that generates code for a
2037a2631fcSmrgplatform different from the build platform, you should specify the
2047a2631fcSmrg"host" platform (i.e., that on which the generated programs will
2057a2631fcSmrgeventually be run) with `--host=TYPE'.
2067a2631fcSmrg
2077a2631fcSmrgSharing Defaults
2087a2631fcSmrg================
2097a2631fcSmrg
2107a2631fcSmrg   If you want to set default values for `configure' scripts to share,
2117a2631fcSmrgyou can create a site shell script called `config.site' that gives
2127a2631fcSmrgdefault values for variables like `CC', `cache_file', and `prefix'.
2137a2631fcSmrg`configure' looks for `PREFIX/share/config.site' if it exists, then
2147a2631fcSmrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
2157a2631fcSmrg`CONFIG_SITE' environment variable to the location of the site script.
2167a2631fcSmrgA warning: not all `configure' scripts look for a site script.
2177a2631fcSmrg
2187a2631fcSmrgDefining Variables
2197a2631fcSmrg==================
2207a2631fcSmrg
2217a2631fcSmrg   Variables not defined in a site shell script can be set in the
2227a2631fcSmrgenvironment passed to `configure'.  However, some packages may run
2237a2631fcSmrgconfigure again during the build, and the customized values of these
2247a2631fcSmrgvariables may be lost.  In order to avoid this problem, you should set
2257a2631fcSmrgthem in the `configure' command line, using `VAR=value'.  For example:
2267a2631fcSmrg
2277a2631fcSmrg     ./configure CC=/usr/local2/bin/gcc
2287a2631fcSmrg
2297a2631fcSmrgcauses the specified `gcc' to be used as the C compiler (unless it is
2307a2631fcSmrgoverridden in the site shell script).
2317a2631fcSmrg
2327a2631fcSmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
2337a2631fcSmrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
2347a2631fcSmrg
2357a2631fcSmrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
2367a2631fcSmrg
2377a2631fcSmrg`configure' Invocation
2387a2631fcSmrg======================
2397a2631fcSmrg
2407a2631fcSmrg   `configure' recognizes the following options to control how it
2417a2631fcSmrgoperates.
2427a2631fcSmrg
2437a2631fcSmrg`--help'
2447a2631fcSmrg`-h'
2457a2631fcSmrg     Print a summary of all of the options to `configure', and exit.
2467a2631fcSmrg
2477a2631fcSmrg`--help=short'
2487a2631fcSmrg`--help=recursive'
2497a2631fcSmrg     Print a summary of the options unique to this package's
2507a2631fcSmrg     `configure', and exit.  The `short' variant lists options used
2517a2631fcSmrg     only in the top level, while the `recursive' variant lists options
2527a2631fcSmrg     also present in any nested packages.
2537a2631fcSmrg
2547a2631fcSmrg`--version'
2557a2631fcSmrg`-V'
2567a2631fcSmrg     Print the version of Autoconf used to generate the `configure'
2577a2631fcSmrg     script, and exit.
2587a2631fcSmrg
2597a2631fcSmrg`--cache-file=FILE'
2607a2631fcSmrg     Enable the cache: use and save the results of the tests in FILE,
2617a2631fcSmrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
2627a2631fcSmrg     disable caching.
2637a2631fcSmrg
2647a2631fcSmrg`--config-cache'
2657a2631fcSmrg`-C'
2667a2631fcSmrg     Alias for `--cache-file=config.cache'.
2677a2631fcSmrg
2687a2631fcSmrg`--quiet'
2697a2631fcSmrg`--silent'
2707a2631fcSmrg`-q'
2717a2631fcSmrg     Do not print messages saying which checks are being made.  To
2727a2631fcSmrg     suppress all normal output, redirect it to `/dev/null' (any error
2737a2631fcSmrg     messages will still be shown).
2747a2631fcSmrg
2757a2631fcSmrg`--srcdir=DIR'
2767a2631fcSmrg     Look for the package's source code in directory DIR.  Usually
2777a2631fcSmrg     `configure' can determine that directory automatically.
2787a2631fcSmrg
2797a2631fcSmrg`--prefix=DIR'
2807a2631fcSmrg     Use DIR as the installation prefix.  *Note Installation Names::
2817a2631fcSmrg     for more details, including other options available for fine-tuning
2827a2631fcSmrg     the installation locations.
2837a2631fcSmrg
2847a2631fcSmrg`--no-create'
2857a2631fcSmrg`-n'
2867a2631fcSmrg     Run the configure checks, but stop before creating any output
2877a2631fcSmrg     files.
2887a2631fcSmrg
2897a2631fcSmrg`configure' also accepts some other, not widely useful, options.  Run
2907a2631fcSmrg`configure --help' for more details.
2917a2631fcSmrg
292