INSTALL revision eeced2e6
1eeced2e6SmrgInstallation Instructions
2eeced2e6Smrg*************************
3eeced2e6Smrg
4eeced2e6SmrgCopyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
5eeced2e6Smrg2006, 2007, 2008 Free Software Foundation, Inc.
6eeced2e6Smrg
7eeced2e6Smrg   This file is free documentation; the Free Software Foundation gives
8eeced2e6Smrgunlimited permission to copy, distribute and modify it.
9eeced2e6Smrg
10eeced2e6SmrgBasic Installation
11eeced2e6Smrg==================
12eeced2e6Smrg
13eeced2e6Smrg   Briefly, the shell commands `./configure; make; make install' should
14eeced2e6Smrgconfigure, build, and install this package.  The following
15eeced2e6Smrgmore-detailed instructions are generic; see the `README' file for
16eeced2e6Smrginstructions specific to this package.
17eeced2e6Smrg
18eeced2e6Smrg   The `configure' shell script attempts to guess correct values for
19eeced2e6Smrgvarious system-dependent variables used during compilation.  It uses
20eeced2e6Smrgthose values to create a `Makefile' in each directory of the package.
21eeced2e6SmrgIt may also create one or more `.h' files containing system-dependent
22eeced2e6Smrgdefinitions.  Finally, it creates a shell script `config.status' that
23eeced2e6Smrgyou can run in the future to recreate the current configuration, and a
24eeced2e6Smrgfile `config.log' containing compiler output (useful mainly for
25eeced2e6Smrgdebugging `configure').
26eeced2e6Smrg
27eeced2e6Smrg   It can also use an optional file (typically called `config.cache'
28eeced2e6Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
29eeced2e6Smrgthe results of its tests to speed up reconfiguring.  Caching is
30eeced2e6Smrgdisabled by default to prevent problems with accidental use of stale
31eeced2e6Smrgcache files.
32eeced2e6Smrg
33eeced2e6Smrg   If you need to do unusual things to compile the package, please try
34eeced2e6Smrgto figure out how `configure' could check whether to do them, and mail
35eeced2e6Smrgdiffs or instructions to the address given in the `README' so they can
36eeced2e6Smrgbe considered for the next release.  If you are using the cache, and at
37eeced2e6Smrgsome point `config.cache' contains results you don't want to keep, you
38eeced2e6Smrgmay remove or edit it.
39eeced2e6Smrg
40eeced2e6Smrg   The file `configure.ac' (or `configure.in') is used to create
41eeced2e6Smrg`configure' by a program called `autoconf'.  You need `configure.ac' if
42eeced2e6Smrgyou want to change it or regenerate `configure' using a newer version
43eeced2e6Smrgof `autoconf'.
44eeced2e6Smrg
45eeced2e6SmrgThe simplest way to compile this package is:
46eeced2e6Smrg
47eeced2e6Smrg  1. `cd' to the directory containing the package's source code and type
48eeced2e6Smrg     `./configure' to configure the package for your system.
49eeced2e6Smrg
50eeced2e6Smrg     Running `configure' might take a while.  While running, it prints
51eeced2e6Smrg     some messages telling which features it is checking for.
52eeced2e6Smrg
53eeced2e6Smrg  2. Type `make' to compile the package.
54eeced2e6Smrg
55eeced2e6Smrg  3. Optionally, type `make check' to run any self-tests that come with
56eeced2e6Smrg     the package.
57eeced2e6Smrg
58eeced2e6Smrg  4. Type `make install' to install the programs and any data files and
59eeced2e6Smrg     documentation.
60eeced2e6Smrg
61eeced2e6Smrg  5. You can remove the program binaries and object files from the
62eeced2e6Smrg     source code directory by typing `make clean'.  To also remove the
63eeced2e6Smrg     files that `configure' created (so you can compile the package for
64eeced2e6Smrg     a different kind of computer), type `make distclean'.  There is
65eeced2e6Smrg     also a `make maintainer-clean' target, but that is intended mainly
66eeced2e6Smrg     for the package's developers.  If you use it, you may have to get
67eeced2e6Smrg     all sorts of other programs in order to regenerate files that came
68eeced2e6Smrg     with the distribution.
69eeced2e6Smrg
70eeced2e6Smrg  6. Often, you can also type `make uninstall' to remove the installed
71eeced2e6Smrg     files again.
72eeced2e6Smrg
73eeced2e6SmrgCompilers and Options
74eeced2e6Smrg=====================
75eeced2e6Smrg
76eeced2e6Smrg   Some systems require unusual options for compilation or linking that
77eeced2e6Smrgthe `configure' script does not know about.  Run `./configure --help'
78eeced2e6Smrgfor details on some of the pertinent environment variables.
79eeced2e6Smrg
80eeced2e6Smrg   You can give `configure' initial values for configuration parameters
81eeced2e6Smrgby setting variables in the command line or in the environment.  Here
82eeced2e6Smrgis an example:
83eeced2e6Smrg
84eeced2e6Smrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
85eeced2e6Smrg
86eeced2e6Smrg   *Note Defining Variables::, for more details.
87eeced2e6Smrg
88eeced2e6SmrgCompiling For Multiple Architectures
89eeced2e6Smrg====================================
90eeced2e6Smrg
91eeced2e6Smrg   You can compile the package for more than one kind of computer at the
92eeced2e6Smrgsame time, by placing the object files for each architecture in their
93eeced2e6Smrgown directory.  To do this, you can use GNU `make'.  `cd' to the
94eeced2e6Smrgdirectory where you want the object files and executables to go and run
95eeced2e6Smrgthe `configure' script.  `configure' automatically checks for the
96eeced2e6Smrgsource code in the directory that `configure' is in and in `..'.
97eeced2e6Smrg
98eeced2e6Smrg   With a non-GNU `make', it is safer to compile the package for one
99eeced2e6Smrgarchitecture at a time in the source code directory.  After you have
100eeced2e6Smrginstalled the package for one architecture, use `make distclean' before
101eeced2e6Smrgreconfiguring for another architecture.
102eeced2e6Smrg
103eeced2e6Smrg   On MacOS X 10.5 and later systems, you can create libraries and
104eeced2e6Smrgexecutables that work on multiple system types--known as "fat" or
105eeced2e6Smrg"universal" binaries--by specifying multiple `-arch' options to the
106eeced2e6Smrgcompiler but only a single `-arch' option to the preprocessor.  Like
107eeced2e6Smrgthis:
108eeced2e6Smrg
109eeced2e6Smrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
110eeced2e6Smrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
111eeced2e6Smrg                 CPP="gcc -E" CXXCPP="g++ -E"
112eeced2e6Smrg
113eeced2e6Smrg   This is not guaranteed to produce working output in all cases, you
114eeced2e6Smrgmay have to build one architecture at a time and combine the results
115eeced2e6Smrgusing the `lipo' tool if you have problems.
116eeced2e6Smrg
117eeced2e6SmrgInstallation Names
118eeced2e6Smrg==================
119eeced2e6Smrg
120eeced2e6Smrg   By default, `make install' installs the package's commands under
121eeced2e6Smrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
122eeced2e6Smrgcan specify an installation prefix other than `/usr/local' by giving
123eeced2e6Smrg`configure' the option `--prefix=PREFIX'.
124eeced2e6Smrg
125eeced2e6Smrg   You can specify separate installation prefixes for
126eeced2e6Smrgarchitecture-specific files and architecture-independent files.  If you
127eeced2e6Smrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
128eeced2e6SmrgPREFIX as the prefix for installing programs and libraries.
129eeced2e6SmrgDocumentation and other data files still use the regular prefix.
130eeced2e6Smrg
131eeced2e6Smrg   In addition, if you use an unusual directory layout you can give
132eeced2e6Smrgoptions like `--bindir=DIR' to specify different values for particular
133eeced2e6Smrgkinds of files.  Run `configure --help' for a list of the directories
134eeced2e6Smrgyou can set and what kinds of files go in them.
135eeced2e6Smrg
136eeced2e6Smrg   If the package supports it, you can cause programs to be installed
137eeced2e6Smrgwith an extra prefix or suffix on their names by giving `configure' the
138eeced2e6Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
139eeced2e6Smrg
140eeced2e6SmrgOptional Features
141eeced2e6Smrg=================
142eeced2e6Smrg
143eeced2e6Smrg   Some packages pay attention to `--enable-FEATURE' options to
144eeced2e6Smrg`configure', where FEATURE indicates an optional part of the package.
145eeced2e6SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
146eeced2e6Smrgis something like `gnu-as' or `x' (for the X Window System).  The
147eeced2e6Smrg`README' should mention any `--enable-' and `--with-' options that the
148eeced2e6Smrgpackage recognizes.
149eeced2e6Smrg
150eeced2e6Smrg   For packages that use the X Window System, `configure' can usually
151eeced2e6Smrgfind the X include and library files automatically, but if it doesn't,
152eeced2e6Smrgyou can use the `configure' options `--x-includes=DIR' and
153eeced2e6Smrg`--x-libraries=DIR' to specify their locations.
154eeced2e6Smrg
155eeced2e6SmrgParticular systems
156eeced2e6Smrg==================
157eeced2e6Smrg
158eeced2e6Smrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
159eeced2e6SmrgCC is not installed, it is recommended to use the following options in
160eeced2e6Smrgorder to use an ANSI C compiler:
161eeced2e6Smrg
162eeced2e6Smrg     ./configure CC="cc -Ae"
163eeced2e6Smrg
164eeced2e6Smrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
165eeced2e6Smrg
166eeced2e6Smrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
167eeced2e6Smrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
168eeced2e6Smrga workaround.  If GNU CC is not installed, it is therefore recommended
169eeced2e6Smrgto try
170eeced2e6Smrg
171eeced2e6Smrg     ./configure CC="cc"
172eeced2e6Smrg
173eeced2e6Smrgand if that doesn't work, try
174eeced2e6Smrg
175eeced2e6Smrg     ./configure CC="cc -nodtk"
176eeced2e6Smrg
177eeced2e6SmrgSpecifying the System Type
178eeced2e6Smrg==========================
179eeced2e6Smrg
180eeced2e6Smrg   There may be some features `configure' cannot figure out
181eeced2e6Smrgautomatically, but needs to determine by the type of machine the package
182eeced2e6Smrgwill run on.  Usually, assuming the package is built to be run on the
183eeced2e6Smrg_same_ architectures, `configure' can figure that out, but if it prints
184eeced2e6Smrga message saying it cannot guess the machine type, give it the
185eeced2e6Smrg`--build=TYPE' option.  TYPE can either be a short name for the system
186eeced2e6Smrgtype, such as `sun4', or a canonical name which has the form:
187eeced2e6Smrg
188eeced2e6Smrg     CPU-COMPANY-SYSTEM
189eeced2e6Smrg
190eeced2e6Smrgwhere SYSTEM can have one of these forms:
191eeced2e6Smrg
192eeced2e6Smrg     OS KERNEL-OS
193eeced2e6Smrg
194eeced2e6Smrg   See the file `config.sub' for the possible values of each field.  If
195eeced2e6Smrg`config.sub' isn't included in this package, then this package doesn't
196eeced2e6Smrgneed to know the machine type.
197eeced2e6Smrg
198eeced2e6Smrg   If you are _building_ compiler tools for cross-compiling, you should
199eeced2e6Smrguse the option `--target=TYPE' to select the type of system they will
200eeced2e6Smrgproduce code for.
201eeced2e6Smrg
202eeced2e6Smrg   If you want to _use_ a cross compiler, that generates code for a
203eeced2e6Smrgplatform different from the build platform, you should specify the
204eeced2e6Smrg"host" platform (i.e., that on which the generated programs will
205eeced2e6Smrgeventually be run) with `--host=TYPE'.
206eeced2e6Smrg
207eeced2e6SmrgSharing Defaults
208eeced2e6Smrg================
209eeced2e6Smrg
210eeced2e6Smrg   If you want to set default values for `configure' scripts to share,
211eeced2e6Smrgyou can create a site shell script called `config.site' that gives
212eeced2e6Smrgdefault values for variables like `CC', `cache_file', and `prefix'.
213eeced2e6Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then
214eeced2e6Smrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
215eeced2e6Smrg`CONFIG_SITE' environment variable to the location of the site script.
216eeced2e6SmrgA warning: not all `configure' scripts look for a site script.
217eeced2e6Smrg
218eeced2e6SmrgDefining Variables
219eeced2e6Smrg==================
220eeced2e6Smrg
221eeced2e6Smrg   Variables not defined in a site shell script can be set in the
222eeced2e6Smrgenvironment passed to `configure'.  However, some packages may run
223eeced2e6Smrgconfigure again during the build, and the customized values of these
224eeced2e6Smrgvariables may be lost.  In order to avoid this problem, you should set
225eeced2e6Smrgthem in the `configure' command line, using `VAR=value'.  For example:
226eeced2e6Smrg
227eeced2e6Smrg     ./configure CC=/usr/local2/bin/gcc
228eeced2e6Smrg
229eeced2e6Smrgcauses the specified `gcc' to be used as the C compiler (unless it is
230eeced2e6Smrgoverridden in the site shell script).
231eeced2e6Smrg
232eeced2e6SmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
233eeced2e6Smrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
234eeced2e6Smrg
235eeced2e6Smrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
236eeced2e6Smrg
237eeced2e6Smrg`configure' Invocation
238eeced2e6Smrg======================
239eeced2e6Smrg
240eeced2e6Smrg   `configure' recognizes the following options to control how it
241eeced2e6Smrgoperates.
242eeced2e6Smrg
243eeced2e6Smrg`--help'
244eeced2e6Smrg`-h'
245eeced2e6Smrg     Print a summary of all of the options to `configure', and exit.
246eeced2e6Smrg
247eeced2e6Smrg`--help=short'
248eeced2e6Smrg`--help=recursive'
249eeced2e6Smrg     Print a summary of the options unique to this package's
250eeced2e6Smrg     `configure', and exit.  The `short' variant lists options used
251eeced2e6Smrg     only in the top level, while the `recursive' variant lists options
252eeced2e6Smrg     also present in any nested packages.
253eeced2e6Smrg
254eeced2e6Smrg`--version'
255eeced2e6Smrg`-V'
256eeced2e6Smrg     Print the version of Autoconf used to generate the `configure'
257eeced2e6Smrg     script, and exit.
258eeced2e6Smrg
259eeced2e6Smrg`--cache-file=FILE'
260eeced2e6Smrg     Enable the cache: use and save the results of the tests in FILE,
261eeced2e6Smrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
262eeced2e6Smrg     disable caching.
263eeced2e6Smrg
264eeced2e6Smrg`--config-cache'
265eeced2e6Smrg`-C'
266eeced2e6Smrg     Alias for `--cache-file=config.cache'.
267eeced2e6Smrg
268eeced2e6Smrg`--quiet'
269eeced2e6Smrg`--silent'
270eeced2e6Smrg`-q'
271eeced2e6Smrg     Do not print messages saying which checks are being made.  To
272eeced2e6Smrg     suppress all normal output, redirect it to `/dev/null' (any error
273eeced2e6Smrg     messages will still be shown).
274eeced2e6Smrg
275eeced2e6Smrg`--srcdir=DIR'
276eeced2e6Smrg     Look for the package's source code in directory DIR.  Usually
277eeced2e6Smrg     `configure' can determine that directory automatically.
278eeced2e6Smrg
279eeced2e6Smrg`--prefix=DIR'
280eeced2e6Smrg     Use DIR as the installation prefix.  *Note Installation Names::
281eeced2e6Smrg     for more details, including other options available for fine-tuning
282eeced2e6Smrg     the installation locations.
283eeced2e6Smrg
284eeced2e6Smrg`--no-create'
285eeced2e6Smrg`-n'
286eeced2e6Smrg     Run the configure checks, but stop before creating any output
287eeced2e6Smrg     files.
288eeced2e6Smrg
289eeced2e6Smrg`configure' also accepts some other, not widely useful, options.  Run
290eeced2e6Smrg`configure --help' for more details.
291eeced2e6Smrg
292