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