1 Making and Installing the OpenLDAP Distribution
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.
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.
10 If you simply want to build LDAP for a single machine platform, follow
13 1. untar the distribution and cd to the top:
15 % tar xfz openldap-VERSION.tgz
18 If you are reading this file, you probably have already done this!
20 2. copy Make-common.dist or Make-common.gmake to Make.common
22 3. edit the files Make-common and include/ldapconfig.h.edit to configure
23 the software for your site (the files are well-commented):
26 % vi include/ldapconfig.h.edit
28 Note that you should NOT need to edit the Makefile located at the
29 top of the distribution.
31 If you just want to see if things will build, you can leave the
32 configuration alone and change it later. You may want to consult
33 the appropriate platform makefile (build/*/Make-platform) for
34 platform-specific defaults.
36 If you have the ISODE package built and want to build the
37 LDAP-to-X.500 server (ldapd), be sure to uncomment the appropriate
38 lines near the end of the Make-common file. By default only the
39 stand-alone server, LDAP libraries and client software are built.
45 If all goes well, then make will figure out what platform you are on,
46 pick a compiler to use, construct Makefiles, and build everything.
47 If you see a message like "unknown platform..." LDAP has probably not
48 been set up to build on your machine. See the file build/PORTS for
49 hints on what to do in that case.
51 Note that if your make does not use the Bourne (sh) shell by
52 default when executing internal scripts (reportedly the case on SGI
53 machines at least), you will need to run the make explicitly from
54 within a Bourne shell. If you a syntax error such as "Missing ]"
55 when you do the make under your usual shell, try this:
60 If you don't like the some of the platform-specific options chosen
61 by the automatic build process (such as the compiler to use, etc),
62 you can intervene and edit them before anything is actually compiled
63 by explicitly doing a "make platform" step, editing the .make-platform
64 file (actually a link to the file to be edited), and then doing a
71 If you want to choose the build platform yourself from among those that
72 the distribution supports, cd to the appropriate directory underneath
73 build/platforms and make from there. For example, if you are on a
74 machine running SunOS 4.1.4 and you want to force the use of the cc
75 compiler, you would do this:
77 % cd build/platforms/sunos4-cc
80 If you want to run some simple tests after the build is complete, you
85 5. install the binaries and man pages. You may need to be superuser to
86 do this (depending on where you are installing things):
91 That's it! See the man pages for the individual clients for information
92 on configuring and using them. Eventually you will probably want to
93 edit the configuration files used by the various clients (installed in
94 the LDAP etc directory). The files are:
96 ldapfilter.conf - search filter configuration
97 ldapfriendly - mapping of X.500 names to human-friendly names
98 ldapsearchprefs.conf - search object definitions
99 ldaptemplates.conf - display template definitions
101 There are section 5 man pages for all of these files.
104 Building LDAP For More Than One Platform
106 It is now possible to build LDAP for more than one platform from the same
107 source tree. This is accomplished by some rules in the Makefiles that
108 create a shadow (linked) directory tree where the binaries are placed.
110 Follow these steps for each different platform:
112 1. move to the directory that matches the platform and compiler you
113 want to build for and type make. The directories are all located
114 underneath the build/platforms directory. If your platform is not
115 there, you may need to do a port - see the build/PORTS file for
116 more information. For a Sun running SunOS 4.1.4, you might do
119 % cd build/platforms/sunos4-cc
122 This will create a linked source area.
125 2. move to the new directory and make as for a single platform. Follow steps
126 1-4 above to accomplish this. For example:
131 That's all there is to it. You can also create the linked source area(s)
132 by just typing "make links" at the top of the distribution, in which case
133 the Makefile will try to automatically determine the platform and
137 End of OpenLDAP INSTALL file.