160786Sps This file describes how to build and install less using 260786Spsthe "configure" script. This only works on Unix systems. 360786SpsTo install on other systems, read the README file. 460786Sps 560786Sps 660786SpsBasic Installation 760786Sps================== 860786Sps 960786Sps These are generic installation instructions. 1060786Sps 1160786Sps The `configure' shell script attempts to guess correct values for 1260786Spsvarious system-dependent variables used during compilation. It uses 1360786Spsthose values to create a `Makefile' in each directory of the package. 1460786SpsIt may also create one or more `.h' files containing system-dependent 1560786Spsdefinitions. Finally, it creates a shell script `config.status' that 1660786Spsyou can run in the future to recreate the current configuration, a file 1760786Sps`config.cache' that saves the results of its tests to speed up 1860786Spsreconfiguring, and a file `config.log' containing compiler output 1960786Sps(useful mainly for debugging `configure'). 2060786Sps 2160786Sps If you need to do unusual things to compile the package, please try 2260786Spsto figure out how `configure' could check whether to do them, and mail 2360786Spsdiffs or instructions to the address given in the `README' so they can 2460786Spsbe considered for the next release. If at some point `config.cache' 2560786Spscontains results you don't want to keep, you may remove or edit it. 2660786Sps 2760786Sps The file `configure.in' is used to create `configure' by a program 2860786Spscalled `autoconf'. You only need `configure.in' if you want to change 2960786Spsit or regenerate `configure' using a newer version of `autoconf'. 3060786Sps 3160786SpsThe simplest way to compile this package is: 3260786Sps 3360786Sps 1. `cd' to the directory containing the package's source code and type 3460786Sps `./configure' to configure the package for your system. If you're 3560786Sps using `csh' on an old version of System V, you might need to type 3660786Sps `sh ./configure' instead to prevent `csh' from trying to execute 3760786Sps `configure' itself. 3860786Sps 3960786Sps Running `configure' takes awhile. While running, it prints some 4060786Sps messages telling which features it is checking for. 4160786Sps 4260786Sps 2. Type `make' to compile the package. 4360786Sps 4460786Sps 3. Optionally, type `make check' to run any self-tests that come with 4560786Sps the package. 4660786Sps 4760786Sps 4. Type `make install' to install the programs and any data files and 4860786Sps documentation. 4960786Sps 5060786Sps 5. You can remove the program binaries and object files from the 5160786Sps source code directory by typing `make clean'. To also remove the 5260786Sps files that `configure' created (so you can compile the package for 5360786Sps a different kind of computer), type `make distclean'. There is 5460786Sps also a `make maintainer-clean' target, but that is intended mainly 5560786Sps for the package's developers. If you use it, you may have to get 5660786Sps all sorts of other programs in order to regenerate files that came 5760786Sps with the distribution. 5860786Sps 5960786SpsCompilers and Options 6060786Sps===================== 6160786Sps 6260786Sps Some systems require unusual options for compilation or linking that 6360786Spsthe `configure' script does not know about. You can give `configure' 6460786Spsinitial values for variables by setting them in the environment. Using 6560786Spsa Bourne-compatible shell, you can do that on the command line like 6660786Spsthis: 6760786Sps CC=c89 CFLAGS=-O2 LIBS=-lposix ./configure 6860786Sps 6960786SpsOr on systems that have the `env' program, you can do it like this: 7060786Sps env CPPFLAGS=-I/usr/local/include LDFLAGS=-s ./configure 7160786Sps 7260786SpsCompiling For Multiple Architectures 7360786Sps==================================== 7460786Sps 7560786Sps You can compile the package for more than one kind of computer at the 7660786Spssame time, by placing the object files for each architecture in their 7760786Spsown directory. To do this, you must use a version of `make' that 7860786Spssupports the `VPATH' variable, such as GNU `make'. `cd' to the 7960786Spsdirectory where you want the object files and executables to go and run 8060786Spsthe `configure' script. `configure' automatically checks for the 8160786Spssource code in the directory that `configure' is in and in `..'. 8260786Sps 8360786Sps If you have to use a `make' that does not supports the `VPATH' 8460786Spsvariable, you have to compile the package for one architecture at a time 8560786Spsin the source code directory. After you have installed the package for 8660786Spsone architecture, use `make distclean' before reconfiguring for another 8760786Spsarchitecture. 8860786Sps 8960786SpsInstallation Names 9060786Sps================== 9160786Sps 9260786Sps By default, `make install' will install the package's files in 9360786Sps`/usr/local/bin', `/usr/local/man', etc. You can specify an 9460786Spsinstallation prefix other than `/usr/local' by giving `configure' the 9560786Spsoption `--prefix=PATH'. 9660786Sps 9760786Sps You can specify separate installation prefixes for 9860786Spsarchitecture-specific files and architecture-independent files. If you 9960786Spsgive `configure' the option `--exec-prefix=PATH', the package will use 10060786SpsPATH as the prefix for installing programs and libraries. 10160786SpsDocumentation and other data files will still use the regular prefix. 10260786Sps 10360786Sps In addition, if you use an unusual directory layout you can give 10460786Spsoptions like `--bindir=PATH' to specify different values for particular 10560786Spskinds of files. Run `configure --help' for a list of the directories 10660786Spsyou can set and what kinds of files go in them. 10760786Sps 10860786Sps If the package supports it, you can cause programs to be installed 10960786Spswith an extra prefix or suffix on their names by giving `configure' the 11060786Spsoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. 11160786Sps 11260786SpsOptional Features 11360786Sps================= 11460786Sps 11560786Sps Some packages pay attention to `--enable-FEATURE' options to 11660786Sps`configure', where FEATURE indicates an optional part of the package. 11760786SpsThey may also pay attention to `--with-PACKAGE' options, where PACKAGE 11860786Spsis something like `gnu-as' or `x' (for the X Window System). The 11960786Sps`README' should mention any `--enable-' and `--with-' options that the 12060786Spspackage recognizes. 12160786Sps 12260786Sps For packages that use the X Window System, `configure' can usually 12360786Spsfind the X include and library files automatically, but if it doesn't, 12460786Spsyou can use the `configure' options `--x-includes=DIR' and 12560786Sps`--x-libraries=DIR' to specify their locations. 12660786Sps 12760786SpsSpecifying the System Type 12860786Sps========================== 12960786Sps 13060786Sps There may be some features `configure' can not figure out 13160786Spsautomatically, but needs to determine by the type of host the package 13260786Spswill run on. Usually `configure' can figure that out, but if it prints 13360786Spsa message saying it can not guess the host type, give it the 13460786Sps`--host=TYPE' option. TYPE can either be a short name for the system 13560786Spstype, such as `sun4', or a canonical name with three fields: 13660786Sps CPU-COMPANY-SYSTEM 13760786Sps 13860786SpsSee the file `config.sub' for the possible values of each field. If 13960786Sps`config.sub' isn't included in this package, then this package doesn't 14060786Spsneed to know the host type. 14160786Sps 14260786Sps If you are building compiler tools for cross-compiling, you can also 14360786Spsuse the `--target=TYPE' option to select the type of system they will 14460786Spsproduce code for and the `--build=TYPE' option to select the type of 14560786Spssystem on which you are compiling the package. 14660786Sps 14760786SpsSharing Defaults 14860786Sps================ 14960786Sps 15060786Sps If you want to set default values for `configure' scripts to share, 15160786Spsyou can create a site shell script called `config.site' that gives 15260786Spsdefault values for variables like `CC', `cache_file', and `prefix'. 15360786Sps`configure' looks for `PREFIX/share/config.site' if it exists, then 15460786Sps`PREFIX/etc/config.site' if it exists. Or, you can set the 15560786Sps`CONFIG_SITE' environment variable to the location of the site script. 15660786SpsA warning: not all `configure' scripts look for a site script. 15760786Sps 15860786SpsOperation Controls 15960786Sps================== 16060786Sps 16160786Sps `configure' recognizes the following options to control how it 16260786Spsoperates. 16360786Sps 16460786Sps`--cache-file=FILE' 16560786Sps Use and save the results of the tests in FILE instead of 16660786Sps `./config.cache'. Set FILE to `/dev/null' to disable caching, for 16760786Sps debugging `configure'. 16860786Sps 16960786Sps`--help' 17060786Sps Print a summary of the options to `configure', and exit. 17160786Sps 17260786Sps`--quiet' 17360786Sps`--silent' 17460786Sps`-q' 17560786Sps Do not print messages saying which checks are being made. 17660786Sps 17760786Sps`--srcdir=DIR' 17860786Sps Look for the package's source code in directory DIR. Usually 17960786Sps `configure' can determine that directory automatically. 18060786Sps 18160786Sps`--version' 18260786Sps Print the version of Autoconf used to generate the `configure' 18360786Sps script, and exit. 18460786Sps 18560786Sps`configure' also accepts some other, not widely useful, options. 18660786Sps 187