INSTALL revision 6c321187
16c321187SmrgCopyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002 Free Software 26c321187SmrgFoundation, Inc. 36c321187Smrg 46c321187Smrg This file is free documentation; the Free Software Foundation gives 56c321187Smrgunlimited permission to copy, distribute and modify it. 66c321187Smrg 76c321187SmrgBasic Installation 86c321187Smrg================== 96c321187Smrg 106c321187Smrg These are generic installation instructions. 116c321187Smrg 126c321187Smrg The `configure' shell script attempts to guess correct values for 136c321187Smrgvarious system-dependent variables used during compilation. It uses 146c321187Smrgthose values to create a `Makefile' in each directory of the package. 156c321187SmrgIt may also create one or more `.h' files containing system-dependent 166c321187Smrgdefinitions. Finally, it creates a shell script `config.status' that 176c321187Smrgyou can run in the future to recreate the current configuration, and a 186c321187Smrgfile `config.log' containing compiler output (useful mainly for 196c321187Smrgdebugging `configure'). 206c321187Smrg 216c321187Smrg It can also use an optional file (typically called `config.cache' 226c321187Smrgand enabled with `--cache-file=config.cache' or simply `-C') that saves 236c321187Smrgthe results of its tests to speed up reconfiguring. (Caching is 246c321187Smrgdisabled by default to prevent problems with accidental use of stale 256c321187Smrgcache files.) 266c321187Smrg 276c321187Smrg If you need to do unusual things to compile the package, please try 286c321187Smrgto figure out how `configure' could check whether to do them, and mail 296c321187Smrgdiffs or instructions to the address given in the `README' so they can 306c321187Smrgbe considered for the next release. If you are using the cache, and at 316c321187Smrgsome point `config.cache' contains results you don't want to keep, you 326c321187Smrgmay remove or edit it. 336c321187Smrg 346c321187Smrg The file `configure.ac' (or `configure.in') is used to create 356c321187Smrg`configure' by a program called `autoconf'. You only need 366c321187Smrg`configure.ac' if you want to change it or regenerate `configure' using 376c321187Smrga newer version of `autoconf'. 386c321187Smrg 396c321187SmrgThe simplest way to compile this package is: 406c321187Smrg 416c321187Smrg 1. `cd' to the directory containing the package's source code and type 426c321187Smrg `./configure' to configure the package for your system. If you're 436c321187Smrg using `csh' on an old version of System V, you might need to type 446c321187Smrg `sh ./configure' instead to prevent `csh' from trying to execute 456c321187Smrg `configure' itself. 466c321187Smrg 476c321187Smrg Running `configure' takes awhile. While running, it prints some 486c321187Smrg messages telling which features it is checking for. 496c321187Smrg 506c321187Smrg 2. Type `make' to compile the package. 516c321187Smrg 526c321187Smrg 3. Optionally, type `make check' to run any self-tests that come with 536c321187Smrg the package. 546c321187Smrg 556c321187Smrg 4. Type `make install' to install the programs and any data files and 566c321187Smrg documentation. 576c321187Smrg 586c321187Smrg 5. You can remove the program binaries and object files from the 596c321187Smrg source code directory by typing `make clean'. To also remove the 606c321187Smrg files that `configure' created (so you can compile the package for 616c321187Smrg a different kind of computer), type `make distclean'. There is 626c321187Smrg also a `make maintainer-clean' target, but that is intended mainly 636c321187Smrg for the package's developers. If you use it, you may have to get 646c321187Smrg all sorts of other programs in order to regenerate files that came 656c321187Smrg with the distribution. 666c321187Smrg 676c321187SmrgCompilers and Options 686c321187Smrg===================== 696c321187Smrg 706c321187Smrg Some systems require unusual options for compilation or linking that 716c321187Smrgthe `configure' script does not know about. Run `./configure --help' 726c321187Smrgfor details on some of the pertinent environment variables. 736c321187Smrg 746c321187Smrg You can give `configure' initial values for configuration parameters 756c321187Smrgby setting variables in the command line or in the environment. Here 766c321187Smrgis an example: 776c321187Smrg 786c321187Smrg ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix 796c321187Smrg 806c321187Smrg *Note Defining Variables::, for more details. 816c321187Smrg 826c321187SmrgCompiling For Multiple Architectures 836c321187Smrg==================================== 846c321187Smrg 856c321187Smrg You can compile the package for more than one kind of computer at the 866c321187Smrgsame time, by placing the object files for each architecture in their 876c321187Smrgown directory. To do this, you must use a version of `make' that 886c321187Smrgsupports the `VPATH' variable, such as GNU `make'. `cd' to the 896c321187Smrgdirectory where you want the object files and executables to go and run 906c321187Smrgthe `configure' script. `configure' automatically checks for the 916c321187Smrgsource code in the directory that `configure' is in and in `..'. 926c321187Smrg 936c321187Smrg If you have to use a `make' that does not support the `VPATH' 946c321187Smrgvariable, you have to compile the package for one architecture at a 956c321187Smrgtime in the source code directory. After you have installed the 966c321187Smrgpackage for one architecture, use `make distclean' before reconfiguring 976c321187Smrgfor another architecture. 986c321187Smrg 996c321187SmrgInstallation Names 1006c321187Smrg================== 1016c321187Smrg 1026c321187Smrg By default, `make install' will install the package's files in 1036c321187Smrg`/usr/local/bin', `/usr/local/man', etc. You can specify an 1046c321187Smrginstallation prefix other than `/usr/local' by giving `configure' the 1056c321187Smrgoption `--prefix=PATH'. 1066c321187Smrg 1076c321187Smrg You can specify separate installation prefixes for 1086c321187Smrgarchitecture-specific files and architecture-independent files. If you 1096c321187Smrggive `configure' the option `--exec-prefix=PATH', the package will use 1106c321187SmrgPATH as the prefix for installing programs and libraries. 1116c321187SmrgDocumentation and other data files will still use the regular prefix. 1126c321187Smrg 1136c321187Smrg In addition, if you use an unusual directory layout you can give 1146c321187Smrgoptions like `--bindir=PATH' to specify different values for particular 1156c321187Smrgkinds of files. Run `configure --help' for a list of the directories 1166c321187Smrgyou can set and what kinds of files go in them. 1176c321187Smrg 1186c321187Smrg If the package supports it, you can cause programs to be installed 1196c321187Smrgwith an extra prefix or suffix on their names by giving `configure' the 1206c321187Smrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. 1216c321187Smrg 1226c321187SmrgOptional Features 1236c321187Smrg================= 1246c321187Smrg 1256c321187Smrg Some packages pay attention to `--enable-FEATURE' options to 1266c321187Smrg`configure', where FEATURE indicates an optional part of the package. 1276c321187SmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE 1286c321187Smrgis something like `gnu-as' or `x' (for the X Window System). The 1296c321187Smrg`README' should mention any `--enable-' and `--with-' options that the 1306c321187Smrgpackage recognizes. 1316c321187Smrg 1326c321187Smrg For packages that use the X Window System, `configure' can usually 1336c321187Smrgfind the X include and library files automatically, but if it doesn't, 1346c321187Smrgyou can use the `configure' options `--x-includes=DIR' and 1356c321187Smrg`--x-libraries=DIR' to specify their locations. 1366c321187Smrg 1376c321187SmrgSpecifying the System Type 1386c321187Smrg========================== 1396c321187Smrg 1406c321187Smrg There may be some features `configure' cannot figure out 1416c321187Smrgautomatically, but needs to determine by the type of machine the package 1426c321187Smrgwill run on. Usually, assuming the package is built to be run on the 1436c321187Smrg_same_ architectures, `configure' can figure that out, but if it prints 1446c321187Smrga message saying it cannot guess the machine type, give it the 1456c321187Smrg`--build=TYPE' option. TYPE can either be a short name for the system 1466c321187Smrgtype, such as `sun4', or a canonical name which has the form: 1476c321187Smrg 1486c321187Smrg CPU-COMPANY-SYSTEM 1496c321187Smrg 1506c321187Smrgwhere SYSTEM can have one of these forms: 1516c321187Smrg 1526c321187Smrg OS KERNEL-OS 1536c321187Smrg 1546c321187Smrg See the file `config.sub' for the possible values of each field. If 1556c321187Smrg`config.sub' isn't included in this package, then this package doesn't 1566c321187Smrgneed to know the machine type. 1576c321187Smrg 1586c321187Smrg If you are _building_ compiler tools for cross-compiling, you should 1596c321187Smrguse the `--target=TYPE' option to select the type of system they will 1606c321187Smrgproduce code for. 1616c321187Smrg 1626c321187Smrg If you want to _use_ a cross compiler, that generates code for a 1636c321187Smrgplatform different from the build platform, you should specify the 1646c321187Smrg"host" platform (i.e., that on which the generated programs will 1656c321187Smrgeventually be run) with `--host=TYPE'. 1666c321187Smrg 1676c321187SmrgSharing Defaults 1686c321187Smrg================ 1696c321187Smrg 1706c321187Smrg If you want to set default values for `configure' scripts to share, 1716c321187Smrgyou can create a site shell script called `config.site' that gives 1726c321187Smrgdefault values for variables like `CC', `cache_file', and `prefix'. 1736c321187Smrg`configure' looks for `PREFIX/share/config.site' if it exists, then 1746c321187Smrg`PREFIX/etc/config.site' if it exists. Or, you can set the 1756c321187Smrg`CONFIG_SITE' environment variable to the location of the site script. 1766c321187SmrgA warning: not all `configure' scripts look for a site script. 1776c321187Smrg 1786c321187SmrgDefining Variables 1796c321187Smrg================== 1806c321187Smrg 1816c321187Smrg Variables not defined in a site shell script can be set in the 1826c321187Smrgenvironment passed to `configure'. However, some packages may run 1836c321187Smrgconfigure again during the build, and the customized values of these 1846c321187Smrgvariables may be lost. In order to avoid this problem, you should set 1856c321187Smrgthem in the `configure' command line, using `VAR=value'. For example: 1866c321187Smrg 1876c321187Smrg ./configure CC=/usr/local2/bin/gcc 1886c321187Smrg 1896c321187Smrgwill cause the specified gcc to be used as the C compiler (unless it is 1906c321187Smrgoverridden in the site shell script). 1916c321187Smrg 1926c321187Smrg`configure' Invocation 1936c321187Smrg====================== 1946c321187Smrg 1956c321187Smrg `configure' recognizes the following options to control how it 1966c321187Smrgoperates. 1976c321187Smrg 1986c321187Smrg`--help' 1996c321187Smrg`-h' 2006c321187Smrg Print a summary of the options to `configure', and exit. 2016c321187Smrg 2026c321187Smrg`--version' 2036c321187Smrg`-V' 2046c321187Smrg Print the version of Autoconf used to generate the `configure' 2056c321187Smrg script, and exit. 2066c321187Smrg 2076c321187Smrg`--cache-file=FILE' 2086c321187Smrg Enable the cache: use and save the results of the tests in FILE, 2096c321187Smrg traditionally `config.cache'. FILE defaults to `/dev/null' to 2106c321187Smrg disable caching. 2116c321187Smrg 2126c321187Smrg`--config-cache' 2136c321187Smrg`-C' 2146c321187Smrg Alias for `--cache-file=config.cache'. 2156c321187Smrg 2166c321187Smrg`--quiet' 2176c321187Smrg`--silent' 2186c321187Smrg`-q' 2196c321187Smrg Do not print messages saying which checks are being made. To 2206c321187Smrg suppress all normal output, redirect it to `/dev/null' (any error 2216c321187Smrg messages will still be shown). 2226c321187Smrg 2236c321187Smrg`--srcdir=DIR' 2246c321187Smrg Look for the package's source code in directory DIR. Usually 2256c321187Smrg `configure' can determine that directory automatically. 2266c321187Smrg 2276c321187Smrg`configure' also accepts some other, not widely useful, options. Run 2286c321187Smrg`configure --help' for more details. 2296c321187Smrg 230