INSTALL revision 493f84f4
1493f84f4SmrgInstallation Instructions
2493f84f4Smrg*************************
3493f84f4Smrg
4493f84f4SmrgCopyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005,
5493f84f4Smrg2006, 2007, 2008 Free Software Foundation, Inc.
6493f84f4Smrg
7493f84f4Smrg   This file is free documentation; the Free Software Foundation gives
8493f84f4Smrgunlimited permission to copy, distribute and modify it.
9493f84f4Smrg
10493f84f4SmrgBasic Installation
11493f84f4Smrg==================
12493f84f4Smrg
13493f84f4Smrg   Briefly, the shell commands `./configure; make; make install' should
14493f84f4Smrgconfigure, build, and install this package.  The following
15493f84f4Smrgmore-detailed instructions are generic; see the `README' file for
16493f84f4Smrginstructions specific to this package.
17493f84f4Smrg
18493f84f4Smrg   The `configure' shell script attempts to guess correct values for
19493f84f4Smrgvarious system-dependent variables used during compilation.  It uses
20493f84f4Smrgthose values to create a `Makefile' in each directory of the package.
21493f84f4SmrgIt may also create one or more `.h' files containing system-dependent
22493f84f4Smrgdefinitions.  Finally, it creates a shell script `config.status' that
23493f84f4Smrgyou can run in the future to recreate the current configuration, and a
24493f84f4Smrgfile `config.log' containing compiler output (useful mainly for
25493f84f4Smrgdebugging `configure').
26493f84f4Smrg
27493f84f4Smrg   It can also use an optional file (typically called `config.cache'
28493f84f4Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves
29493f84f4Smrgthe results of its tests to speed up reconfiguring.  Caching is
30493f84f4Smrgdisabled by default to prevent problems with accidental use of stale
31493f84f4Smrgcache files.
32493f84f4Smrg
33493f84f4Smrg   If you need to do unusual things to compile the package, please try
34493f84f4Smrgto figure out how `configure' could check whether to do them, and mail
35493f84f4Smrgdiffs or instructions to the address given in the `README' so they can
36493f84f4Smrgbe considered for the next release.  If you are using the cache, and at
37493f84f4Smrgsome point `config.cache' contains results you don't want to keep, you
38493f84f4Smrgmay remove or edit it.
39493f84f4Smrg
40493f84f4Smrg   The file `configure.ac' (or `configure.in') is used to create
41493f84f4Smrg`configure' by a program called `autoconf'.  You need `configure.ac' if
42493f84f4Smrgyou want to change it or regenerate `configure' using a newer version
43493f84f4Smrgof `autoconf'.
44493f84f4Smrg
45493f84f4SmrgThe simplest way to compile this package is:
46493f84f4Smrg
47493f84f4Smrg  1. `cd' to the directory containing the package's source code and type
48493f84f4Smrg     `./configure' to configure the package for your system.
49493f84f4Smrg
50493f84f4Smrg     Running `configure' might take a while.  While running, it prints
51493f84f4Smrg     some messages telling which features it is checking for.
52493f84f4Smrg
53493f84f4Smrg  2. Type `make' to compile the package.
54493f84f4Smrg
55493f84f4Smrg  3. Optionally, type `make check' to run any self-tests that come with
56493f84f4Smrg     the package.
57493f84f4Smrg
58493f84f4Smrg  4. Type `make install' to install the programs and any data files and
59493f84f4Smrg     documentation.
60493f84f4Smrg
61493f84f4Smrg  5. You can remove the program binaries and object files from the
62493f84f4Smrg     source code directory by typing `make clean'.  To also remove the
63493f84f4Smrg     files that `configure' created (so you can compile the package for
64493f84f4Smrg     a different kind of computer), type `make distclean'.  There is
65493f84f4Smrg     also a `make maintainer-clean' target, but that is intended mainly
66493f84f4Smrg     for the package's developers.  If you use it, you may have to get
67493f84f4Smrg     all sorts of other programs in order to regenerate files that came
68493f84f4Smrg     with the distribution.
69493f84f4Smrg
70493f84f4Smrg  6. Often, you can also type `make uninstall' to remove the installed
71493f84f4Smrg     files again.
72493f84f4Smrg
73493f84f4SmrgCompilers and Options
74493f84f4Smrg=====================
75493f84f4Smrg
76493f84f4Smrg   Some systems require unusual options for compilation or linking that
77493f84f4Smrgthe `configure' script does not know about.  Run `./configure --help'
78493f84f4Smrgfor details on some of the pertinent environment variables.
79493f84f4Smrg
80493f84f4Smrg   You can give `configure' initial values for configuration parameters
81493f84f4Smrgby setting variables in the command line or in the environment.  Here
82493f84f4Smrgis an example:
83493f84f4Smrg
84493f84f4Smrg     ./configure CC=c99 CFLAGS=-g LIBS=-lposix
85493f84f4Smrg
86493f84f4Smrg   *Note Defining Variables::, for more details.
87493f84f4Smrg
88493f84f4SmrgCompiling For Multiple Architectures
89493f84f4Smrg====================================
90493f84f4Smrg
91493f84f4Smrg   You can compile the package for more than one kind of computer at the
92493f84f4Smrgsame time, by placing the object files for each architecture in their
93493f84f4Smrgown directory.  To do this, you can use GNU `make'.  `cd' to the
94493f84f4Smrgdirectory where you want the object files and executables to go and run
95493f84f4Smrgthe `configure' script.  `configure' automatically checks for the
96493f84f4Smrgsource code in the directory that `configure' is in and in `..'.
97493f84f4Smrg
98493f84f4Smrg   With a non-GNU `make', it is safer to compile the package for one
99493f84f4Smrgarchitecture at a time in the source code directory.  After you have
100493f84f4Smrginstalled the package for one architecture, use `make distclean' before
101493f84f4Smrgreconfiguring for another architecture.
102493f84f4Smrg
103493f84f4Smrg   On MacOS X 10.5 and later systems, you can create libraries and
104493f84f4Smrgexecutables that work on multiple system types--known as "fat" or
105493f84f4Smrg"universal" binaries--by specifying multiple `-arch' options to the
106493f84f4Smrgcompiler but only a single `-arch' option to the preprocessor.  Like
107493f84f4Smrgthis:
108493f84f4Smrg
109493f84f4Smrg     ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
110493f84f4Smrg                 CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \
111493f84f4Smrg                 CPP="gcc -E" CXXCPP="g++ -E"
112493f84f4Smrg
113493f84f4Smrg   This is not guaranteed to produce working output in all cases, you
114493f84f4Smrgmay have to build one architecture at a time and combine the results
115493f84f4Smrgusing the `lipo' tool if you have problems.
116493f84f4Smrg
117493f84f4SmrgInstallation Names
118493f84f4Smrg==================
119493f84f4Smrg
120493f84f4Smrg   By default, `make install' installs the package's commands under
121493f84f4Smrg`/usr/local/bin', include files under `/usr/local/include', etc.  You
122493f84f4Smrgcan specify an installation prefix other than `/usr/local' by giving
123493f84f4Smrg`configure' the option `--prefix=PREFIX'.
124493f84f4Smrg
125493f84f4Smrg   You can specify separate installation prefixes for
126493f84f4Smrgarchitecture-specific files and architecture-independent files.  If you
127493f84f4Smrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses
128493f84f4SmrgPREFIX as the prefix for installing programs and libraries.
129493f84f4SmrgDocumentation and other data files still use the regular prefix.
130493f84f4Smrg
131493f84f4Smrg   In addition, if you use an unusual directory layout you can give
132493f84f4Smrgoptions like `--bindir=DIR' to specify different values for particular
133493f84f4Smrgkinds of files.  Run `configure --help' for a list of the directories
134493f84f4Smrgyou can set and what kinds of files go in them.
135493f84f4Smrg
136493f84f4Smrg   If the package supports it, you can cause programs to be installed
137493f84f4Smrgwith an extra prefix or suffix on their names by giving `configure' the
138493f84f4Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
139493f84f4Smrg
140493f84f4SmrgOptional Features
141493f84f4Smrg=================
142493f84f4Smrg
143493f84f4Smrg   Some packages pay attention to `--enable-FEATURE' options to
144493f84f4Smrg`configure', where FEATURE indicates an optional part of the package.
145493f84f4SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE
146493f84f4Smrgis something like `gnu-as' or `x' (for the X Window System).  The
147493f84f4Smrg`README' should mention any `--enable-' and `--with-' options that the
148493f84f4Smrgpackage recognizes.
149493f84f4Smrg
150493f84f4Smrg   For packages that use the X Window System, `configure' can usually
151493f84f4Smrgfind the X include and library files automatically, but if it doesn't,
152493f84f4Smrgyou can use the `configure' options `--x-includes=DIR' and
153493f84f4Smrg`--x-libraries=DIR' to specify their locations.
154493f84f4Smrg
155493f84f4SmrgParticular systems
156493f84f4Smrg==================
157493f84f4Smrg
158493f84f4Smrg   On HP-UX, the default C compiler is not ANSI C compatible.  If GNU
159493f84f4SmrgCC is not installed, it is recommended to use the following options in
160493f84f4Smrgorder to use an ANSI C compiler:
161493f84f4Smrg
162493f84f4Smrg     ./configure CC="cc -Ae"
163493f84f4Smrg
164493f84f4Smrgand if that doesn't work, install pre-built binaries of GCC for HP-UX.
165493f84f4Smrg
166493f84f4Smrg   On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot
167493f84f4Smrgparse its `<wchar.h>' header file.  The option `-nodtk' can be used as
168493f84f4Smrga workaround.  If GNU CC is not installed, it is therefore recommended
169493f84f4Smrgto try
170493f84f4Smrg
171493f84f4Smrg     ./configure CC="cc"
172493f84f4Smrg
173493f84f4Smrgand if that doesn't work, try
174493f84f4Smrg
175493f84f4Smrg     ./configure CC="cc -nodtk"
176493f84f4Smrg
177493f84f4SmrgSpecifying the System Type
178493f84f4Smrg==========================
179493f84f4Smrg
180493f84f4Smrg   There may be some features `configure' cannot figure out
181493f84f4Smrgautomatically, but needs to determine by the type of machine the package
182493f84f4Smrgwill run on.  Usually, assuming the package is built to be run on the
183493f84f4Smrg_same_ architectures, `configure' can figure that out, but if it prints
184493f84f4Smrga message saying it cannot guess the machine type, give it the
185493f84f4Smrg`--build=TYPE' option.  TYPE can either be a short name for the system
186493f84f4Smrgtype, such as `sun4', or a canonical name which has the form:
187493f84f4Smrg
188493f84f4Smrg     CPU-COMPANY-SYSTEM
189493f84f4Smrg
190493f84f4Smrgwhere SYSTEM can have one of these forms:
191493f84f4Smrg
192493f84f4Smrg     OS KERNEL-OS
193493f84f4Smrg
194493f84f4Smrg   See the file `config.sub' for the possible values of each field.  If
195493f84f4Smrg`config.sub' isn't included in this package, then this package doesn't
196493f84f4Smrgneed to know the machine type.
197493f84f4Smrg
198493f84f4Smrg   If you are _building_ compiler tools for cross-compiling, you should
199493f84f4Smrguse the option `--target=TYPE' to select the type of system they will
200493f84f4Smrgproduce code for.
201493f84f4Smrg
202493f84f4Smrg   If you want to _use_ a cross compiler, that generates code for a
203493f84f4Smrgplatform different from the build platform, you should specify the
204493f84f4Smrg"host" platform (i.e., that on which the generated programs will
205493f84f4Smrgeventually be run) with `--host=TYPE'.
206493f84f4Smrg
207493f84f4SmrgSharing Defaults
208493f84f4Smrg================
209493f84f4Smrg
210493f84f4Smrg   If you want to set default values for `configure' scripts to share,
211493f84f4Smrgyou can create a site shell script called `config.site' that gives
212493f84f4Smrgdefault values for variables like `CC', `cache_file', and `prefix'.
213493f84f4Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then
214493f84f4Smrg`PREFIX/etc/config.site' if it exists.  Or, you can set the
215493f84f4Smrg`CONFIG_SITE' environment variable to the location of the site script.
216493f84f4SmrgA warning: not all `configure' scripts look for a site script.
217493f84f4Smrg
218493f84f4SmrgDefining Variables
219493f84f4Smrg==================
220493f84f4Smrg
221493f84f4Smrg   Variables not defined in a site shell script can be set in the
222493f84f4Smrgenvironment passed to `configure'.  However, some packages may run
223493f84f4Smrgconfigure again during the build, and the customized values of these
224493f84f4Smrgvariables may be lost.  In order to avoid this problem, you should set
225493f84f4Smrgthem in the `configure' command line, using `VAR=value'.  For example:
226493f84f4Smrg
227493f84f4Smrg     ./configure CC=/usr/local2/bin/gcc
228493f84f4Smrg
229493f84f4Smrgcauses the specified `gcc' to be used as the C compiler (unless it is
230493f84f4Smrgoverridden in the site shell script).
231493f84f4Smrg
232493f84f4SmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to
233493f84f4Smrgan Autoconf bug.  Until the bug is fixed you can use this workaround:
234493f84f4Smrg
235493f84f4Smrg     CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash
236493f84f4Smrg
237493f84f4Smrg`configure' Invocation
238493f84f4Smrg======================
239493f84f4Smrg
240493f84f4Smrg   `configure' recognizes the following options to control how it
241493f84f4Smrgoperates.
242493f84f4Smrg
243493f84f4Smrg`--help'
244493f84f4Smrg`-h'
245493f84f4Smrg     Print a summary of all of the options to `configure', and exit.
246493f84f4Smrg
247493f84f4Smrg`--help=short'
248493f84f4Smrg`--help=recursive'
249493f84f4Smrg     Print a summary of the options unique to this package's
250493f84f4Smrg     `configure', and exit.  The `short' variant lists options used
251493f84f4Smrg     only in the top level, while the `recursive' variant lists options
252493f84f4Smrg     also present in any nested packages.
253493f84f4Smrg
254493f84f4Smrg`--version'
255493f84f4Smrg`-V'
256493f84f4Smrg     Print the version of Autoconf used to generate the `configure'
257493f84f4Smrg     script, and exit.
258493f84f4Smrg
259493f84f4Smrg`--cache-file=FILE'
260493f84f4Smrg     Enable the cache: use and save the results of the tests in FILE,
261493f84f4Smrg     traditionally `config.cache'.  FILE defaults to `/dev/null' to
262493f84f4Smrg     disable caching.
263493f84f4Smrg
264493f84f4Smrg`--config-cache'
265493f84f4Smrg`-C'
266493f84f4Smrg     Alias for `--cache-file=config.cache'.
267493f84f4Smrg
268493f84f4Smrg`--quiet'
269493f84f4Smrg`--silent'
270493f84f4Smrg`-q'
271493f84f4Smrg     Do not print messages saying which checks are being made.  To
272493f84f4Smrg     suppress all normal output, redirect it to `/dev/null' (any error
273493f84f4Smrg     messages will still be shown).
274493f84f4Smrg
275493f84f4Smrg`--srcdir=DIR'
276493f84f4Smrg     Look for the package's source code in directory DIR.  Usually
277493f84f4Smrg     `configure' can determine that directory automatically.
278493f84f4Smrg
279493f84f4Smrg`--prefix=DIR'
280493f84f4Smrg     Use DIR as the installation prefix.  *Note Installation Names::
281493f84f4Smrg     for more details, including other options available for fine-tuning
282493f84f4Smrg     the installation locations.
283493f84f4Smrg
284493f84f4Smrg`--no-create'
285493f84f4Smrg`-n'
286493f84f4Smrg     Run the configure checks, but stop before creating any output
287493f84f4Smrg     files.
288493f84f4Smrg
289493f84f4Smrg`configure' also accepts some other, not widely useful, options.  Run
290493f84f4Smrg`configure --help' for more details.
291493f84f4Smrg
292