]> git.sur5r.net Git - openldap/blob - doc/guide/release/install.sdf
Add rcs id
[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 It is recommended that you read or at least skim through ALL of the
8 instructions in this file before attempting to build the software.
9
10 The OpenLDAP Installation FAQ is available at:
11
12 .{{URL:http://www.openldap.org/faq/index.cgi?file=8}}
13
14 You should also check for platform specific hints.
15 These are located in doc/install/hints or:
16
17 .{{URL:http://www.openldap.org/faq/index.cgi?file=9}}
18
19
20 P2: Making and Installing the OpenLDAP Distribution
21
22 ^ untar the distribution and cd to the top:
23
24 E:      % tar xfz openldap-VERSION.tgz
25 E:      % cd openldap-VERSION
26
27 .If you are reading this file, you probably have already done this!
28
29
30 + Type:
31
32 E:      % ./configure --help
33
34 .to list available configuration options.   A description of
35 these options is provided in the 'CONFIGURE OPTIONS' section
36 below.
37
38 .The configure script uses environmental variables for
39 determining compiler/linker options.  See the HINTS
40 section for commonly used settings. 
41
42 .These environment variables are used: 
43
44 >       CC              C compiler      gcc
45 >       CFLAGS          C flags         -ansi
46 >       CPPFLAGS        cpp flags       -I/path/include -Ddef
47 >       LDFLAGS         ld flags        -L/usr/local/lib
48 >       LIBS            libraries       -llib
49 >       PATH            command path    /usr/local/bin:/usr/bin:/bin
50
51 .See the 'USING ENVIRONMENT VARIABLES' section for information
52 on how to use the variables. 
53
54 + Configure the build system
55
56 E:      % [env settings] ./configure [options]
57
58 .If all goes well, the configure script with auto-detect the
59 appropriate settings.  Use configure enable/with options and/or
60 environment variables to obtain desired results.
61
62 + Review the file include/ldapconfig.h.edit.
63
64 .You generally do not need to modify this file.  
65
66 E:      % view include/ldapconfig.h.edit
67
68 + Build dependencies
69
70 E:      % make depend
71
72 + Build the system
73
74 E:      % make
75
76 .If all goes well, the system will build as configured.  If not,
77 return to step 4 after reviewing the configuration settings.
78
79 .You may want to consult the doc/install/hints file for your
80 platform.
81
82 + Test the standalone system
83
84 .This step requires the standalone LDAP server (slapd) with
85 LDBM support.
86
87 E:      % cd tests
88 E:      % make
89 E:      % cd ..
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.
93
94 .You may want to consult the doc/install/hints file for your
95 platform.
96
97 + install the binaries and man pages.  You may need to be superuser to
98 do this (depending on where you are installing things):
99
100 E:      % su root -c make install
101
102 + That's it!
103
104 .See the man pages for the individual applications for
105 information on configuring and using them.  You may also want
106 to edit the configuration files used by the various components.
107 These configuration files are located in the OpenLDAP
108 configuration directory (normally /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
116 .There are section 5 man pages for all of these files.
117
118
119 P2: Building OpenLDAP For More Than One Platform
120
121 .You can build OpenLDAP for more than one platform from the
122 same source tree.
123 This is accomplished by using make(1) VPATH support.
124 If your make(1) program is old and doesn't have VPATH support,
125 install GNU Make.
126
127 .Follow these steps for each different platform:
128
129 ^ Create a directory for the platform object files.
130
131 E:      % mkdir obj-platform
132
133 + Change your working directory to the platform object directory.
134
135 E:      % cd obj-platform
136
137 + Configure the build system
138
139 E:      % [env settings] ../configure --src-dir=.. [options]
140
141 ( replace ".." with the appropriate path )
142
143 + Continue as above (starting at step 6).
144
145 Note: make depend in VPATH environment is not yet supported.
146
147
148 P2: CONFIGURE OPTIONS
149
150 Regrettably, this section has not been written (yet).  See
151 "./configure --help" for current list of options.  For general
152 information about how to use "configure", please read:
153         doc/install/configure
154
155
156 P2: USING ENVIRONMENT VARIABLES
157
158 The configure script will also use your environmental
159 variables for determining compiler/linker options.   This can
160 be used to manual specify features and compilation options.
161
162 Note: If you change environment setting, be sure to remove
163 any config.cache before running ./configure.
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 CC environment variable to tell configure to
177 use a specific compiler.  For example, to use ecgs
178 instead of the compiler configure choose, use:
179
180 E:      % [env] CC=egcc ./configure 
181
182 .You can also use 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 CFLAGS to specify compiler flags)
189
190 * Preprocessor Flags
191
192 .You may specify additional preprocessor flags by setting
193 CPPFLAGS.  For example, if you would like to use headers
194 installed in /usr/local/include, use:
195
196 E:      % [env] CPPFLAGS="-I/usr/local/include" ./configure
197
198 .You can also use 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 LDFLAGS.
205 For example, if you would like to use libraries installed
206 in /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 /usr/css/bin for commands, use:
219
220 E:      % [env] PATH="/usr/css/bin:$PATH" ./configure
221         
222
223 * Use local software
224
225 E:      % [env] \
226 E:              CPPFLAGS="-I/usr/local/include" \
227 E:              LDFLAGS="-L/usr/local/lib" \
228 E:              ./configure
229
230
231 End of OpenLDAP INSTALL file.
232
233 {{$OpenLDAP$}}