3 ## Makefile for LDAP tools
5 SRCS = ldapsearch.c ldapmodify.c ldapdelete.c ldapmodrdn.c ldappasswd.c
6 OBJS = ldapsearch.o ldapmodify.o ldapdelete.o ldapmodrdn.o ldappasswd.o
8 LDAP_INCDIR= ../../include
9 LDAP_LIBDIR= ../../libraries
11 XLIBS = -lldif -lldap -llber -llutil
12 XXLIBS = $(SECURITY_LIBS) $(LDIF_LIBS) $(LUTIL_LIBS)
14 XSRCS = ldsversion.c ldmversion.c lddversion.c ldrversion.c ldpversion.c
16 PROGRAMS = ldapsearch ldapmodify ldapdelete ldapmodrdn ldapadd ldappasswd
18 ldapsearch: ldsversion.o
19 $(LTLINK) -o $@ ldapsearch.o ldsversion.o $(LIBS)
21 ldapmodify: ldmversion.o
22 $(LTLINK) -o $@ ldapmodify.o ldmversion.o $(LIBS)
24 ldapdelete: lddversion.o
25 $(LTLINK) -o $@ ldapdelete.o lddversion.o $(LIBS)
27 ldapmodrdn: ldrversion.o
28 $(LTLINK) -o $@ ldapmodrdn.o ldrversion.o $(LIBS)
30 ldappasswd: ldpversion.o
31 $(LTLINK) -o $@ ldappasswd.o ldpversion.o $(LIBS)
35 $(LN_H) ldapmodify$(EXEEXT) ldapadd$(EXEEXT)
37 ldsversion.c: ldapsearch.o $(LDAP_LIBDEPEND)
39 $(MKVERSION) ldapsearch > $@
41 ldmversion.c: ldapmodify.o $(LDAP_LIBDEPEND)
43 $(MKVERSION) ldapmodify > $@
45 lddversion.c: ldapdelete.o $(LDAP_LIBDEPEND)
47 $(MKVERSION) ldapdelete > $@
49 ldpversion.c: ldappasswd.o $(LDAP_LIBDEPEND)
51 $(MKVERSION) ldappasswd > $@
53 ldrversion.c: ldapmodrdn.o $(LDAP_LIBDEPEND)
55 $(MKVERSION) ldapmodrdn > $@
58 -$(MKDIR) $(DESTDIR)$(bindir)
59 $(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapsearch $(DESTDIR)$(bindir)
60 $(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapmodify $(DESTDIR)$(bindir)
61 $(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapdelete $(DESTDIR)$(bindir)
62 $(LTINSTALL) $(INSTALLFLAGS) -m 755 ldapmodrdn $(DESTDIR)$(bindir)
63 $(LTINSTALL) $(INSTALLFLAGS) -m 755 ldappasswd $(DESTDIR)$(bindir)
64 $(RM) $(DESTDIR)$(bindir)/ldapadd$(EXEEXT)
65 $(LN) ldapmodify$(EXEEXT) $(DESTDIR)$(bindir)/ldapadd$(EXEEXT)