2 ## Copyright 1998-2002 The OpenLDAP Foundation, Redwood City, California, USA
3 ## All rights reserved.
5 ## Redistribution and use in source and binary forms, with or without
6 ## modification, are permitted only as authorized by the OpenLDAP
7 ## Public License. A copy of this license is available at
8 ## http://www.OpenLDAP.org/license.html or in file LICENSE in the
9 ## top-level directory of the distribution.
13 RELEASEDATE= @OPENLDAP_RELEASE_DATE@
18 top_builddir = @top_builddir@
21 top_srcdir = @top_srcdir@
24 exec_prefix = @exec_prefix@
25 ldap_subdir = @ldap_subdir@
28 datadir = @datadir@$(ldap_subdir)
29 includedir = @includedir@
32 libexecdir = @libexecdir@
33 localstatedir = @localstatedir@
35 moduledir = @libexecdir@$(ldap_subdir)
37 sharedstatedir = @sharedstatedir@
38 sysconfdir = @sysconfdir@$(ldap_subdir)
39 schemadir = $(sysconfdir)/schema
45 BUILD_LIBS_DYNAMIC = @BUILD_LIBS_DYNAMIC@
48 INSTALL_PROGRAM = @INSTALL_PROGRAM@
49 INSTALL_DATA = @INSTALL_DATA@
50 INSTALL_SCRIPT = @INSTALL_SCRIPT@
55 MKDEP = $(top_srcdir)/build/mkdep $(MKDEPFLAG) \
56 -d "$(srcdir)" -c "$(MKDEP_CC)" -m "$(MKDEP_CFLAGS)"
58 MKDEP_CFLAGS = @OL_MKDEP_FLAGS@
60 MKVERSION = $(top_srcdir)/build/mkversion -v "$(VERSION)"
62 SHTOOL = $(top_srcdir)/build/shtool
65 LIBVERSION = @OPENLDAP_LIBVERSION@
66 LTVERSION = -version-info $(LIBVERSION)
68 # libtool --only flag for libraries: platform specific
69 NT_LTONLY_LIB = --only-$(BUILD_LIBS_DYNAMIC)
70 LTONLY_LIB = $(@PLAT@_LTONLY_LIB)
72 # libtool --only flag for modules: depends on linkage of module
73 # The BUILD_MOD_DYNAMIC macro is defined in each backend Makefile.in file
74 LTONLY_MOD = # --only-$(BUILD_MOD_DYNAMIC)
76 # platform-specific libtool flags
77 NT_LTFLAGS_LIB = -no-undefined -avoid-version -rpath $(libdir)
78 NT_LTFLAGS_MOD = -no-undefined -avoid-version -rpath $(moduledir)
79 UNIX_LTFLAGS_LIB = $(LTVERSION) -rpath $(libdir)
80 UNIX_LTFLAGS_MOD = $(LTVERSION) -rpath $(moduledir)
83 LTFLAGS = $(@PLAT@_LTFLAGS)
84 LTFLAGS_LIB = $(@PLAT@_LTFLAGS_LIB)
85 LTFLAGS_MOD = $(@PLAT@_LTFLAGS_MOD)
87 # LIB_DEFS defined in liblber and libldap Makefile.in files.
88 # MOD_DEFS defined in backend Makefile.in files.
90 # platform-specific LINK_LIBS defined in various Makefile.in files.
91 # LINK_LIBS referenced in library and module link commands.
92 LINK_LIBS = $(@PLAT@_LINK_LIBS)
94 LTLINK = $(LIBTOOL) --mode=link \
95 $(CC) -static $(LT_CFLAGS) $(LDFLAGS) $(LTFLAGS)
97 LTCOMPILE_LIB = $(LIBTOOL) $(LTONLY_LIB) --mode=compile \
98 $(CC) $(LT_CFLAGS) $(LT_CPPFLAGS) $(LIB_DEFS) -c
100 LTLINK_LIB = $(LIBTOOL) $(LTONLY_LIB) --mode=link \
101 $(CC) $(LT_CFLAGS) $(LDFLAGS) $(LTFLAGS_LIB)
103 LTCOMPILE_MOD = $(LIBTOOL) $(LTONLY_MOD) --mode=compile \
104 $(CC) $(LT_CFLAGS) $(LT_CPPFLAGS) $(MOD_DEFS) -c
106 LTLINK_MOD = $(LIBTOOL) $(LTONLY_MOD) --mode=link \
107 $(CC) $(LT_CFLAGS) $(LDFLAGS) $(LTFLAGS_MOD)
109 LTINSTALL = $(LIBTOOL) --mode=install $(INSTALL)
110 LTFINISH = $(LIBTOOL) --mode=finish
112 # Misc UNIX commands used in build environment
119 HOSTNAME = $(SHTOOL) echo -e "%h%d"
123 MAKEINFO = @MAKEINFO@
124 MKDIR = $(SHTOOL) mkdir -p
131 # Misc UNIX commands used in programs
133 SENDMAIL = @SENDMAIL@
136 # MANCOMPRESS=@MANCOMPRESS@
137 # MANCOMPRESSSUFFIX=@MANCOMPRESSSUFFIX@
141 INCLUDEDIR= $(top_srcdir)/include
142 LDAP_INCPATH= -I$(LDAP_INCDIR) -I$(INCLUDEDIR)
143 LDAP_LIBDIR= $(top_builddir)/libraries
145 LUTIL_LIBS = @LUTIL_LIBS@
146 LDIF_LIBS = @LDIF_LIBS@
147 LDBM_LIBS = @LDBM_LIBS@
148 LTHREAD_LIBS = @LTHREAD_LIBS@
150 LDAP_LIBLBER_LA = $(LDAP_LIBDIR)/liblber/liblber.la
151 LDAP_LIBLDAP_LA = $(LDAP_LIBDIR)/libldap/libldap.la
152 LDAP_LIBLDAP_R_LA = $(LDAP_LIBDIR)/libldap_r/libldap_r.la
154 LDAP_LIBAVL_A = $(LDAP_LIBDIR)/libavl/libavl.a
155 LDAP_LIBLDBM_A = $(LDAP_LIBDIR)/libldbm/libldbm.a
156 LDAP_LIBLDIF_A = $(LDAP_LIBDIR)/libldif/libldif.a
157 LDAP_LIBREWRITE_A = $(LDAP_LIBDIR)/librewrite/librewrite.a
158 LDAP_LIBLUNICODE_A = $(LDAP_LIBDIR)/liblunicode/liblunicode.a
159 LDAP_LIBLUTIL_A = $(LDAP_LIBDIR)/liblutil/liblutil.a
161 LDAP_L = $(LDAP_LIBLUTIL_A) $(LDAP_LIBLDIF_A) \
162 $(LDAP_LIBLDAP_LA) $(LDAP_LIBLBER_LA)
163 SLURPD_L = $(LDAP_LIBLDIF_A) $(LDAP_LIBLUTIL_A) \
164 $(LDAP_LIBLDAP_R_LA) $(LDAP_LIBLBER_LA)
165 SLAPD_L = $(LDAP_LIBAVL_A) $(LDAP_LIBLDBM_A) \
166 $(LDAP_LIBLUNICODE_A) $(LDAP_LIBREWRITE_A) \
169 WRAP_LIBS = @WRAP_LIBS@
170 # AutoConfig generated
173 AC_DEFS = @CPPFLAGS@ # @DEFS@
174 AC_LDFLAGS = @LDFLAGS@
177 KRB4_LIBS = @KRB4_LIBS@
178 KRB5_LIBS = @KRB5_LIBS@
179 KRB_LIBS = @KRB4_LIBS@ @KRB5_LIBS@
180 SASL_LIBS = @SASL_LIBS@
181 TLS_LIBS = @TLS_LIBS@
182 AUTH_LIBS = @AUTH_LIBS@
183 SECURITY_LIBS = $(SASL_LIBS) $(KRB_LIBS) $(TLS_LIBS) $(AUTH_LIBS)
185 MODULES_CPPFLAGS = @SLAPD_MODULES_CPPFLAGS@
186 MODULES_LDFLAGS = @SLAPD_MODULES_LDFLAGS@
187 MODULES_LIBS = @MODULES_LIBS@
188 TERMCAP_LIBS = @TERMCAP_LIBS@
189 SLAPD_PERL_LDFLAGS = @SLAPD_PERL_LDFLAGS@
191 SLAPD_SQL_LDFLAGS = @SLAPD_SQL_LDFLAGS@
192 SLAPD_SQL_INCLUDES = @SLAPD_SQL_INCLUDES@
193 SLAPD_SQL_LIBS = @SLAPD_SQL_LIBS@
195 SLAPD_LIBS = @SLAPD_LIBS@ @SLAPD_PERL_LDFLAGS@ @SLAPD_SQL_LDFLAGS@ @SLAPD_SQL_LIBS@ @SLAPD_SLP_LIBS@
196 SLURPD_LIBS = @SLURPD_LIBS@
200 DEFS = $(LDAP_INCPATH) $(XINCPATH) $(XDEFS) $(AC_DEFS) $(DEFINES)
201 CFLAGS = $(AC_CFLAGS) $(DEFS)
202 LDFLAGS = $(LDAP_LIBPATH) $(AC_LDFLAGS) $(XLDFLAGS)
203 LIBS = $(XLIBS) $(XXLIBS) $(AC_LIBS) $(XXXLIBS)
205 LT_CFLAGS = $(AC_CFLAGS)
206 LT_CPPFLAGS = $(DEFS)
208 all: all-common all-local FORCE
209 install: install-common install-local FORCE
210 clean: clean-common clean-local FORCE
211 veryclean: veryclean-common veryclean-local FORCE
212 depend: depend-common depend-local FORCE
218 veryclean-common: clean-common FORCE
227 veryclean-local: clean-local FORCE
236 Makefile: Makefile.in $(top_srcdir)/build/top.mk
241 # empty rule for forcing rules
244 ##---------------------------------------------------------------------------