148af84faSmrgInstallation Instructions 248af84faSmrg************************* 348af84faSmrg 4c6a6acfbSmrgCopyright (C) 1994-1996, 1999-2002, 2004-2011 Free Software Foundation, 5c6a6acfbSmrgInc. 648af84faSmrg 7c6a6acfbSmrg Copying and distribution of this file, with or without modification, 8c6a6acfbSmrgare permitted in any medium without royalty provided the copyright 9c6a6acfbSmrgnotice and this notice are preserved. This file is offered as-is, 10c6a6acfbSmrgwithout warranty of any kind. 1148af84faSmrg 1248af84faSmrgBasic Installation 1348af84faSmrg================== 1448af84faSmrg 1548af84faSmrg Briefly, the shell commands `./configure; make; make install' should 1648af84faSmrgconfigure, build, and install this package. The following 1748af84faSmrgmore-detailed instructions are generic; see the `README' file for 18c6a6acfbSmrginstructions specific to this package. Some packages provide this 19c6a6acfbSmrg`INSTALL' file but do not implement all of the features documented 20c6a6acfbSmrgbelow. The lack of an optional feature in a given package is not 21c6a6acfbSmrgnecessarily a bug. More recommendations for GNU packages can be found 22c6a6acfbSmrgin *note Makefile Conventions: (standards)Makefile Conventions. 2348af84faSmrg 2448af84faSmrg The `configure' shell script attempts to guess correct values for 2548af84faSmrgvarious system-dependent variables used during compilation. It uses 2648af84faSmrgthose values to create a `Makefile' in each directory of the package. 2748af84faSmrgIt may also create one or more `.h' files containing system-dependent 2848af84faSmrgdefinitions. Finally, it creates a shell script `config.status' that 2948af84faSmrgyou can run in the future to recreate the current configuration, and a 3048af84faSmrgfile `config.log' containing compiler output (useful mainly for 3148af84faSmrgdebugging `configure'). 3248af84faSmrg 3348af84faSmrg It can also use an optional file (typically called `config.cache' 3448af84faSmrgand enabled with `--cache-file=config.cache' or simply `-C') that saves 3548af84faSmrgthe results of its tests to speed up reconfiguring. Caching is 3648af84faSmrgdisabled by default to prevent problems with accidental use of stale 3748af84faSmrgcache files. 3848af84faSmrg 3948af84faSmrg If you need to do unusual things to compile the package, please try 4048af84faSmrgto figure out how `configure' could check whether to do them, and mail 4148af84faSmrgdiffs or instructions to the address given in the `README' so they can 4248af84faSmrgbe considered for the next release. If you are using the cache, and at 4348af84faSmrgsome point `config.cache' contains results you don't want to keep, you 4448af84faSmrgmay remove or edit it. 4548af84faSmrg 4648af84faSmrg The file `configure.ac' (or `configure.in') is used to create 4748af84faSmrg`configure' by a program called `autoconf'. You need `configure.ac' if 4848af84faSmrgyou want to change it or regenerate `configure' using a newer version 4948af84faSmrgof `autoconf'. 5048af84faSmrg 51c6a6acfbSmrg The simplest way to compile this package is: 5248af84faSmrg 5348af84faSmrg 1. `cd' to the directory containing the package's source code and type 5448af84faSmrg `./configure' to configure the package for your system. 5548af84faSmrg 5648af84faSmrg Running `configure' might take a while. While running, it prints 5748af84faSmrg some messages telling which features it is checking for. 5848af84faSmrg 5948af84faSmrg 2. Type `make' to compile the package. 6048af84faSmrg 6148af84faSmrg 3. Optionally, type `make check' to run any self-tests that come with 62c6a6acfbSmrg the package, generally using the just-built uninstalled binaries. 6348af84faSmrg 6448af84faSmrg 4. Type `make install' to install the programs and any data files and 65c6a6acfbSmrg documentation. When installing into a prefix owned by root, it is 66c6a6acfbSmrg recommended that the package be configured and built as a regular 67c6a6acfbSmrg user, and only the `make install' phase executed with root 68c6a6acfbSmrg privileges. 69c6a6acfbSmrg 70c6a6acfbSmrg 5. Optionally, type `make installcheck' to repeat any self-tests, but 71c6a6acfbSmrg this time using the binaries in their final installed location. 72c6a6acfbSmrg This target does not install anything. Running this target as a 73c6a6acfbSmrg regular user, particularly if the prior `make install' required 74c6a6acfbSmrg root privileges, verifies that the installation completed 75c6a6acfbSmrg correctly. 76c6a6acfbSmrg 77c6a6acfbSmrg 6. You can remove the program binaries and object files from the 7848af84faSmrg source code directory by typing `make clean'. To also remove the 7948af84faSmrg files that `configure' created (so you can compile the package for 8048af84faSmrg a different kind of computer), type `make distclean'. There is 8148af84faSmrg also a `make maintainer-clean' target, but that is intended mainly 8248af84faSmrg for the package's developers. If you use it, you may have to get 8348af84faSmrg all sorts of other programs in order to regenerate files that came 8448af84faSmrg with the distribution. 8548af84faSmrg 86c6a6acfbSmrg 7. Often, you can also type `make uninstall' to remove the installed 87c6a6acfbSmrg files again. In practice, not all packages have tested that 88c6a6acfbSmrg uninstallation works correctly, even though it is required by the 89c6a6acfbSmrg GNU Coding Standards. 90c6a6acfbSmrg 91c6a6acfbSmrg 8. Some packages, particularly those that use Automake, provide `make 92c6a6acfbSmrg distcheck', which can by used by developers to test that all other 93c6a6acfbSmrg targets like `make install' and `make uninstall' work correctly. 94c6a6acfbSmrg This target is generally not run by end users. 9548af84faSmrg 9648af84faSmrgCompilers and Options 9748af84faSmrg===================== 9848af84faSmrg 9948af84faSmrg Some systems require unusual options for compilation or linking that 10048af84faSmrgthe `configure' script does not know about. Run `./configure --help' 10148af84faSmrgfor details on some of the pertinent environment variables. 10248af84faSmrg 10348af84faSmrg You can give `configure' initial values for configuration parameters 10448af84faSmrgby setting variables in the command line or in the environment. Here 10548af84faSmrgis an example: 10648af84faSmrg 10748af84faSmrg ./configure CC=c99 CFLAGS=-g LIBS=-lposix 10848af84faSmrg 10948af84faSmrg *Note Defining Variables::, for more details. 11048af84faSmrg 11148af84faSmrgCompiling For Multiple Architectures 11248af84faSmrg==================================== 11348af84faSmrg 11448af84faSmrg You can compile the package for more than one kind of computer at the 11548af84faSmrgsame time, by placing the object files for each architecture in their 11648af84faSmrgown directory. To do this, you can use GNU `make'. `cd' to the 11748af84faSmrgdirectory where you want the object files and executables to go and run 11848af84faSmrgthe `configure' script. `configure' automatically checks for the 119c6a6acfbSmrgsource code in the directory that `configure' is in and in `..'. This 120c6a6acfbSmrgis known as a "VPATH" build. 12148af84faSmrg 12248af84faSmrg With a non-GNU `make', it is safer to compile the package for one 12348af84faSmrgarchitecture at a time in the source code directory. After you have 12448af84faSmrginstalled the package for one architecture, use `make distclean' before 12548af84faSmrgreconfiguring for another architecture. 12648af84faSmrg 12748af84faSmrg On MacOS X 10.5 and later systems, you can create libraries and 12848af84faSmrgexecutables that work on multiple system types--known as "fat" or 12948af84faSmrg"universal" binaries--by specifying multiple `-arch' options to the 13048af84faSmrgcompiler but only a single `-arch' option to the preprocessor. Like 13148af84faSmrgthis: 13248af84faSmrg 13348af84faSmrg ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ 13448af84faSmrg CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ 13548af84faSmrg CPP="gcc -E" CXXCPP="g++ -E" 13648af84faSmrg 13748af84faSmrg This is not guaranteed to produce working output in all cases, you 13848af84faSmrgmay have to build one architecture at a time and combine the results 13948af84faSmrgusing the `lipo' tool if you have problems. 14048af84faSmrg 14148af84faSmrgInstallation Names 14248af84faSmrg================== 14348af84faSmrg 14448af84faSmrg By default, `make install' installs the package's commands under 14548af84faSmrg`/usr/local/bin', include files under `/usr/local/include', etc. You 14648af84faSmrgcan specify an installation prefix other than `/usr/local' by giving 147c6a6acfbSmrg`configure' the option `--prefix=PREFIX', where PREFIX must be an 148c6a6acfbSmrgabsolute file name. 14948af84faSmrg 15048af84faSmrg You can specify separate installation prefixes for 15148af84faSmrgarchitecture-specific files and architecture-independent files. If you 15248af84faSmrgpass the option `--exec-prefix=PREFIX' to `configure', the package uses 15348af84faSmrgPREFIX as the prefix for installing programs and libraries. 15448af84faSmrgDocumentation and other data files still use the regular prefix. 15548af84faSmrg 15648af84faSmrg In addition, if you use an unusual directory layout you can give 15748af84faSmrgoptions like `--bindir=DIR' to specify different values for particular 15848af84faSmrgkinds of files. Run `configure --help' for a list of the directories 159c6a6acfbSmrgyou can set and what kinds of files go in them. In general, the 160c6a6acfbSmrgdefault for these options is expressed in terms of `${prefix}', so that 161c6a6acfbSmrgspecifying just `--prefix' will affect all of the other directory 162c6a6acfbSmrgspecifications that were not explicitly provided. 163c6a6acfbSmrg 164c6a6acfbSmrg The most portable way to affect installation locations is to pass the 165c6a6acfbSmrgcorrect locations to `configure'; however, many packages provide one or 166c6a6acfbSmrgboth of the following shortcuts of passing variable assignments to the 167c6a6acfbSmrg`make install' command line to change installation locations without 168c6a6acfbSmrghaving to reconfigure or recompile. 169c6a6acfbSmrg 170c6a6acfbSmrg The first method involves providing an override variable for each 171c6a6acfbSmrgaffected directory. For example, `make install 172c6a6acfbSmrgprefix=/alternate/directory' will choose an alternate location for all 173c6a6acfbSmrgdirectory configuration variables that were expressed in terms of 174c6a6acfbSmrg`${prefix}'. Any directories that were specified during `configure', 175c6a6acfbSmrgbut not in terms of `${prefix}', must each be overridden at install 176c6a6acfbSmrgtime for the entire installation to be relocated. The approach of 177c6a6acfbSmrgmakefile variable overrides for each directory variable is required by 178c6a6acfbSmrgthe GNU Coding Standards, and ideally causes no recompilation. 179c6a6acfbSmrgHowever, some platforms have known limitations with the semantics of 180c6a6acfbSmrgshared libraries that end up requiring recompilation when using this 181c6a6acfbSmrgmethod, particularly noticeable in packages that use GNU Libtool. 182c6a6acfbSmrg 183c6a6acfbSmrg The second method involves providing the `DESTDIR' variable. For 184c6a6acfbSmrgexample, `make install DESTDIR=/alternate/directory' will prepend 185c6a6acfbSmrg`/alternate/directory' before all installation names. The approach of 186c6a6acfbSmrg`DESTDIR' overrides is not required by the GNU Coding Standards, and 187c6a6acfbSmrgdoes not work on platforms that have drive letters. On the other hand, 188c6a6acfbSmrgit does better at avoiding recompilation issues, and works well even 189c6a6acfbSmrgwhen some directory options were not specified in terms of `${prefix}' 190c6a6acfbSmrgat `configure' time. 191c6a6acfbSmrg 192c6a6acfbSmrgOptional Features 193c6a6acfbSmrg================= 19448af84faSmrg 19548af84faSmrg If the package supports it, you can cause programs to be installed 19648af84faSmrgwith an extra prefix or suffix on their names by giving `configure' the 19748af84faSmrgoption `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. 19848af84faSmrg 19948af84faSmrg Some packages pay attention to `--enable-FEATURE' options to 20048af84faSmrg`configure', where FEATURE indicates an optional part of the package. 20148af84faSmrgThey may also pay attention to `--with-PACKAGE' options, where PACKAGE 20248af84faSmrgis something like `gnu-as' or `x' (for the X Window System). The 20348af84faSmrg`README' should mention any `--enable-' and `--with-' options that the 20448af84faSmrgpackage recognizes. 20548af84faSmrg 20648af84faSmrg For packages that use the X Window System, `configure' can usually 20748af84faSmrgfind the X include and library files automatically, but if it doesn't, 20848af84faSmrgyou can use the `configure' options `--x-includes=DIR' and 20948af84faSmrg`--x-libraries=DIR' to specify their locations. 21048af84faSmrg 211c6a6acfbSmrg Some packages offer the ability to configure how verbose the 212c6a6acfbSmrgexecution of `make' will be. For these packages, running `./configure 213c6a6acfbSmrg--enable-silent-rules' sets the default to minimal output, which can be 214c6a6acfbSmrgoverridden with `make V=1'; while running `./configure 215c6a6acfbSmrg--disable-silent-rules' sets the default to verbose, which can be 216c6a6acfbSmrgoverridden with `make V=0'. 217c6a6acfbSmrg 21848af84faSmrgParticular systems 21948af84faSmrg================== 22048af84faSmrg 22148af84faSmrg On HP-UX, the default C compiler is not ANSI C compatible. If GNU 22248af84faSmrgCC is not installed, it is recommended to use the following options in 22348af84faSmrgorder to use an ANSI C compiler: 22448af84faSmrg 225c6a6acfbSmrg ./configure CC="cc -Ae -D_XOPEN_SOURCE=500" 22648af84faSmrg 22748af84faSmrgand if that doesn't work, install pre-built binaries of GCC for HP-UX. 22848af84faSmrg 229c6a6acfbSmrg HP-UX `make' updates targets which have the same time stamps as 230c6a6acfbSmrgtheir prerequisites, which makes it generally unusable when shipped 231c6a6acfbSmrggenerated files such as `configure' are involved. Use GNU `make' 232c6a6acfbSmrginstead. 233c6a6acfbSmrg 23448af84faSmrg On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot 23548af84faSmrgparse its `<wchar.h>' header file. The option `-nodtk' can be used as 23648af84faSmrga workaround. If GNU CC is not installed, it is therefore recommended 23748af84faSmrgto try 23848af84faSmrg 23948af84faSmrg ./configure CC="cc" 24048af84faSmrg 24148af84faSmrgand if that doesn't work, try 24248af84faSmrg 24348af84faSmrg ./configure CC="cc -nodtk" 24448af84faSmrg 245c6a6acfbSmrg On Solaris, don't put `/usr/ucb' early in your `PATH'. This 246c6a6acfbSmrgdirectory contains several dysfunctional programs; working variants of 247c6a6acfbSmrgthese programs are available in `/usr/bin'. So, if you need `/usr/ucb' 248c6a6acfbSmrgin your `PATH', put it _after_ `/usr/bin'. 249c6a6acfbSmrg 250c6a6acfbSmrg On Haiku, software installed for all users goes in `/boot/common', 251c6a6acfbSmrgnot `/usr/local'. It is recommended to use the following options: 252c6a6acfbSmrg 253c6a6acfbSmrg ./configure --prefix=/boot/common 254c6a6acfbSmrg 25548af84faSmrgSpecifying the System Type 25648af84faSmrg========================== 25748af84faSmrg 25848af84faSmrg There may be some features `configure' cannot figure out 25948af84faSmrgautomatically, but needs to determine by the type of machine the package 26048af84faSmrgwill run on. Usually, assuming the package is built to be run on the 26148af84faSmrg_same_ architectures, `configure' can figure that out, but if it prints 26248af84faSmrga message saying it cannot guess the machine type, give it the 26348af84faSmrg`--build=TYPE' option. TYPE can either be a short name for the system 26448af84faSmrgtype, such as `sun4', or a canonical name which has the form: 26548af84faSmrg 26648af84faSmrg CPU-COMPANY-SYSTEM 26748af84faSmrg 26848af84faSmrgwhere SYSTEM can have one of these forms: 26948af84faSmrg 270c6a6acfbSmrg OS 271c6a6acfbSmrg KERNEL-OS 27248af84faSmrg 27348af84faSmrg See the file `config.sub' for the possible values of each field. If 27448af84faSmrg`config.sub' isn't included in this package, then this package doesn't 27548af84faSmrgneed to know the machine type. 27648af84faSmrg 27748af84faSmrg If you are _building_ compiler tools for cross-compiling, you should 27848af84faSmrguse the option `--target=TYPE' to select the type of system they will 27948af84faSmrgproduce code for. 28048af84faSmrg 28148af84faSmrg If you want to _use_ a cross compiler, that generates code for a 28248af84faSmrgplatform different from the build platform, you should specify the 28348af84faSmrg"host" platform (i.e., that on which the generated programs will 28448af84faSmrgeventually be run) with `--host=TYPE'. 28548af84faSmrg 28648af84faSmrgSharing Defaults 28748af84faSmrg================ 28848af84faSmrg 28948af84faSmrg If you want to set default values for `configure' scripts to share, 29048af84faSmrgyou can create a site shell script called `config.site' that gives 29148af84faSmrgdefault values for variables like `CC', `cache_file', and `prefix'. 29248af84faSmrg`configure' looks for `PREFIX/share/config.site' if it exists, then 29348af84faSmrg`PREFIX/etc/config.site' if it exists. Or, you can set the 29448af84faSmrg`CONFIG_SITE' environment variable to the location of the site script. 29548af84faSmrgA warning: not all `configure' scripts look for a site script. 29648af84faSmrg 29748af84faSmrgDefining Variables 29848af84faSmrg================== 29948af84faSmrg 30048af84faSmrg Variables not defined in a site shell script can be set in the 30148af84faSmrgenvironment passed to `configure'. However, some packages may run 30248af84faSmrgconfigure again during the build, and the customized values of these 30348af84faSmrgvariables may be lost. In order to avoid this problem, you should set 30448af84faSmrgthem in the `configure' command line, using `VAR=value'. For example: 30548af84faSmrg 30648af84faSmrg ./configure CC=/usr/local2/bin/gcc 30748af84faSmrg 30848af84faSmrgcauses the specified `gcc' to be used as the C compiler (unless it is 30948af84faSmrgoverridden in the site shell script). 31048af84faSmrg 31148af84faSmrgUnfortunately, this technique does not work for `CONFIG_SHELL' due to 31248af84faSmrgan Autoconf bug. Until the bug is fixed you can use this workaround: 31348af84faSmrg 31448af84faSmrg CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash 31548af84faSmrg 31648af84faSmrg`configure' Invocation 31748af84faSmrg====================== 31848af84faSmrg 31948af84faSmrg `configure' recognizes the following options to control how it 32048af84faSmrgoperates. 32148af84faSmrg 32248af84faSmrg`--help' 32348af84faSmrg`-h' 32448af84faSmrg Print a summary of all of the options to `configure', and exit. 32548af84faSmrg 32648af84faSmrg`--help=short' 32748af84faSmrg`--help=recursive' 32848af84faSmrg Print a summary of the options unique to this package's 32948af84faSmrg `configure', and exit. The `short' variant lists options used 33048af84faSmrg only in the top level, while the `recursive' variant lists options 33148af84faSmrg also present in any nested packages. 33248af84faSmrg 33348af84faSmrg`--version' 33448af84faSmrg`-V' 33548af84faSmrg Print the version of Autoconf used to generate the `configure' 33648af84faSmrg script, and exit. 33748af84faSmrg 33848af84faSmrg`--cache-file=FILE' 33948af84faSmrg Enable the cache: use and save the results of the tests in FILE, 34048af84faSmrg traditionally `config.cache'. FILE defaults to `/dev/null' to 34148af84faSmrg disable caching. 34248af84faSmrg 34348af84faSmrg`--config-cache' 34448af84faSmrg`-C' 34548af84faSmrg Alias for `--cache-file=config.cache'. 34648af84faSmrg 34748af84faSmrg`--quiet' 34848af84faSmrg`--silent' 34948af84faSmrg`-q' 35048af84faSmrg Do not print messages saying which checks are being made. To 35148af84faSmrg suppress all normal output, redirect it to `/dev/null' (any error 35248af84faSmrg messages will still be shown). 35348af84faSmrg 35448af84faSmrg`--srcdir=DIR' 35548af84faSmrg Look for the package's source code in directory DIR. Usually 35648af84faSmrg `configure' can determine that directory automatically. 35748af84faSmrg 35848af84faSmrg`--prefix=DIR' 359c6a6acfbSmrg Use DIR as the installation prefix. *note Installation Names:: 36048af84faSmrg for more details, including other options available for fine-tuning 36148af84faSmrg the installation locations. 36248af84faSmrg 36348af84faSmrg`--no-create' 36448af84faSmrg`-n' 36548af84faSmrg Run the configure checks, but stop before creating any output 36648af84faSmrg files. 36748af84faSmrg 36848af84faSmrg`configure' also accepts some other, not widely useful, options. Run 36948af84faSmrg`configure --help' for more details. 37048af84faSmrg 371