INSTALL revision 8fff3f40
18fff3f40SmrgInstallation Instructions
28fff3f40Smrg*************************
38fff3f40Smrg
48fff3f40SmrgCopyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
58fff3f40Smrg2006, 2007, 2008 Free Software Foundation, Inc.
68fff3f40Smrg
78fff3f40Smrg   This file is free documentation; the Free Software Foundation gives
88fff3f40Smrgunlimited permission to copy, distribute and modify it.
98fff3f40Smrg
108fff3f40SmrgBasic Installation
118fff3f40Smrg==================
128fff3f40Smrg
138fff3f40Smrg   Briefly, the shell commands `./configure; make; make install' should
148fff3f40Smrgconfigure, build, and install this package.  The following
158fff3f40Smrgmore-detailed instructions are generic; see the `README' file for
168fff3f40Smrginstructions specific to this package.
178fff3f40Smrg
188fff3f40Smrg   The `configure' shell script attempts to guess correct values for
198fff3f40Smrgvarious system-dependent variables used during compilation.  It uses
208fff3f40Smrgthose values to create a `Makefile' in each directory of the package.
218fff3f40SmrgIt may also create one or more `.h' files containing system-dependent
228fff3f40Smrgdefinitions.  Finally, it creates a shell script `config.status' that
238fff3f40Smrgyou can run in the future to recreate the current configuration, and a
248fff3f40Smrgfile `config.log' containing compiler output (useful mainly for
258fff3f40Smrgdebugging `configure').
268fff3f40Smrg
278fff3f40Smrg   It can also use an optional file (typically called `config.cache'
288fff3f40Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
298fff3f40Smrgthe results of its tests to speed up reconfiguring.  Caching is
308fff3f40Smrgdisabled by default to prevent problems with accidental use of stale
318fff3f40Smrgcache files.
328fff3f40Smrg
338fff3f40Smrg   If you need to do unusual things to compile the package, please try
348fff3f40Smrgto figure out how `configure' could check whether to do them, and mail
358fff3f40Smrgdiffs or instructions to the address given in the `README' so they can
368fff3f40Smrgbe considered for the next release.  If you are using the cache, and at
378fff3f40Smrgsome point `config.cache' contains results you don't want to keep, you
388fff3f40Smrgmay remove or edit it.
398fff3f40Smrg
408fff3f40Smrg   The file `configure.ac' (or `configure.in') is used to create
418fff3f40Smrg`configure' by a program called `autoconf'.  You need `configure.ac' if
428fff3f40Smrgyou want to change it or regenerate `configure' using a newer version
438fff3f40Smrgof `autoconf'.
448fff3f40Smrg
458fff3f40SmrgThe simplest way to compile this package is:
468fff3f40Smrg
478fff3f40Smrg  1. `cd' to the directory containing the package's source code and type
488fff3f40Smrg     `./configure' to configure the package for your system.
498fff3f40Smrg
508fff3f40Smrg     Running `configure' might take a while.  While running, it prints
518fff3f40Smrg     some messages telling which features it is checking for.
528fff3f40Smrg
538fff3f40Smrg  2. Type `make' to compile the package.
548fff3f40Smrg
558fff3f40Smrg  3. Optionally, type `make check' to run any self-tests that come with
568fff3f40Smrg     the package.
578fff3f40Smrg
588fff3f40Smrg  4. Type `make install' to install the programs and any data files and
598fff3f40Smrg     documentation.
608fff3f40Smrg
618fff3f40Smrg  5. You can remove the program binaries and object files from the
628fff3f40Smrg     source code directory by typing `make clean'.  To also remove the
638fff3f40Smrg     files that `configure' created (so you can compile the package for
648fff3f40Smrg     a different kind of computer), type `make distclean'.  There is
658fff3f40Smrg     also a `make maintainer-clean' target, but that is intended mainly
668fff3f40Smrg     for the package's developers.  If you use it, you may have to get
678fff3f40Smrg     all sorts of other programs in order to regenerate files that came
688fff3f40Smrg     with the distribution.
698fff3f40Smrg
708fff3f40Smrg  6. Often, you can also type `make uninstall' to remove the installed
718fff3f40Smrg     files again.
728fff3f40Smrg
738fff3f40SmrgCompilers and Options
748fff3f40Smrg=====================
758fff3f40Smrg
768fff3f40Smrg   Some systems require unusual options for compilation or linking that
778fff3f40Smrgthe `configure' script does not know about.  Run `./configure --help'
788fff3f40Smrgfor details on some of the pertinent environment variables.
798fff3f40Smrg
808fff3f40Smrg   You can give `configure' initial values for configuration parameters
818fff3f40Smrgby setting variables in the command line or in the environment.  Here
828fff3f40Smrgis an example:
838fff3f40Smrg
848fff3f40Smrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
858fff3f40Smrg
868fff3f40Smrg   *Note Defining Variables::, for more details.
878fff3f40Smrg
888fff3f40SmrgCompiling For Multiple Architectures
898fff3f40Smrg====================================
908fff3f40Smrg
918fff3f40Smrg   You can compile the package for more than one kind of computer at the
928fff3f40Smrgsame time, by placing the object files for each architecture in their
938fff3f40Smrgown directory.  To do this, you can use GNU `make'.  `cd' to the
948fff3f40Smrgdirectory where you want the object files and executables to go and run
958fff3f40Smrgthe `configure' script.  `configure' automatically checks for the
968fff3f40Smrgsource code in the directory that `configure' is in and in `..'.
978fff3f40Smrg
988fff3f40Smrg   With a non-GNU `make', it is safer to compile the package for one
998fff3f40Smrgarchitecture at a time in the source code directory.  After you have
1008fff3f40Smrginstalled the package for one architecture, use `make distclean' before
1018fff3f40Smrgreconfiguring for another architecture.
1028fff3f40Smrg
1038fff3f40Smrg   On MacOS X 10.5 and later systems, you can create libraries and
1048fff3f40Smrgexecutables that work on multiple system types--known as "fat" or
1058fff3f40Smrg"universal" binaries--by specifying multiple `-arch' options to the
1068fff3f40Smrgcompiler but only a single `-arch' option to the preprocessor.  Like
1078fff3f40Smrgthis:
1088fff3f40Smrg
1098fff3f40Smrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1108fff3f40Smrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
1118fff3f40Smrg                 CPP="gcc -E" CXXCPP="g++ -E"
1128fff3f40Smrg
1138fff3f40Smrg   This is not guaranteed to produce working output in all cases, you
1148fff3f40Smrgmay have to build one architecture at a time and combine the results
1158fff3f40Smrgusing the `lipo' tool if you have problems.
1168fff3f40Smrg
1178fff3f40SmrgInstallation Names
1188fff3f40Smrg==================
1198fff3f40Smrg
1208fff3f40Smrg   By default, `make install' installs the package's commands under
1218fff3f40Smrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
1228fff3f40Smrgcan specify an installation prefix other than `/usr/local' by giving
1238fff3f40Smrg`configure' the option `--prefix=PREFIX'.
1248fff3f40Smrg
1258fff3f40Smrg   You can specify separate installation prefixes for
1268fff3f40Smrgarchitecture-specific files and architecture-independent files.  If you
1278fff3f40Smrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
1288fff3f40SmrgPREFIX as the prefix for installing programs and libraries.
1298fff3f40SmrgDocumentation and other data files still use the regular prefix.
1308fff3f40Smrg
1318fff3f40Smrg   In addition, if you use an unusual directory layout you can give
1328fff3f40Smrgoptions like `--bindir=DIR' to specify different values for particular
1338fff3f40Smrgkinds of files.  Run `configure --help' for a list of the directories
1348fff3f40Smrgyou can set and what kinds of files go in them.
1358fff3f40Smrg
1368fff3f40Smrg   If the package supports it, you can cause programs to be installed
1378fff3f40Smrgwith an extra prefix or suffix on their names by giving `configure' the
1388fff3f40Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
1398fff3f40Smrg
1408fff3f40SmrgOptional Features
1418fff3f40Smrg=================
1428fff3f40Smrg
1438fff3f40Smrg   Some packages pay attention to `--enable-FEATURE' options to
1448fff3f40Smrg`configure', where FEATURE indicates an optional part of the package.
1458fff3f40SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
1468fff3f40Smrgis something like `gnu-as' or `x' (for the X Window System).  The
1478fff3f40Smrg`README' should mention any `--enable-' and `--with-' options that the
1488fff3f40Smrgpackage recognizes.
1498fff3f40Smrg
1508fff3f40Smrg   For packages that use the X Window System, `configure' can usually
1518fff3f40Smrgfind the X include and library files automatically, but if it doesn't,
1528fff3f40Smrgyou can use the `configure' options `--x-includes=DIR' and
1538fff3f40Smrg`--x-libraries=DIR' to specify their locations.
1548fff3f40Smrg
1558fff3f40SmrgParticular systems
1568fff3f40Smrg==================
1578fff3f40Smrg
1588fff3f40Smrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
1598fff3f40SmrgCC is not installed, it is recommended to use the following options in
1608fff3f40Smrgorder to use an ANSI C compiler:
1618fff3f40Smrg
1628fff3f40Smrg     ./configure CC="cc -Ae"
1638fff3f40Smrg
1648fff3f40Smrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
1658fff3f40Smrg
1668fff3f40Smrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
1678fff3f40Smrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
1688fff3f40Smrga workaround.  If GNU CC is not installed, it is therefore recommended
1698fff3f40Smrgto try
1708fff3f40Smrg
1718fff3f40Smrg     ./configure CC="cc"
1728fff3f40Smrg
1738fff3f40Smrgand if that doesn't work, try
1748fff3f40Smrg
1758fff3f40Smrg     ./configure CC="cc -nodtk"
1768fff3f40Smrg
1778fff3f40SmrgSpecifying the System Type
1788fff3f40Smrg==========================
1798fff3f40Smrg
1808fff3f40Smrg   There may be some features `configure' cannot figure out
1818fff3f40Smrgautomatically, but needs to determine by the type of machine the package
1828fff3f40Smrgwill run on.  Usually, assuming the package is built to be run on the
1838fff3f40Smrg_same_ architectures, `configure' can figure that out, but if it prints
1848fff3f40Smrga message saying it cannot guess the machine type, give it the
1858fff3f40Smrg`--build=TYPE' option.  TYPE can either be a short name for the system
1868fff3f40Smrgtype, such as `sun4', or a canonical name which has the form:
1878fff3f40Smrg
1888fff3f40Smrg     CPU-COMPANY-SYSTEM
1898fff3f40Smrg
1908fff3f40Smrgwhere SYSTEM can have one of these forms:
1918fff3f40Smrg
1928fff3f40Smrg     OS KERNEL-OS
1938fff3f40Smrg
1948fff3f40Smrg   See the file `config.sub' for the possible values of each field.  If
1958fff3f40Smrg`config.sub' isn't included in this package, then this package doesn't
1968fff3f40Smrgneed to know the machine type.
1978fff3f40Smrg
1988fff3f40Smrg   If you are _building_ compiler tools for cross-compiling, you should
1998fff3f40Smrguse the option `--target=TYPE' to select the type of system they will
2008fff3f40Smrgproduce code for.
2018fff3f40Smrg
2028fff3f40Smrg   If you want to _use_ a cross compiler, that generates code for a
2038fff3f40Smrgplatform different from the build platform, you should specify the
2048fff3f40Smrg"host" platform (i.e., that on which the generated programs will
2058fff3f40Smrgeventually be run) with `--host=TYPE'.
2068fff3f40Smrg
2078fff3f40SmrgSharing Defaults
2088fff3f40Smrg================
2098fff3f40Smrg
2108fff3f40Smrg   If you want to set default values for `configure' scripts to share,
2118fff3f40Smrgyou can create a site shell script called `config.site' that gives
2128fff3f40Smrgdefault values for variables like `CC', `cache_file', and `prefix'.
2138fff3f40Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then
2148fff3f40Smrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
2158fff3f40Smrg`CONFIG_SITE' environment variable to the location of the site script.
2168fff3f40SmrgA warning: not all `configure' scripts look for a site script.
2178fff3f40Smrg
2188fff3f40SmrgDefining Variables
2198fff3f40Smrg==================
2208fff3f40Smrg
2218fff3f40Smrg   Variables not defined in a site shell script can be set in the
2228fff3f40Smrgenvironment passed to `configure'.  However, some packages may run
2238fff3f40Smrgconfigure again during the build, and the customized values of these
2248fff3f40Smrgvariables may be lost.  In order to avoid this problem, you should set
2258fff3f40Smrgthem in the `configure' command line, using `VAR=value'.  For example:
2268fff3f40Smrg
2278fff3f40Smrg     ./configure CC=/usr/local2/bin/gcc
2288fff3f40Smrg
2298fff3f40Smrgcauses the specified `gcc' to be used as the C compiler (unless it is
2308fff3f40Smrgoverridden in the site shell script).
2318fff3f40Smrg
2328fff3f40SmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
2338fff3f40Smrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
2348fff3f40Smrg
2358fff3f40Smrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
2368fff3f40Smrg
2378fff3f40Smrg`configure' Invocation
2388fff3f40Smrg======================
2398fff3f40Smrg
2408fff3f40Smrg   `configure' recognizes the following options to control how it
2418fff3f40Smrgoperates.
2428fff3f40Smrg
2438fff3f40Smrg`--help'
2448fff3f40Smrg`-h'
2458fff3f40Smrg     Print a summary of all of the options to `configure', and exit.
2468fff3f40Smrg
2478fff3f40Smrg`--help=short'
2488fff3f40Smrg`--help=recursive'
2498fff3f40Smrg     Print a summary of the options unique to this package's
2508fff3f40Smrg     `configure', and exit.  The `short' variant lists options used
2518fff3f40Smrg     only in the top level, while the `recursive' variant lists options
2528fff3f40Smrg     also present in any nested packages.
2538fff3f40Smrg
2548fff3f40Smrg`--version'
2558fff3f40Smrg`-V'
2568fff3f40Smrg     Print the version of Autoconf used to generate the `configure'
2578fff3f40Smrg     script, and exit.
2588fff3f40Smrg
2598fff3f40Smrg`--cache-file=FILE'
2608fff3f40Smrg     Enable the cache: use and save the results of the tests in FILE,
2618fff3f40Smrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
2628fff3f40Smrg     disable caching.
2638fff3f40Smrg
2648fff3f40Smrg`--config-cache'
2658fff3f40Smrg`-C'
2668fff3f40Smrg     Alias for `--cache-file=config.cache'.
2678fff3f40Smrg
2688fff3f40Smrg`--quiet'
2698fff3f40Smrg`--silent'
2708fff3f40Smrg`-q'
2718fff3f40Smrg     Do not print messages saying which checks are being made.  To
2728fff3f40Smrg     suppress all normal output, redirect it to `/dev/null' (any error
2738fff3f40Smrg     messages will still be shown).
2748fff3f40Smrg
2758fff3f40Smrg`--srcdir=DIR'
2768fff3f40Smrg     Look for the package's source code in directory DIR.  Usually
2778fff3f40Smrg     `configure' can determine that directory automatically.
2788fff3f40Smrg
2798fff3f40Smrg`--prefix=DIR'
2808fff3f40Smrg     Use DIR as the installation prefix.  *Note Installation Names::
2818fff3f40Smrg     for more details, including other options available for fine-tuning
2828fff3f40Smrg     the installation locations.
2838fff3f40Smrg
2848fff3f40Smrg`--no-create'
2858fff3f40Smrg`-n'
2868fff3f40Smrg     Run the configure checks, but stop before creating any output
2878fff3f40Smrg     files.
2888fff3f40Smrg
2898fff3f40Smrg`configure' also accepts some other, not widely useful, options.  Run
2908fff3f40Smrg`configure --help' for more details.
2918fff3f40Smrg
292