]> git.sur5r.net Git - openldap/blob - doc/guide/release/install.sdf
Mostly formating changes
[openldap] / doc / guide / release / install.sdf
1 # $OpenLDAP$
2 # Copyright 1999-2000, The OpenLDAP Foundation, All Rights Reserved.
3 # COPYING RESTRICTIONS APPLY, see COPYRIGHT.
4
5 P1: Making and Installing the OpenLDAP Distribution
6
7 This file provides brief instructions on how to build and install
8 OpenLDAP on UNIX (and UNIX-{{like}}) system.  For other systems,
9 please consult {{The OpenLDAP Administrator's Guide}}
10 {{URL:http://www.openldap.org/devel/admin/}}.
11
12 It is recommended that you read, or at least skim through, ALL of
13 the instructions in this file before attempting to build the
14 software.
15
16 It is also recommended your review
17 {{The OpenLDAP Administrator's Guide}}
18 ({{URL:http://www.openldap.org/devel/admin/}}) and
19 the {{Frequently Asked Questions}} ({{URL:http://www.openldap.org/faq/}})
20 pages, in particular the
21 {{Installation section}} ({{URL:http://www.openldap.org/faq/index.cgi?file=8}})
22 and
23 {{Platform Hints}} ({{URL:http://www.openldap.org/faq/index.cgi?file=9}})
24 should be examined.
25
26
27 P2: Making and Installing the OpenLDAP Distribution
28
29 ^ Unpack the distribution and change directory:
30
31 E:      % tar xfz openldap-VERSION.tgz
32 E:      % cd openldap-VERSION
33
34 .(replacing {{EX:VERSION}} with the appropriate version string).  If
35 you are reading this file, you probably have already done this!
36
37
38 + Type:
39
40 E:      % ./configure --help
41
42 .to list available configuration options.   A description of
43 these options is provided in the 'CONFIGURE OPTIONS' section
44 below.
45
46 .The {{EX:configure}} script uses environmental variables for
47 determining compiler/linker options.  See the 'USING ENVIRONMENT
48 VARIABLES' section for commonly used settings.
49
50 .These environment variables are used: 
51
52 >       CC              C compiler      gcc
53 >       CFLAGS          C flags         -ansi
54 >       CPPFLAGS        cpp flags       -I/path/include -Ddef
55 >       LDFLAGS         ld flags        -L/usr/local/lib
56 >       LIBS            libraries       -llib
57 >       PATH            command path    /usr/local/bin:/usr/bin:/bin
58
59 .See the 'USING ENVIRONMENT VARIABLES' section for information
60 on how to use the variables. 
61
62 + Configure the build system
63
64 E:      % [env settings] ./configure [options]
65
66 .If all goes well, the {{EX:configure}} script with automatically
67 detect the appropriate settings.  However, you may need to
68 specify options and/or environment variables to obtain desired
69 results.
70
71 + Build dependencies
72
73 E:      % make depend
74
75 + Build the system
76
77 E:      % make
78
79 .If all goes well, the system will build as configured.  If not,
80 return to step 3 after reviewing the configuration settings.  You
81 may want to consult the {{Platform Hints}} subsection of the {{FAQ}}
82 if you have not done so already.
83
84 + Test the standalone system
85
86 .This step requires the standalone LDAP server, {{slapd}}(8),
87 with {{LDBM}} support.
88
89 E:      % make test
90
91 .If all goes well, the system has been built as configured.  If not,
92 return to step 4 after reviewing your configuration settings.  You
93 may want to consult the {{Installation}} section of the {{FAQ}}
94 if you have not done so already.
95
96 + install the binaries and man pages.  You may need to be {{superuser}}
97 to do this (depending on where you are installing things):
98
99 E:      % su root -c 'make install'
100
101 + That's it!
102
103 See the {{Administrator's Guide}} and the manual pages for the
104 individual applications for configuration and use information.
105 You may also want to edit the configuration files used by the
106 various components.  These configuration files are located in
107 the OpenLDAP configuration directory (normally
108 {{F:/usr/local/etc/openldap}}).
109
110 >       ldap.conf               client defaults
111 >       ldapfilter.conf         search filter configuration
112 >       ldapsearchprefs.conf    search object definitions
113 >       ldaptemplates.conf      display template definitions
114 >       slapd.conf              Standalone LDAP daemon
115 >       schema/*.schema         Schema Definitions
116
117 There are section 5 man pages for these configuration files.
118
119
120 P2: Building OpenLDAP For More Than One Platform
121
122 You can build OpenLDAP for more than one platform from the
123 same source tree.
124 This is accomplished by using {{make}}(1) {{EX:VPATH}} support.
125 If your {{make}}(1) program is old and doesn't have {{EX:VPATH}}
126 support, install {{BSD Make}} or {{GNU Make}}.
127
128 Follow these steps for each different platform:
129
130 ^ Create a directory for the platform object files.
131
132 E:      % mkdir obj-platform
133
134 + Change your working directory to the platform object directory.
135
136 E:      % cd obj-platform
137
138 + Configure the build system
139
140 E:      % [env settings] ../configure --src-dir=.. [options]
141
142 . ( replace "{{F:..}}" with the appropriate path )
143
144 + Continue as above (starting at step 6).
145
146
147 P2: CONFIGURE OPTIONS
148
149 Regrettably, this section has not been written (yet).  See
150 "{{EX:./configure --help}}" for current list of options.  For general
151 information about how to use "{{EX:configure}}", please read
152 {{F:doc/install/configure}}.
153
154
155 P2: USING ENVIRONMENT VARIABLES
156
157 The configure script will also use your environmental
158 variables for determining compiler/linker options.   This can
159 be used to manual specify features and compilation options.
160
161 Note[label=Warning]: Executables built in your environment may not run
162 in your users' environments.  The portability of executables
163 between environments is your responsibility.
164
165 Supported Environmental Variables:
166
167 >       CC              C compiler      cc
168 >       CFLAGS          C flags         -ansi
169 >       CPPFLAGS        cpp flags       -I/path/include -Ddef
170 >       LDFLAGS         ld flags        -L/usr/local/lib
171 >       LIBS            libraries       -llib
172 >       PATH            command path    /usr/local/bin:/usr/bin:/bin
173
174 * Including alternative compilers
175
176 .Use the {{EX:CC}} environment variable to tell configure to
177 use a specific compiler.  For example, to use {{GNU C
178 Compiler}} instead of the default compiler, use:
179
180 E:      % [env] CC=gcc ./configure 
181
182 .You can also use {{EX:CC}} use specific flags with the
183 specified compiler.  For example, to require strict
184 {{ANSI C}} using the {{GNU C Compiler}}, use:
185
186 E:      % [env] CC="gcc -ansi -pedantic" ./configure
187
188 .(you can use {{EX:CFLAGS}} to specify compiler flags)
189
190 * Preprocessor Flags
191
192 .You may specify additional preprocessor flags by setting
193 {{EX:CPPFLAGS}}.  For example, if you would like to use headers
194 installed in {{F:/usr/local/include}}, use:
195
196 E:      % [env] CPPFLAGS="-I/usr/local/include" ./configure
197
198 .You can also use {{EX:CPPFLAGS}} to specify preprocessor macros.
199
200 E:      % [env] CPPFLAGS="-D__SPECIAL_FLAG__" ./configure
201
202 * Linker Flags
203
204 .You may specify additional linker flags by setting {{EX:LDFLAGS}}.
205 For example, if you would like to use libraries installed
206 in {{F:/usr/local/lib}}, use:
207
208 E:      % [env] LDFLAGS="-L/usr/local/lib" ./configure
209
210 .You can also use CPPFLAGS to specify linker flags:
211
212 E:      % [env] LDFLAGS="-Bstatic" ./configure
213
214 * Path
215
216 .You may alter your path to affect configure ability to
217 find (or not find) commands.  For example, to have configure
218 additionally look in {{F:/usr/css/bin}} for commands, use:
219
220 E:      % [env] PATH="/usr/css/bin:$PATH" ./configure
221         
222 * Using locally installed software
223
224 .To use software under installed under {{F:/usr/local}}.
225
226 E:      [env] \
227 E:              CPPFLAGS="-I/usr/local/include" \
228 E:              LDFLAGS="-L/usr/local/lib" \
229 E:              ./configure
230
231 Note: You may have add additional flags if your system
232 supports shared libraries.
233
234
235 End of OpenLDAP INSTALL file.
236
237 {{S:$OpenLDAP$}}