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