]> git.sur5r.net Git - openldap/blob - INSTALL
ldap_modify: delete of last attribute value should delete attribute (ITS#229)
[openldap] / INSTALL
1 Making and Installing the U-M LDAP Distribution
2
3 ** It is recommended that you read or at least skim through ALL of the
4 ** instructions in this file before attempting to build the software.
5
6 If you want to build binaries for more than one platform from a single
7 source tree, skip ahead to the "Building LDAP For More Than One Platform"
8 section near the end of this file. If you are planning to run slapd,
9 you should read the "SLAPD and SLURPD Administrator's Guide", found in
10 the doc/guides/ directory within the distribution.
11
12 If you simply want to build LDAP for a single machine platform, follow
13 these steps:
14
15  1. untar the distribution and cd to the top:
16
17         % zcat ldap-3.3.tar.Z | tar xf -
18         % cd ldap-3.3
19
20     If you are reading this file, you probably have already done this!
21
22
23  2. edit the files Make-common and include/ldapconfig.h.edit to configure
24     the software for your site (the files are well-commented):
25
26         % vi Make-common
27         % vi include/ldapconfig.h.edit
28
29     Note that you should NOT need to edit the Makefile located at the
30     top of the distribution.
31
32     If you just want to see if things will build, you can leave the
33     configuration alone and change it later.
34
35     If you have the ISODE package built and want to build the
36     LDAP-to-X.500 server (ldapd), be sure to uncomment the appropriate
37     lines near the end of the Make-common file.  By default only the
38     stand-alone server, LDAP libraries and client software are built.
39
40  3. make the software:
41
42         % make
43
44     If all goes well, then make will figure out what platform you are on,
45     pick a compiler to use, construct Makefiles, and build everything.
46     If you see a message like "unknown platform..." LDAP has probably not
47     been set up to build on your machine.  See the file build/PORTS for
48     hints on what to do in that case.
49
50     Note that if your make does not use the Bourne (sh) shell by
51     default when executing internal scripts (reportedly the case on SGI
52     machines at least), you will need to run the make explicitly from
53     within a Bourne shell.  If you a syntax error such as "Missing ]"
54     when you do the make under your usual shell, try this:
55
56         % sh
57         $ make
58
59     If you don't like the some of the platform-specific options chosen
60     by the automatic build process (such as the compiler to use, etc),
61     you can intervene and edit them before anything is actually compiled
62     by explicitly doing a "make platform" step, editing the .make-platform
63     file (actually a link to the file to be edited), and then doing a
64     regular make:
65
66         % make platform
67         % vi .make-platform
68         % make
69
70     If you want to choose the build platform yourself from among those that
71     the distribution supports, cd to the appropriate directory underneath
72     build/platforms and make from there.  For example, if you are on a
73     machine running SunOS 4.1.4 and you want to force the use of the cc
74     compiler, you would do this:
75
76         % cd build/platforms/sunos4-cc
77         % make
78
79     If you want to run some simple tests after the build is complete, you
80     can do this:
81
82         % make test
83
84  4. install the binaries and man pages.  You may need to be superuser to
85     do this (depending on where you are installing things):
86
87         % su
88         # make install
89
90     That's it!  See the man pages for the individual clients for information
91     on configuring and using them.  Eventually you will probably want to
92     edit the configuration files used by the various clients (installed in
93     the LDAP etc directory).  The files are:
94
95         ldapfilter.conf      - search filter configuration
96         ldapfriendly         - mapping of X.500 names to human-friendly names
97         ldapsearchprefs.conf - search object definitions
98         ldaptemplates.conf   - display template definitions
99
100     There are section 5 man pages for all of these files.
101
102
103 Building LDAP For More Than One Platform
104
105 It is now possible to build LDAP for more than one platform from the same
106 source tree.  This is accomplished by some rules in the Makefiles that
107 create a shadow (linked) directory tree where the binaries are placed.
108
109 Follow these steps for each different platform:
110
111  1. move to the directory that matches the platform and compiler you
112     want to build for and type make.  The directories are all located
113     underneath the build/platforms directory.  If your platform is not
114     there, you may need to do a port - see the build/PORTS file for
115     more information.  For a Sun running SunOS 4.1.4, you might do
116     this:
117
118         % cd build/platforms/sunos4-cc
119         % make links
120
121     This will create a linked source area.
122
123
124  2. move to the new directory and make as for a single platform.  Follow steps
125     1-4 above to accomplish this.  For example:
126
127         % cd obj-sunos4-cc
128         % make
129
130     That's all there is to it.  You can also create the linked source area(s)
131     by just typing "make links" at the top of the distribution, in which case
132     the Makefile will try to automatically determine the platform and
133     compiler.
134
135
136 End of LDAP INSTALL file.