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