1f33d31a3SmrgInstallation Instructions
2f33d31a3Smrg*************************
3f33d31a3Smrg
4f33d31a3SmrgCopyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation,
5f33d31a3SmrgInc.
6f33d31a3Smrg
7f33d31a3Smrg   Copying and distribution of this file, with or without modification,
8f33d31a3Smrgare permitted in any medium without royalty provided the copyright
9f33d31a3Smrgnotice and this notice are preserved.  This file is offered as-is,
10f33d31a3Smrgwithout warranty of any kind.
11f33d31a3Smrg
12f33d31a3SmrgBasic Installation
13f33d31a3Smrg==================
14f33d31a3Smrg
15f33d31a3Smrg   Briefly, the shell commands `./configure; make; make install' should
16f33d31a3Smrgconfigure, build, and install this package.  The following
17f33d31a3Smrgmore-detailed instructions are generic; see the `README' file for
18f33d31a3Smrginstructions specific to this package.  Some packages provide this
19f33d31a3Smrg`INSTALL' file but do not implement all of the features documented
20f33d31a3Smrgbelow.  The lack of an optional feature in a given package is not
21f33d31a3Smrgnecessarily a bug.  More recommendations for GNU packages can be found
22f33d31a3Smrgin *note Makefile Conventions: (standards)Makefile Conventions.
23f33d31a3Smrg
24f33d31a3Smrg   The `configure' shell script attempts to guess correct values for
25f33d31a3Smrgvarious system-dependent variables used during compilation.  It uses
26f33d31a3Smrgthose values to create a `Makefile' in each directory of the package.
27f33d31a3SmrgIt may also create one or more `.h' files containing system-dependent
28f33d31a3Smrgdefinitions.  Finally, it creates a shell script `config.status' that
29f33d31a3Smrgyou can run in the future to recreate the current configuration, and a
30f33d31a3Smrgfile `config.log' containing compiler output (useful mainly for
31f33d31a3Smrgdebugging `configure').
32f33d31a3Smrg
33f33d31a3Smrg   It can also use an optional file (typically called `config.cache'
34f33d31a3Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
35f33d31a3Smrgthe results of its tests to speed up reconfiguring.  Caching is
36f33d31a3Smrgdisabled by default to prevent problems with accidental use of stale
37f33d31a3Smrgcache files.
38f33d31a3Smrg
39f33d31a3Smrg   If you need to do unusual things to compile the package, please try
40f33d31a3Smrgto figure out how `configure' could check whether to do them, and mail
41f33d31a3Smrgdiffs or instructions to the address given in the `README' so they can
42f33d31a3Smrgbe considered for the next release.  If you are using the cache, and at
43f33d31a3Smrgsome point `config.cache' contains results you don't want to keep, you
44f33d31a3Smrgmay remove or edit it.
45f33d31a3Smrg
46f33d31a3Smrg   The file `configure.ac' (or `configure.in') is used to create
47f33d31a3Smrg`configure' by a program called `autoconf'.  You need `configure.ac' if
48f33d31a3Smrgyou want to change it or regenerate `configure' using a newer version
49f33d31a3Smrgof `autoconf'.
50f33d31a3Smrg
51f33d31a3Smrg   The simplest way to compile this package is:
52f33d31a3Smrg
53f33d31a3Smrg  1. `cd' to the directory containing the package's source code and type
54f33d31a3Smrg     `./configure' to configure the package for your system.
55f33d31a3Smrg
56f33d31a3Smrg     Running `configure' might take a while.  While running, it prints
57f33d31a3Smrg     some messages telling which features it is checking for.
58f33d31a3Smrg
59f33d31a3Smrg  2. Type `make' to compile the package.
60f33d31a3Smrg
61f33d31a3Smrg  3. Optionally, type `make check' to run any self-tests that come with
62f33d31a3Smrg     the package, generally using the just-built uninstalled binaries.
63f33d31a3Smrg
64f33d31a3Smrg  4. Type `make install' to install the programs and any data files and
65f33d31a3Smrg     documentation.  When installing into a prefix owned by root, it is
66f33d31a3Smrg     recommended that the package be configured and built as a regular
67f33d31a3Smrg     user, and only the `make install' phase executed with root
68f33d31a3Smrg     privileges.
69f33d31a3Smrg
70f33d31a3Smrg  5. Optionally, type `make installcheck' to repeat any self-tests, but
71f33d31a3Smrg     this time using the binaries in their final installed location.
72f33d31a3Smrg     This target does not install anything.  Running this target as a
73f33d31a3Smrg     regular user, particularly if the prior `make install' required
74f33d31a3Smrg     root privileges, verifies that the installation completed
75f33d31a3Smrg     correctly.
76f33d31a3Smrg
77f33d31a3Smrg  6. You can remove the program binaries and object files from the
78f33d31a3Smrg     source code directory by typing `make clean'.  To also remove the
79f33d31a3Smrg     files that `configure' created (so you can compile the package for
80f33d31a3Smrg     a different kind of computer), type `make distclean'.  There is
81f33d31a3Smrg     also a `make maintainer-clean' target, but that is intended mainly
82f33d31a3Smrg     for the package's developers.  If you use it, you may have to get
83f33d31a3Smrg     all sorts of other programs in order to regenerate files that came
84f33d31a3Smrg     with the distribution.
85f33d31a3Smrg
86f33d31a3Smrg  7. Often, you can also type `make uninstall' to remove the installed
87f33d31a3Smrg     files again.  In practice, not all packages have tested that
88f33d31a3Smrg     uninstallation works correctly, even though it is required by the
89f33d31a3Smrg     GNU Coding Standards.
90f33d31a3Smrg
91f33d31a3Smrg  8. Some packages, particularly those that use Automake, provide `make
92f33d31a3Smrg     distcheck', which can by used by developers to test that all other
93f33d31a3Smrg     targets like `make install' and `make uninstall' work correctly.
94f33d31a3Smrg     This target is generally not run by end users.
95f33d31a3Smrg
96f33d31a3SmrgCompilers and Options
97f33d31a3Smrg=====================
98f33d31a3Smrg
99f33d31a3Smrg   Some systems require unusual options for compilation or linking that
100f33d31a3Smrgthe `configure' script does not know about.  Run `./configure --help'
101f33d31a3Smrgfor details on some of the pertinent environment variables.
102f33d31a3Smrg
103f33d31a3Smrg   You can give `configure' initial values for configuration parameters
104f33d31a3Smrgby setting variables in the command line or in the environment.  Here
105f33d31a3Smrgis an example:
106f33d31a3Smrg
107f33d31a3Smrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
108f33d31a3Smrg
109f33d31a3Smrg   *Note Defining Variables::, for more details.
110f33d31a3Smrg
111f33d31a3SmrgCompiling For Multiple Architectures
112f33d31a3Smrg====================================
113f33d31a3Smrg
114f33d31a3Smrg   You can compile the package for more than one kind of computer at the
115f33d31a3Smrgsame time, by placing the object files for each architecture in their
116f33d31a3Smrgown directory.  To do this, you can use GNU `make'.  `cd' to the
117f33d31a3Smrgdirectory where you want the object files and executables to go and run
118f33d31a3Smrgthe `configure' script.  `configure' automatically checks for the
119f33d31a3Smrgsource code in the directory that `configure' is in and in `..'.  This
120f33d31a3Smrgis known as a "VPATH" build.
121f33d31a3Smrg
122f33d31a3Smrg   With a non-GNU `make', it is safer to compile the package for one
123f33d31a3Smrgarchitecture at a time in the source code directory.  After you have
124f33d31a3Smrginstalled the package for one architecture, use `make distclean' before
125f33d31a3Smrgreconfiguring for another architecture.
126f33d31a3Smrg
127f33d31a3Smrg   On MacOS X 10.5 and later systems, you can create libraries and
128f33d31a3Smrgexecutables that work on multiple system types--known as "fat" or
129f33d31a3Smrg"universal" binaries--by specifying multiple `-arch' options to the
130f33d31a3Smrgcompiler but only a single `-arch' option to the preprocessor.  Like
131f33d31a3Smrgthis:
132f33d31a3Smrg
133f33d31a3Smrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
134f33d31a3Smrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
135f33d31a3Smrg                 CPP="gcc -E" CXXCPP="g++ -E"
136f33d31a3Smrg
137f33d31a3Smrg   This is not guaranteed to produce working output in all cases, you
138f33d31a3Smrgmay have to build one architecture at a time and combine the results
139f33d31a3Smrgusing the `lipo' tool if you have problems.
140f33d31a3Smrg
141f33d31a3SmrgInstallation Names
142f33d31a3Smrg==================
143f33d31a3Smrg
144f33d31a3Smrg   By default, `make install' installs the package's commands under
145f33d31a3Smrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
146f33d31a3Smrgcan specify an installation prefix other than `/usr/local' by giving
147f33d31a3Smrg`configure' the option `--prefix=PREFIX', where PREFIX must be an
148f33d31a3Smrgabsolute file name.
149f33d31a3Smrg
150f33d31a3Smrg   You can specify separate installation prefixes for
151f33d31a3Smrgarchitecture-specific files and architecture-independent files.  If you
152f33d31a3Smrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
153f33d31a3SmrgPREFIX as the prefix for installing programs and libraries.
154f33d31a3SmrgDocumentation and other data files still use the regular prefix.
155f33d31a3Smrg
156f33d31a3Smrg   In addition, if you use an unusual directory layout you can give
157f33d31a3Smrgoptions like `--bindir=DIR' to specify different values for particular
158f33d31a3Smrgkinds of files.  Run `configure --help' for a list of the directories
159f33d31a3Smrgyou can set and what kinds of files go in them.  In general, the
160f33d31a3Smrgdefault for these options is expressed in terms of `${prefix}', so that
161f33d31a3Smrgspecifying just `--prefix' will affect all of the other directory
162f33d31a3Smrgspecifications that were not explicitly provided.
163f33d31a3Smrg
164f33d31a3Smrg   The most portable way to affect installation locations is to pass the
165f33d31a3Smrgcorrect locations to `configure'; however, many packages provide one or
166f33d31a3Smrgboth of the following shortcuts of passing variable assignments to the
167f33d31a3Smrg`make install' command line to change installation locations without
168f33d31a3Smrghaving to reconfigure or recompile.
169f33d31a3Smrg
170f33d31a3Smrg   The first method involves providing an override variable for each
171f33d31a3Smrgaffected directory.  For example, `make install
172f33d31a3Smrgprefix=/alternate/directory' will choose an alternate location for all
173f33d31a3Smrgdirectory configuration variables that were expressed in terms of
174f33d31a3Smrg`${prefix}'.  Any directories that were specified during `configure',
175f33d31a3Smrgbut not in terms of `${prefix}', must each be overridden at install
176f33d31a3Smrgtime for the entire installation to be relocated.  The approach of
177f33d31a3Smrgmakefile variable overrides for each directory variable is required by
178f33d31a3Smrgthe GNU Coding Standards, and ideally causes no recompilation.
179f33d31a3SmrgHowever, some platforms have known limitations with the semantics of
180f33d31a3Smrgshared libraries that end up requiring recompilation when using this
181f33d31a3Smrgmethod, particularly noticeable in packages that use GNU Libtool.
182f33d31a3Smrg
183f33d31a3Smrg   The second method involves providing the `DESTDIR' variable.  For
184f33d31a3Smrgexample, `make install DESTDIR=/alternate/directory' will prepend
185f33d31a3Smrg`/alternate/directory' before all installation names.  The approach of
186f33d31a3Smrg`DESTDIR' overrides is not required by the GNU Coding Standards, and
187f33d31a3Smrgdoes not work on platforms that have drive letters.  On the other hand,
188f33d31a3Smrgit does better at avoiding recompilation issues, and works well even
189f33d31a3Smrgwhen some directory options were not specified in terms of `${prefix}'
190f33d31a3Smrgat `configure' time.
191f33d31a3Smrg
192f33d31a3SmrgOptional Features
193f33d31a3Smrg=================
194f33d31a3Smrg
195f33d31a3Smrg   If the package supports it, you can cause programs to be installed
196f33d31a3Smrgwith an extra prefix or suffix on their names by giving `configure' the
197f33d31a3Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
198f33d31a3Smrg
199f33d31a3Smrg   Some packages pay attention to `--enable-FEATURE' options to
200f33d31a3Smrg`configure', where FEATURE indicates an optional part of the package.
201f33d31a3SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
202f33d31a3Smrgis something like `gnu-as' or `x' (for the X Window System).  The
203f33d31a3Smrg`README' should mention any `--enable-' and `--with-' options that the
204f33d31a3Smrgpackage recognizes.
205f33d31a3Smrg
206f33d31a3Smrg   For packages that use the X Window System, `configure' can usually
207f33d31a3Smrgfind the X include and library files automatically, but if it doesn't,
208f33d31a3Smrgyou can use the `configure' options `--x-includes=DIR' and
209f33d31a3Smrg`--x-libraries=DIR' to specify their locations.
210f33d31a3Smrg
211f33d31a3Smrg   Some packages offer the ability to configure how verbose the
212f33d31a3Smrgexecution of `make' will be.  For these packages, running `./configure
213f33d31a3Smrg--enable-silent-rules' sets the default to minimal output, which can be
214f33d31a3Smrgoverridden with `make V=1'; while running `./configure
215f33d31a3Smrg--disable-silent-rules' sets the default to verbose, which can be
216f33d31a3Smrgoverridden with `make V=0'.
217f33d31a3Smrg
218f33d31a3SmrgParticular systems
219f33d31a3Smrg==================
220f33d31a3Smrg
221f33d31a3Smrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
222f33d31a3SmrgCC is not installed, it is recommended to use the following options in
223f33d31a3Smrgorder to use an ANSI C compiler:
224f33d31a3Smrg
225f33d31a3Smrg     ./configure CC="cc -Ae -D_XOPEN_SOURCE=500"
226f33d31a3Smrg
227f33d31a3Smrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
228f33d31a3Smrg
229f33d31a3Smrg   HP-UX `make' updates targets which have the same time stamps as
230f33d31a3Smrgtheir prerequisites, which makes it generally unusable when shipped
231f33d31a3Smrggenerated files such as `configure' are involved.  Use GNU `make'
232f33d31a3Smrginstead.
233f33d31a3Smrg
234f33d31a3Smrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
235f33d31a3Smrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
236f33d31a3Smrga workaround.  If GNU CC is not installed, it is therefore recommended
237f33d31a3Smrgto try
238f33d31a3Smrg
239f33d31a3Smrg     ./configure CC="cc"
240f33d31a3Smrg
241f33d31a3Smrgand if that doesn't work, try
242f33d31a3Smrg
243f33d31a3Smrg     ./configure CC="cc -nodtk"
244f33d31a3Smrg
245f33d31a3Smrg   On Solaris, don't put `/usr/ucb' early in your `PATH'.  This
246f33d31a3Smrgdirectory contains several dysfunctional programs; working variants of
247f33d31a3Smrgthese programs are available in `/usr/bin'.  So, if you need `/usr/ucb'
248f33d31a3Smrgin your `PATH', put it _after_ `/usr/bin'.
249f33d31a3Smrg
250f33d31a3Smrg   On Haiku, software installed for all users goes in `/boot/common',
251f33d31a3Smrgnot `/usr/local'.  It is recommended to use the following options:
252f33d31a3Smrg
253f33d31a3Smrg     ./configure --prefix=/boot/common
254f33d31a3Smrg
255f33d31a3SmrgSpecifying the System Type
256f33d31a3Smrg==========================
257f33d31a3Smrg
258f33d31a3Smrg   There may be some features `configure' cannot figure out
259f33d31a3Smrgautomatically, but needs to determine by the type of machine the package
260f33d31a3Smrgwill run on.  Usually, assuming the package is built to be run on the
261f33d31a3Smrg_same_ architectures, `configure' can figure that out, but if it prints
262f33d31a3Smrga message saying it cannot guess the machine type, give it the
263f33d31a3Smrg`--build=TYPE' option.  TYPE can either be a short name for the system
264f33d31a3Smrgtype, such as `sun4', or a canonical name which has the form:
265f33d31a3Smrg
266f33d31a3Smrg     CPU-COMPANY-SYSTEM
267f33d31a3Smrg
268f33d31a3Smrgwhere SYSTEM can have one of these forms:
269f33d31a3Smrg
270f33d31a3Smrg     OS
271f33d31a3Smrg     KERNEL-OS
272f33d31a3Smrg
273f33d31a3Smrg   See the file `config.sub' for the possible values of each field.  If
274f33d31a3Smrg`config.sub' isn't included in this package, then this package doesn't
275f33d31a3Smrgneed to know the machine type.
276f33d31a3Smrg
277f33d31a3Smrg   If you are _building_ compiler tools for cross-compiling, you should
278f33d31a3Smrguse the option `--target=TYPE' to select the type of system they will
279f33d31a3Smrgproduce code for.
280f33d31a3Smrg
281f33d31a3Smrg   If you want to _use_ a cross compiler, that generates code for a
282f33d31a3Smrgplatform different from the build platform, you should specify the
283f33d31a3Smrg"host" platform (i.e., that on which the generated programs will
284f33d31a3Smrgeventually be run) with `--host=TYPE'.
285f33d31a3Smrg
286f33d31a3SmrgSharing Defaults
287f33d31a3Smrg================
288f33d31a3Smrg
289f33d31a3Smrg   If you want to set default values for `configure' scripts to share,
290f33d31a3Smrgyou can create a site shell script called `config.site' that gives
291f33d31a3Smrgdefault values for variables like `CC', `cache_file', and `prefix'.
292f33d31a3Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then
293f33d31a3Smrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
294f33d31a3Smrg`CONFIG_SITE' environment variable to the location of the site script.
295f33d31a3SmrgA warning: not all `configure' scripts look for a site script.
296f33d31a3Smrg
297f33d31a3SmrgDefining Variables
298f33d31a3Smrg==================
299f33d31a3Smrg
300f33d31a3Smrg   Variables not defined in a site shell script can be set in the
301f33d31a3Smrgenvironment passed to `configure'.  However, some packages may run
302f33d31a3Smrgconfigure again during the build, and the customized values of these
303f33d31a3Smrgvariables may be lost.  In order to avoid this problem, you should set
304f33d31a3Smrgthem in the `configure' command line, using `VAR=value'.  For example:
305f33d31a3Smrg
306f33d31a3Smrg     ./configure CC=/usr/local2/bin/gcc
307f33d31a3Smrg
308f33d31a3Smrgcauses the specified `gcc' to be used as the C compiler (unless it is
309f33d31a3Smrgoverridden in the site shell script).
310f33d31a3Smrg
311f33d31a3SmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
312f33d31a3Smrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
313f33d31a3Smrg
314f33d31a3Smrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
315f33d31a3Smrg
316f33d31a3Smrg`configure' Invocation
317f33d31a3Smrg======================
318f33d31a3Smrg
319f33d31a3Smrg   `configure' recognizes the following options to control how it
320f33d31a3Smrgoperates.
321f33d31a3Smrg
322f33d31a3Smrg`--help'
323f33d31a3Smrg`-h'
324f33d31a3Smrg     Print a summary of all of the options to `configure', and exit.
325f33d31a3Smrg
326f33d31a3Smrg`--help=short'
327f33d31a3Smrg`--help=recursive'
328f33d31a3Smrg     Print a summary of the options unique to this package's
329f33d31a3Smrg     `configure', and exit.  The `short' variant lists options used
330f33d31a3Smrg     only in the top level, while the `recursive' variant lists options
331f33d31a3Smrg     also present in any nested packages.
332f33d31a3Smrg
333f33d31a3Smrg`--version'
334f33d31a3Smrg`-V'
335f33d31a3Smrg     Print the version of Autoconf used to generate the `configure'
336f33d31a3Smrg     script, and exit.
337f33d31a3Smrg
338f33d31a3Smrg`--cache-file=FILE'
339f33d31a3Smrg     Enable the cache: use and save the results of the tests in FILE,
340f33d31a3Smrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
341f33d31a3Smrg     disable caching.
342f33d31a3Smrg
343f33d31a3Smrg`--config-cache'
344f33d31a3Smrg`-C'
345f33d31a3Smrg     Alias for `--cache-file=config.cache'.
346f33d31a3Smrg
347f33d31a3Smrg`--quiet'
348f33d31a3Smrg`--silent'
349f33d31a3Smrg`-q'
350f33d31a3Smrg     Do not print messages saying which checks are being made.  To
351f33d31a3Smrg     suppress all normal output, redirect it to `/dev/null' (any error
352f33d31a3Smrg     messages will still be shown).
353f33d31a3Smrg
354f33d31a3Smrg`--srcdir=DIR'
355f33d31a3Smrg     Look for the package's source code in directory DIR.  Usually
356f33d31a3Smrg     `configure' can determine that directory automatically.
357f33d31a3Smrg
358f33d31a3Smrg`--prefix=DIR'
359f33d31a3Smrg     Use DIR as the installation prefix.  *note Installation Names::
360f33d31a3Smrg     for more details, including other options available for fine-tuning
361f33d31a3Smrg     the installation locations.
362f33d31a3Smrg
363f33d31a3Smrg`--no-create'
364f33d31a3Smrg`-n'
365f33d31a3Smrg     Run the configure checks, but stop before creating any output
366f33d31a3Smrg     files.
367f33d31a3Smrg
368f33d31a3Smrg`configure' also accepts some other, not widely useful, options.  Run
369f33d31a3Smrg`configure --help' for more details.
370f33d31a3Smrg
371