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