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