1 #-----------------------------------------------------------------------------
2 # Copyright (c) 1995 Regents of the University of Michigan.
5 # Redistribution and use in source and binary forms are permitted
6 # provided that this notice is preserved and that due credit is given
7 # to the University of Michigan at Ann Arbor. The name of the University
8 # may not be used to endorse or promote products derived from this
9 # software without specific prior written permission. This software
10 # is provided ``as is'' without express or implied warranty.
12 # ldbm backend to stand-alone LDAP server makefile
14 #-----------------------------------------------------------------------------
16 HDIR = $(LDAPSRC)/include
17 LDIR = $(LDAPSRC)/libraries
18 VERSIONFILE = $(LDAPSRC)/build/version
20 SRCS = idl.c add.c search.c cache.c dbcache.c dn2id.c id2entry.c \
21 index.c id2children.c nextid.c abandon.c compare.c \
22 modify.c modrdn.c delete.c init.c config.c bind.c attr.c \
23 filterindex.c unbind.c kerberos.c close.c
24 OBJS = idl.o add.o search.o cache.o dbcache.o dn2id.o id2entry.o \
25 index.o id2children.o nextid.o abandon.o compare.o \
26 modify.o modrdn.o delete.o init.o config.o bind.o attr.o \
27 filterindex.o unbind.o kerberos.o close.o
29 INCLUDES= -I. -I.. -I$(HDIR) $(KRBINCLUDEFLAG)
30 DEFINES = $(DEFS) $(THREADS)
31 CFLAGS = $(INCLUDES) $(THREADSINCLUDE) $(DEFINES) $(ACFLAGS)
32 LDFLAGS = -L$(LDIR) $(KRBLIBFLAG)
35 -@echo "$(SLAPD_BACKENDS)" | grep LDAP_LDBM 2>&1 > /dev/null; \
36 if [ $$? = 0 ]; then \
37 $(MAKE) $(MFLAGS) CC="$(CC)" libback-ldbm.a; \
39 echo "Include -DLDAP_LDBM in SLAPD_BACKENDS in the"; \
40 echo "Make-common file to build the ldbm backend"; \
43 libback-ldbm.a: version.o
44 $(AR) ruv $@ $(OBJS) version.o
45 @if [ ! -z "$(RANLIB)" ]; then \
52 (u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
53 t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
54 -e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
55 -e "s|%VERSION%|$${v}|" \
59 $(LINT) $(INCLUDES) $(DEFINES) $(SRCS)
62 $(5LINT) $(INCLUDES) $(DEFINES) $(SRCS)
65 $(RM) libback-ldbm.a *.o core a.out version.c
68 $(MKDEP) $(INCLUDES) $(DEFINES) $(SRCS)
72 # DO NOT DELETE THIS LINE -- mkdep uses it.
73 # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
75 idl.o: idl.c ../../../include/avl.h ../../../include/proto-lber.h
76 idl.o: ../../../include/proto-ldap.h ../../../include/ldif.h back-ldbm.h
77 add.o: add.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
78 add.o: ../../../include/ldif.h ../../../include/ldbm.h
79 search.o: search.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
80 search.o: ../../../include/ldif.h ../../../include/ldbm.h
81 cache.o: cache.c ../../../include/avl.h ../../../include/proto-lber.h
82 cache.o: ../../../include/proto-ldap.h ../../../include/ldif.h
83 cache.o: ../../../include/ldbm.h
84 dbcache.o: dbcache.c ../../../include/portable.h ../../../include/avl.h
85 dbcache.o: ../../../include/proto-lber.h ../../../include/proto-ldap.h
86 dbcache.o: ../../../include/ldif.h back-ldbm.h
87 dn2id.o: dn2id.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
88 dn2id.o: ../../../include/ldif.h ../../../include/ldbm.h
89 id2entry.o: id2entry.c ../../../include/avl.h ../../../include/proto-lber.h
90 id2entry.o: ../../../include/proto-ldap.h ../../../include/ldif.h
91 id2entry.o: ../../../include/ldbm.h
92 index.o: index.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
93 index.o: ../../../include/ldif.h ../../../include/ldbm.h
94 id2children.o: id2children.c ../../../include/proto-lber.h
95 id2children.o: ../../../include/proto-ldap.h ../../../include/ldif.h
96 id2children.o: ../../../include/ldbm.h
97 nextid.o: nextid.c ../../../include/avl.h ../../../include/proto-lber.h
98 nextid.o: ../../../include/proto-ldap.h ../../../include/ldif.h
99 nextid.o: ../../../include/ldbm.h
101 compare.o: compare.c ../../../include/proto-lber.h
102 compare.o: ../../../include/proto-ldap.h ../../../include/ldif.h
103 compare.o: ../../../include/ldbm.h
104 modify.o: modify.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
105 modify.o: ../../../include/ldif.h ../../../include/ldbm.h
106 modrdn.o: modrdn.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
107 modrdn.o: ../../../include/ldif.h ../../../include/ldbm.h
108 delete.o: delete.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
109 delete.o: ../../../include/ldif.h ../../../include/ldbm.h
110 init.o: init.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
111 init.o: ../../../include/ldif.h ../../../include/ldbm.h
112 config.o: config.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
113 config.o: ../../../include/ldif.h ../../../include/ldbm.h
114 bind.o: bind.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
115 bind.o: ../../../include/ldif.h ../../../include/ldbm.h
116 attr.o: attr.c ../../../include/proto-lber.h ../../../include/proto-ldap.h
117 attr.o: ../../../include/ldif.h ../../../include/ldbm.h
118 filterindex.o: filterindex.c ../../../include/avl.h
119 filterindex.o: ../../../include/proto-lber.h ../../../include/proto-ldap.h
120 filterindex.o: ../../../include/ldif.h ../../../include/ldbm.h
121 unbind.o: unbind.c ../../../include/avl.h ../../../include/proto-lber.h
122 unbind.o: ../../../include/proto-ldap.h ../../../include/ldif.h
123 kerberos.o: kerberos.c ../../../include/proto-lber.h
124 kerberos.o: ../../../include/proto-ldap.h ../../../include/ldif.h
125 kerberos.o: ../../../include/ldbm.h
126 close.o: close.c ../../../include/avl.h ../../../include/proto-lber.h
127 close.o: ../../../include/proto-ldap.h ../../../include/ldif.h
128 close.o: ../../../include/ldbm.h
130 # IF YOU PUT ANYTHING HERE IT WILL GO AWAY