2 ## Copyright 1998-2000 The OpenLDAP Foundation, All Rights Reserved.
3 ## COPYING RESTRICTIONS APPLY, see COPYRIGHT file
5 ## Makefile.in for LDAP -lldap
8 XLIBRARY = ../libldap_r.a
10 PROGRAMS = apitest ltest ttest
12 XXDIR = $(srcdir)/../libldap
13 XXSRCS = apitest.c test.c tmpltest.c extended.c \
14 bind.c controls.c open.c result.c error.c compare.c search.c \
15 modify.c add.c modrdn.c delete.c abandon.c ufn.c cache.c cyrus.c \
16 getfilter.c sasl.c sbind.c kbind.c unbind.c friendly.c \
17 free.c disptmpl.c srchpref.c dsparse.c tmplout.c sort.c \
18 getdn.c getentry.c getattr.c getvalues.c addentry.c \
19 request.c os-ip.c url.c sortctrl.c vlvctrl.c \
20 init.c options.c print.c string.c util-int.c schema.c \
21 charray.c tls.c dn.c os-local.c dnssrv.c \
23 SRCS = threads.c rdwr.c tpool.c \
24 thr_posix.c thr_cthreads.c thr_thr.c thr_lwp.c thr_nt.c \
26 OBJS = threads.lo rdwr.lo tpool.lo \
27 thr_posix.lo thr_cthreads.lo thr_thr.lo thr_lwp.lo thr_nt.lo \
28 thr_pth.lo thr_stub.lo \
30 bind.lo controls.lo open.lo result.lo error.lo compare.lo search.lo \
31 modify.lo add.lo modrdn.lo delete.lo abandon.lo ufn.lo cache.lo cyrus.lo \
32 getfilter.lo sasl.lo sbind.lo kbind.lo unbind.lo friendly.lo \
33 free.lo disptmpl.lo srchpref.lo dsparse.lo tmplout.lo sort.lo \
34 getdn.lo getentry.lo getattr.lo getvalues.lo addentry.lo \
35 request.lo os-ip.lo url.lo sortctrl.lo vlvctrl.lo \
36 init.lo options.lo print.lo string.lo util-int.lo schema.lo \
37 charray.lo tls.lo dn.lo os-local.lo dnssrv.lo \
40 LDAP_INCDIR= ../../include
41 LDAP_LIBDIR= ../../libraries
43 XDEFS = -DLDAP_R_COMPILE -I$(XXDIR)
44 XLIBS = -lldap_r -llber -llutil
45 XXLIBS = $(SECURITY_LIBS) $(LUTIL_LIBS)
46 XXXLIBS = $(LTHREAD_LIBS)
48 LINKAGE = @LT_LIB_LINKAGE@
50 NT_DYN_LIB_LIBS = -llber -llutil $(AC_LIBS)
51 NT_DYN_LIB_DEFS = -DLBER_DECL=dllimport
52 NT_DYN_TEST_DEFS = -DLBER_DECL=dllimport -DLDAP_DECL=dllimport
54 NT_XXLIBS = $(SECURITY_LIBS)
56 UNIX_DYN_LIB_LIBS = -llber $(AC_LIBS)
57 UNIX_XXLIBS = $(SECURITY_LIBS)
59 # Extras for building the library
60 EXTRA_DEFS = $(@PLAT@_@LIB_LINKAGE@_LIB_DEFS)
61 EXTRA_LIBS = $(@PLAT@_@LIB_LINKAGE@_LIB_LIBS) $(@PLAT@_XXLIBS)
63 # Only the test programs will pick up these defs.
64 CPPFLAGS = $(@PLAT@_@LIB_LINKAGE@_TEST_DEFS)
67 @for i in $(XXSRCS); do \
69 $(LN_S) $(XXDIR)/$$i . ; \
80 apitest: $(LIBRARY) apitest.o $(LDAP_LIBLBER_DEPEND)
81 $(LTLINK) -o $@ apitest.o $(LIBS)
82 ltest: $(LIBRARY) test.o $(LDAP_LIBLBER_DEPEND)
83 $(LTLINK) -o $@ test.o $(LIBS)
84 ttest: $(LIBRARY) tmpltest.o $(LDAP_LIBLBER_DEPEND)
85 $(LTLINK) -o $@ tmpltest.o $(LIBS)
87 install-local: $(CFFILES) FORCE
88 -$(MKDIR) $(DESTDIR)$(libdir)
89 $(LTINSTALL) $(INSTALLFLAGS) -m 644 $(LIBRARY) $(DESTDIR)$(libdir)