1 # Makefile for LDAP tools
2 # $OpenLDAP: pkg/ldap/clients/tools/Makefile.in,v 1.45.2.3 2008/02/11 23:26:38 kurt Exp $
3 ## This work is part of OpenLDAP Software <http://www.openldap.org/>.
5 ## Copyright 1998-2008 The OpenLDAP Foundation.
6 ## All rights reserved.
8 ## Redistribution and use in source and binary forms, with or without
9 ## modification, are permitted only as authorized by the OpenLDAP
12 ## A copy of this license is available in the file LICENSE in the
13 ## top-level directory of the distribution or, alternatively, at
14 ## <http://www.OpenLDAP.org/license.html>.
16 SRCS
= ldapsearch.c ldapmodify.c ldapdelete.c ldapmodrdn.c \
17 ldappasswd.c ldapwhoami.c ldapcompare.c \
19 OBJS
= ldapsearch.o ldapmodify.o ldapdelete.o ldapmodrdn.o \
20 ldappasswd.o ldapwhoami.o ldapcompare.o \
23 LDAP_INCDIR
= ..
/..
/include
24 LDAP_LIBDIR
= ..
/..
/libraries
29 XXLIBS
= $(SECURITY_LIBS
) $(LUTIL_LIBS
)
31 XSRCS
= ldsversion.c ldmversion.c lddversion.c ldrversion.c \
32 ldpversion.c ldwversion.c ldcversion.c ldeversion.c
34 PROGRAMS
= ldapsearch ldapmodify ldapdelete ldapmodrdn \
35 ldappasswd ldapwhoami ldapcompare ldapexop
38 ldapsearch
: ldsversion.o
39 $(LTLINK
) -o
$@ ldapsearch.o common.o ldsversion.o
$(LIBS
)
41 ldapmodify
: ldmversion.o
42 $(LTLINK
) -o
$@ ldapmodify.o common.o ldmversion.o
$(LIBS
)
44 ldapdelete
: lddversion.o
45 $(LTLINK
) -o
$@ ldapdelete.o common.o lddversion.o
$(LIBS
)
47 ldapmodrdn
: ldrversion.o
48 $(LTLINK
) -o
$@ ldapmodrdn.o common.o ldrversion.o
$(LIBS
)
50 ldappasswd
: ldpversion.o
51 $(LTLINK
) -o
$@ ldappasswd.o common.o ldpversion.o
$(LIBS
)
53 ldapwhoami
: ldwversion.o
54 $(LTLINK
) -o
$@ ldapwhoami.o common.o ldwversion.o
$(LIBS
)
56 ldapcompare
: ldcversion.o
57 $(LTLINK
) -o
$@ ldapcompare.o common.o ldcversion.o
$(LIBS
)
59 ldapexop
: ldeversion.o
60 $(LTLINK
) -o
$@ ldapexop.o common.o ldeversion.o
$(LIBS
)
62 ldsversion.c
: Makefile
64 $(MKVERSION
) $(MKVOPTS
) ldapsearch
> $@
66 ldsversion.o
: ldapsearch.o common.o
$(XLIBS
)
68 ldmversion.c
: Makefile
70 $(MKVERSION
) $(MKVOPTS
) ldapmodify
> $@
72 ldmversion.o
: ldapmodify.o common.o
$(XLIBS
)
74 lddversion.c
: Makefile
76 $(MKVERSION
) $(MKVOPTS
) ldapdelete
> $@
78 lddversion.o
: ldapdelete.o common.o
$(XLIBS
)
80 ldpversion.c
: Makefile
82 $(MKVERSION
) $(MKVOPTS
) ldappasswd
> $@
84 ldpversion.o
: ldappasswd.o common.o
$(XLIBS
)
86 ldrversion.c
: Makefile
88 $(MKVERSION
) $(MKVOPTS
) ldapmodrdn
> $@
90 ldrversion.o
: ldapmodrdn.o common.o
$(XLIBS
)
92 ldwversion.c
: Makefile
94 $(MKVERSION
) $(MKVOPTS
) ldapwhoami
> $@
96 ldwversion.o
: ldapwhoami.o common.o
$(XLIBS
)
98 ldcversion.c
: Makefile
100 $(MKVERSION
) $(MKVOPTS
) ldapcompare
> $@
102 ldcversion.o
: ldapcompare.o common.o
$(XLIBS
)
104 ldeversion.c
: Makefile
106 $(MKVERSION
) $(MKVOPTS
) ldapexop
> $@
108 ldeversion.o
: ldapexop.o common.o
$(XLIBS
)
111 -$(MKDIR
) $(DESTDIR
)$(bindir)
113 for prg in
$(PROGRAMS
); do \
114 $(LTINSTALL
) $(INSTALLFLAGS
) $(STRIP
) -m
755 $$prg$(EXEEXT
) \
115 $(DESTDIR
)$(bindir); \
118 $(RM
) $(DESTDIR
)$(bindir)/ldapadd
$(EXEEXT
)
119 $(LN_S
) $(DESTDIR
)$(bindir)/ldapmodify
$(EXEEXT
) $(DESTDIR
)$(bindir)/ldapadd
$(EXEEXT
)