1$Id: INSTALL 1122 2009-04-09 23:45:51Z $ 2 3Build Remarks 4============= 5 6(These are remarks for building on UNIX-like systems, instructions for Windows 7systems are provided in the file INSTALL.Windows.txt) 8 9* Standard build: 10 11 $ ./configure && make 12 13* Debug build: 14 15 $ ./configure --enable-debug && make 16 17* Graphics: 18 * Graphics output support can be disabled by passing certain arguments to 19 configure or the C preprocessor: 20 21 * Disable Magick++: 22 23 $ ./configure --disable-magick 24 OR 25 $ make CPPFLAGS="-DDISABLE_MAGICK" 26 27 * Disable GD library: 28 29 $ ./configure --disable-gd 30 OR 31 $ make CPPFLAGS="-DDISABLE_GD" 32 33 * Disable graphics support: 34 35 $ ./configure --disable-magick --disable-gd 36 OR 37 $ make CPPFLAGS="-DDISABLE_GRAPHICS" 38 39 None of these DISABLE_* macros can be set from the configure script. 40 41* Nonstandard locations of libraries: 42 43 configure can be pointed to the correct locations of the boost libraries, gd 44 and Magick++ by using the "--with-*" options (they should point to the 45 *prefix* not the headers -e.g. /usr instead of /usr/include-). They are: 46 --with-gd 47 --with-magick 48 --with-boost 49 --with-boost-program_options 50 --with-boost-thread 51 52* Magick++ support can be provided by either ImageMagick++ or 53 GraphicsMagick++, there's currently no way to choose one over the other. 54 55* If the configure script fails to locate your boost-program-options 56 and/or boosy-thread installation, first locate it (e.g. 57 /usr/lib/libboost_program_options-gcc41-mt-1_34.*) and then pass the suffix 58 as an argument to configure as follows: (for the above example): 59 60 $ ./configure --with-boost-program-options=gcc41-mt-1_34 61 62=============================================================================== 63 Standard GNU installation instructions follow 64=============================================================================== 65 66Installation Instructions 67************************* 68 69Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free 70Software Foundation, Inc. 71 72This file is free documentation; the Free Software Foundation gives 73unlimited permission to copy, distribute and modify it. 74 75Basic Installation 76================== 77 78These are generic installation instructions. 79 80 The `configure' shell script attempts to guess correct values for 81various system-dependent variables used during compilation. It uses 82those values to create a `Makefile' in each directory of the package. 83It may also create one or more `.h' files containing system-dependent 84definitions. Finally, it creates a shell script `config.status' that 85you can run in the future to recreate the current configuration, and a 86file `config.log' containing compiler output (useful mainly for 87debugging `configure'). 88 89 It can also use an optional file (typically called `config.cache' 90and enabled with `--cache-file=config.cache' or simply `-C') that saves 91the results of its tests to speed up reconfiguring. (Caching is 92disabled by default to prevent problems with accidental use of stale 93cache files.) 94 95 If you need to do unusual things to compile the package, please try 96to figure out how `configure' could check whether to do them, and mail 97diffs or instructions to the address given in the `README' so they can 98be considered for the next release. If you are using the cache, and at 99some point `config.cache' contains results you don't want to keep, you 100may remove or edit it. 101 102 The file `configure.ac' (or `configure.in') is used to create 103`configure' by a program called `autoconf'. You only need 104`configure.ac' if you want to change it or regenerate `configure' using 105a newer version of `autoconf'. 106 107The simplest way to compile this package is: 108 109 1. `cd' to the directory containing the package's source code and type 110 `./configure' to configure the package for your system. If you're 111 using `csh' on an old version of System V, you might need to type 112 `sh ./configure' instead to prevent `csh' from trying to execute 113 `configure' itself. 114 115 Running `configure' takes awhile. While running, it prints some 116 messages telling which features it is checking for. 117 118 2. Type `make' to compile the package. 119 120 3. Optionally, type `make check' to run any self-tests that come with 121 the package. 122 123 4. Type `make install' to install the programs and any data files and 124 documentation. 125 126 5. You can remove the program binaries and object files from the 127 source code directory by typing `make clean'. To also remove the 128 files that `configure' created (so you can compile the package for 129 a different kind of computer), type `make distclean'. There is 130 also a `make maintainer-clean' target, but that is intended mainly 131 for the package's developers. If you use it, you may have to get 132 all sorts of other programs in order to regenerate files that came 133 with the distribution. 134 135Compilers and Options 136===================== 137 138Some systems require unusual options for compilation or linking that the 139`configure' script does not know about. Run `./configure --help' for 140details on some of the pertinent environment variables. 141 142 You can give `configure' initial values for configuration parameters 143by setting variables in the command line or in the environment. Here 144is an example: 145 146 ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix 147 148 *Note Defining Variables::, for more details. 149 150Compiling For Multiple Architectures 151==================================== 152 153You can compile the package for more than one kind of computer at the 154same time, by placing the object files for each architecture in their 155own directory. To do this, you must use a version of `make' that 156supports the `VPATH' variable, such as GNU `make'. `cd' to the 157directory where you want the object files and executables to go and run 158the `configure' script. `configure' automatically checks for the 159source code in the directory that `configure' is in and in `..'. 160 161 If you have to use a `make' that does not support the `VPATH' 162variable, you have to compile the package for one architecture at a 163time in the source code directory. After you have installed the 164package for one architecture, use `make distclean' before reconfiguring 165for another architecture. 166 167Installation Names 168================== 169 170By default, `make install' installs the package's commands under 171`/usr/local/bin', include files under `/usr/local/include', etc. You 172can specify an installation prefix other than `/usr/local' by giving 173`configure' the option `--prefix=PREFIX'. 174 175 You can specify separate installation prefixes for 176architecture-specific files and architecture-independent files. If you 177pass the option `--exec-prefix=PREFIX' to `configure', the package uses 178PREFIX as the prefix for installing programs and libraries. 179Documentation and other data files still use the regular prefix. 180 181 In addition, if you use an unusual directory layout you can give 182options like `--bindir=DIR' to specify different values for particular 183kinds of files. Run `configure --help' for a list of the directories 184you can set and what kinds of files go in them. 185 186 If the package supports it, you can cause programs to be installed 187with an extra prefix or suffix on their names by giving `configure' the 188option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. 189 190Optional Features 191================= 192 193Some packages pay attention to `--enable-FEATURE' options to 194`configure', where FEATURE indicates an optional part of the package. 195They may also pay attention to `--with-PACKAGE' options, where PACKAGE 196is something like `gnu-as' or `x' (for the X Window System). The 197`README' should mention any `--enable-' and `--with-' options that the 198package recognizes. 199 200 For packages that use the X Window System, `configure' can usually 201find the X include and library files automatically, but if it doesn't, 202you can use the `configure' options `--x-includes=DIR' and 203`--x-libraries=DIR' to specify their locations. 204 205Specifying the System Type 206========================== 207 208There may be some features `configure' cannot figure out automatically, 209but needs to determine by the type of machine the package will run on. 210Usually, assuming the package is built to be run on the _same_ 211architectures, `configure' can figure that out, but if it prints a 212message saying it cannot guess the machine type, give it the 213`--build=TYPE' option. TYPE can either be a short name for the system 214type, such as `sun4', or a canonical name which has the form: 215 216 CPU-COMPANY-SYSTEM 217 218where SYSTEM can have one of these forms: 219 220 OS KERNEL-OS 221 222 See the file `config.sub' for the possible values of each field. If 223`config.sub' isn't included in this package, then this package doesn't 224need to know the machine type. 225 226 If you are _building_ compiler tools for cross-compiling, you should 227use the option `--target=TYPE' to select the type of system they will 228produce code for. 229 230 If you want to _use_ a cross compiler, that generates code for a 231platform different from the build platform, you should specify the 232"host" platform (i.e., that on which the generated programs will 233eventually be run) with `--host=TYPE'. 234 235Sharing Defaults 236================ 237 238If you want to set default values for `configure' scripts to share, you 239can create a site shell script called `config.site' that gives default 240values for variables like `CC', `cache_file', and `prefix'. 241`configure' looks for `PREFIX/share/config.site' if it exists, then 242`PREFIX/etc/config.site' if it exists. Or, you can set the 243`CONFIG_SITE' environment variable to the location of the site script. 244A warning: not all `configure' scripts look for a site script. 245 246Defining Variables 247================== 248 249Variables not defined in a site shell script can be set in the 250environment passed to `configure'. However, some packages may run 251configure again during the build, and the customized values of these 252variables may be lost. In order to avoid this problem, you should set 253them in the `configure' command line, using `VAR=value'. For example: 254 255 ./configure CC=/usr/local2/bin/gcc 256 257causes the specified `gcc' to be used as the C compiler (unless it is 258overridden in the site shell script). Here is a another example: 259 260 /bin/bash ./configure CONFIG_SHELL=/bin/bash 261 262Here the `CONFIG_SHELL=/bin/bash' operand causes subsequent 263configuration-related scripts to be executed by `/bin/bash'. 264 265`configure' Invocation 266====================== 267 268`configure' recognizes the following options to control how it operates. 269 270`--help' 271`-h' 272 Print a summary of the options to `configure', and exit. 273 274`--version' 275`-V' 276 Print the version of Autoconf used to generate the `configure' 277 script, and exit. 278 279`--cache-file=FILE' 280 Enable the cache: use and save the results of the tests in FILE, 281 traditionally `config.cache'. FILE defaults to `/dev/null' to 282 disable caching. 283 284`--config-cache' 285`-C' 286 Alias for `--cache-file=config.cache'. 287 288`--quiet' 289`--silent' 290`-q' 291 Do not print messages saying which checks are being made. To 292 suppress all normal output, redirect it to `/dev/null' (any error 293 messages will still be shown). 294 295`--srcdir=DIR' 296 Look for the package's source code in directory DIR. Usually 297 `configure' can determine that directory automatically. 298 299`configure' also accepts some other, not widely useful, options. Run 300`configure --help' for more details. 301 302