Wed, 31 Dec 2014 06:09:35 +0100
Cloned upstream origin tor-browser at tor-browser-31.3.0esr-4.5-1-build1
revision ID fc1c9ff7c1b2defdbc039f12214767608f46423f for hacking purpose.
michael@0 | 1 | Installation Instructions |
michael@0 | 2 | ************************* |
michael@0 | 3 | |
michael@0 | 4 | Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005, |
michael@0 | 5 | 2006 Free Software Foundation, Inc. |
michael@0 | 6 | |
michael@0 | 7 | This file is free documentation; the Free Software Foundation gives |
michael@0 | 8 | unlimited permission to copy, distribute and modify it. |
michael@0 | 9 | |
michael@0 | 10 | Basic Installation |
michael@0 | 11 | ================== |
michael@0 | 12 | |
michael@0 | 13 | Briefly, the shell commands `./configure; make; make install' should |
michael@0 | 14 | configure, build, and install this package. The following |
michael@0 | 15 | more-detailed instructions are generic; see the `README' file for |
michael@0 | 16 | instructions specific to this package. |
michael@0 | 17 | |
michael@0 | 18 | The `configure' shell script attempts to guess correct values for |
michael@0 | 19 | various system-dependent variables used during compilation. It uses |
michael@0 | 20 | those values to create a `Makefile' in each directory of the package. |
michael@0 | 21 | It may also create one or more `.h' files containing system-dependent |
michael@0 | 22 | definitions. Finally, it creates a shell script `config.status' that |
michael@0 | 23 | you can run in the future to recreate the current configuration, and a |
michael@0 | 24 | file `config.log' containing compiler output (useful mainly for |
michael@0 | 25 | debugging `configure'). |
michael@0 | 26 | |
michael@0 | 27 | It can also use an optional file (typically called `config.cache' |
michael@0 | 28 | and enabled with `--cache-file=config.cache' or simply `-C') that saves |
michael@0 | 29 | the results of its tests to speed up reconfiguring. Caching is |
michael@0 | 30 | disabled by default to prevent problems with accidental use of stale |
michael@0 | 31 | cache files. |
michael@0 | 32 | |
michael@0 | 33 | If you need to do unusual things to compile the package, please try |
michael@0 | 34 | to figure out how `configure' could check whether to do them, and mail |
michael@0 | 35 | diffs or instructions to the address given in the `README' so they can |
michael@0 | 36 | be considered for the next release. If you are using the cache, and at |
michael@0 | 37 | some point `config.cache' contains results you don't want to keep, you |
michael@0 | 38 | may remove or edit it. |
michael@0 | 39 | |
michael@0 | 40 | The file `configure.ac' (or `configure.in') is used to create |
michael@0 | 41 | `configure' by a program called `autoconf'. You need `configure.ac' if |
michael@0 | 42 | you want to change it or regenerate `configure' using a newer version |
michael@0 | 43 | of `autoconf'. |
michael@0 | 44 | |
michael@0 | 45 | The simplest way to compile this package is: |
michael@0 | 46 | |
michael@0 | 47 | 1. `cd' to the directory containing the package's source code and type |
michael@0 | 48 | `./configure' to configure the package for your system. |
michael@0 | 49 | |
michael@0 | 50 | Running `configure' might take a while. While running, it prints |
michael@0 | 51 | some messages telling which features it is checking for. |
michael@0 | 52 | |
michael@0 | 53 | 2. Type `make' to compile the package. |
michael@0 | 54 | |
michael@0 | 55 | 3. Optionally, type `make check' to run any self-tests that come with |
michael@0 | 56 | the package. |
michael@0 | 57 | |
michael@0 | 58 | 4. Type `make install' to install the programs and any data files and |
michael@0 | 59 | documentation. |
michael@0 | 60 | |
michael@0 | 61 | 5. You can remove the program binaries and object files from the |
michael@0 | 62 | source code directory by typing `make clean'. To also remove the |
michael@0 | 63 | files that `configure' created (so you can compile the package for |
michael@0 | 64 | a different kind of computer), type `make distclean'. There is |
michael@0 | 65 | also a `make maintainer-clean' target, but that is intended mainly |
michael@0 | 66 | for the package's developers. If you use it, you may have to get |
michael@0 | 67 | all sorts of other programs in order to regenerate files that came |
michael@0 | 68 | with the distribution. |
michael@0 | 69 | |
michael@0 | 70 | Compilers and Options |
michael@0 | 71 | ===================== |
michael@0 | 72 | |
michael@0 | 73 | Some systems require unusual options for compilation or linking that the |
michael@0 | 74 | `configure' script does not know about. Run `./configure --help' for |
michael@0 | 75 | details on some of the pertinent environment variables. |
michael@0 | 76 | |
michael@0 | 77 | You can give `configure' initial values for configuration parameters |
michael@0 | 78 | by setting variables in the command line or in the environment. Here |
michael@0 | 79 | is an example: |
michael@0 | 80 | |
michael@0 | 81 | ./configure CC=c99 CFLAGS=-g LIBS=-lposix |
michael@0 | 82 | |
michael@0 | 83 | *Note Defining Variables::, for more details. |
michael@0 | 84 | |
michael@0 | 85 | Compiling For Multiple Architectures |
michael@0 | 86 | ==================================== |
michael@0 | 87 | |
michael@0 | 88 | You can compile the package for more than one kind of computer at the |
michael@0 | 89 | same time, by placing the object files for each architecture in their |
michael@0 | 90 | own directory. To do this, you can use GNU `make'. `cd' to the |
michael@0 | 91 | directory where you want the object files and executables to go and run |
michael@0 | 92 | the `configure' script. `configure' automatically checks for the |
michael@0 | 93 | source code in the directory that `configure' is in and in `..'. |
michael@0 | 94 | |
michael@0 | 95 | With a non-GNU `make', it is safer to compile the package for one |
michael@0 | 96 | architecture at a time in the source code directory. After you have |
michael@0 | 97 | installed the package for one architecture, use `make distclean' before |
michael@0 | 98 | reconfiguring for another architecture. |
michael@0 | 99 | |
michael@0 | 100 | Installation Names |
michael@0 | 101 | ================== |
michael@0 | 102 | |
michael@0 | 103 | By default, `make install' installs the package's commands under |
michael@0 | 104 | `/usr/local/bin', include files under `/usr/local/include', etc. You |
michael@0 | 105 | can specify an installation prefix other than `/usr/local' by giving |
michael@0 | 106 | `configure' the option `--prefix=PREFIX'. |
michael@0 | 107 | |
michael@0 | 108 | You can specify separate installation prefixes for |
michael@0 | 109 | architecture-specific files and architecture-independent files. If you |
michael@0 | 110 | pass the option `--exec-prefix=PREFIX' to `configure', the package uses |
michael@0 | 111 | PREFIX as the prefix for installing programs and libraries. |
michael@0 | 112 | Documentation and other data files still use the regular prefix. |
michael@0 | 113 | |
michael@0 | 114 | In addition, if you use an unusual directory layout you can give |
michael@0 | 115 | options like `--bindir=DIR' to specify different values for particular |
michael@0 | 116 | kinds of files. Run `configure --help' for a list of the directories |
michael@0 | 117 | you can set and what kinds of files go in them. |
michael@0 | 118 | |
michael@0 | 119 | If the package supports it, you can cause programs to be installed |
michael@0 | 120 | with an extra prefix or suffix on their names by giving `configure' the |
michael@0 | 121 | option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. |
michael@0 | 122 | |
michael@0 | 123 | Optional Features |
michael@0 | 124 | ================= |
michael@0 | 125 | |
michael@0 | 126 | Some packages pay attention to `--enable-FEATURE' options to |
michael@0 | 127 | `configure', where FEATURE indicates an optional part of the package. |
michael@0 | 128 | They may also pay attention to `--with-PACKAGE' options, where PACKAGE |
michael@0 | 129 | is something like `gnu-as' or `x' (for the X Window System). The |
michael@0 | 130 | `README' should mention any `--enable-' and `--with-' options that the |
michael@0 | 131 | package recognizes. |
michael@0 | 132 | |
michael@0 | 133 | For packages that use the X Window System, `configure' can usually |
michael@0 | 134 | find the X include and library files automatically, but if it doesn't, |
michael@0 | 135 | you can use the `configure' options `--x-includes=DIR' and |
michael@0 | 136 | `--x-libraries=DIR' to specify their locations. |
michael@0 | 137 | |
michael@0 | 138 | Specifying the System Type |
michael@0 | 139 | ========================== |
michael@0 | 140 | |
michael@0 | 141 | There may be some features `configure' cannot figure out automatically, |
michael@0 | 142 | but needs to determine by the type of machine the package will run on. |
michael@0 | 143 | Usually, assuming the package is built to be run on the _same_ |
michael@0 | 144 | architectures, `configure' can figure that out, but if it prints a |
michael@0 | 145 | message saying it cannot guess the machine type, give it the |
michael@0 | 146 | `--build=TYPE' option. TYPE can either be a short name for the system |
michael@0 | 147 | type, such as `sun4', or a canonical name which has the form: |
michael@0 | 148 | |
michael@0 | 149 | CPU-COMPANY-SYSTEM |
michael@0 | 150 | |
michael@0 | 151 | where SYSTEM can have one of these forms: |
michael@0 | 152 | |
michael@0 | 153 | OS KERNEL-OS |
michael@0 | 154 | |
michael@0 | 155 | See the file `config.sub' for the possible values of each field. If |
michael@0 | 156 | `config.sub' isn't included in this package, then this package doesn't |
michael@0 | 157 | need to know the machine type. |
michael@0 | 158 | |
michael@0 | 159 | If you are _building_ compiler tools for cross-compiling, you should |
michael@0 | 160 | use the option `--target=TYPE' to select the type of system they will |
michael@0 | 161 | produce code for. |
michael@0 | 162 | |
michael@0 | 163 | If you want to _use_ a cross compiler, that generates code for a |
michael@0 | 164 | platform different from the build platform, you should specify the |
michael@0 | 165 | "host" platform (i.e., that on which the generated programs will |
michael@0 | 166 | eventually be run) with `--host=TYPE'. |
michael@0 | 167 | |
michael@0 | 168 | Sharing Defaults |
michael@0 | 169 | ================ |
michael@0 | 170 | |
michael@0 | 171 | If you want to set default values for `configure' scripts to share, you |
michael@0 | 172 | can create a site shell script called `config.site' that gives default |
michael@0 | 173 | values for variables like `CC', `cache_file', and `prefix'. |
michael@0 | 174 | `configure' looks for `PREFIX/share/config.site' if it exists, then |
michael@0 | 175 | `PREFIX/etc/config.site' if it exists. Or, you can set the |
michael@0 | 176 | `CONFIG_SITE' environment variable to the location of the site script. |
michael@0 | 177 | A warning: not all `configure' scripts look for a site script. |
michael@0 | 178 | |
michael@0 | 179 | Defining Variables |
michael@0 | 180 | ================== |
michael@0 | 181 | |
michael@0 | 182 | Variables not defined in a site shell script can be set in the |
michael@0 | 183 | environment passed to `configure'. However, some packages may run |
michael@0 | 184 | configure again during the build, and the customized values of these |
michael@0 | 185 | variables may be lost. In order to avoid this problem, you should set |
michael@0 | 186 | them in the `configure' command line, using `VAR=value'. For example: |
michael@0 | 187 | |
michael@0 | 188 | ./configure CC=/usr/local2/bin/gcc |
michael@0 | 189 | |
michael@0 | 190 | causes the specified `gcc' to be used as the C compiler (unless it is |
michael@0 | 191 | overridden in the site shell script). |
michael@0 | 192 | |
michael@0 | 193 | Unfortunately, this technique does not work for `CONFIG_SHELL' due to |
michael@0 | 194 | an Autoconf bug. Until the bug is fixed you can use this workaround: |
michael@0 | 195 | |
michael@0 | 196 | CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash |
michael@0 | 197 | |
michael@0 | 198 | `configure' Invocation |
michael@0 | 199 | ====================== |
michael@0 | 200 | |
michael@0 | 201 | `configure' recognizes the following options to control how it operates. |
michael@0 | 202 | |
michael@0 | 203 | `--help' |
michael@0 | 204 | `-h' |
michael@0 | 205 | Print a summary of the options to `configure', and exit. |
michael@0 | 206 | |
michael@0 | 207 | `--version' |
michael@0 | 208 | `-V' |
michael@0 | 209 | Print the version of Autoconf used to generate the `configure' |
michael@0 | 210 | script, and exit. |
michael@0 | 211 | |
michael@0 | 212 | `--cache-file=FILE' |
michael@0 | 213 | Enable the cache: use and save the results of the tests in FILE, |
michael@0 | 214 | traditionally `config.cache'. FILE defaults to `/dev/null' to |
michael@0 | 215 | disable caching. |
michael@0 | 216 | |
michael@0 | 217 | `--config-cache' |
michael@0 | 218 | `-C' |
michael@0 | 219 | Alias for `--cache-file=config.cache'. |
michael@0 | 220 | |
michael@0 | 221 | `--quiet' |
michael@0 | 222 | `--silent' |
michael@0 | 223 | `-q' |
michael@0 | 224 | Do not print messages saying which checks are being made. To |
michael@0 | 225 | suppress all normal output, redirect it to `/dev/null' (any error |
michael@0 | 226 | messages will still be shown). |
michael@0 | 227 | |
michael@0 | 228 | `--srcdir=DIR' |
michael@0 | 229 | Look for the package's source code in directory DIR. Usually |
michael@0 | 230 | `configure' can determine that directory automatically. |
michael@0 | 231 | |
michael@0 | 232 | `configure' also accepts some other, not widely useful, options. Run |
michael@0 | 233 | `configure --help' for more details. |
michael@0 | 234 |