$(MAKE) $(MFLAGS) backendslib
$(MAKE) $(MFLAGS) slapd
(cd tools; $(MAKE) $(MFLAGS) all)
+ $(MAKE) $(MFLAGS) all-cffiles
slapd: version.o
$(LTLINK) -o $@ $(OBJS) version.o $(LIBS)
fi
@ls -l libbackends.a
-version.c: libbackends.a $(OBJS) $(LDAP_LIBDEPEND) \
- $(LDAP_LIBDIR)/libldbm.a \
- $(LDAP_LIBDIR)/libavl.a \
- $(LDAP_LIBDIR)/libldif.a \
- $(LDAP_LIBDIR)/liblutil.a \
- $(LDAP_LIBDIR)/liblthread.a
+version.c: libbackends.a $(OBJS) $(SLAPD_LIBDEPEND)
$(RM) $@
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
( cd $$i; $(MAKE) $(MFLAGS) clean ); \
fi; \
done
+ rm -f *.tmp all-cffiles
+
+veryclean-local-srv: FORCE
+ @for i in back-* shell-backends tools; do \
+ if [ -d $$i ]; then \
+ echo; echo " cd $$i; $(MAKE) $(MFLAGS) clean"; \
+ ( cd $$i; $(MAKE) $(MFLAGS) veryclean ); \
+ fi; \
+ done
install-local-srv: install-slapd install-conf install-tools
CFFILES=slapd.conf slapd.at.conf slapd.oc.conf
+all-cffiles:
+ @for i in $(CFFILES); do \
+ tmpcf=$$i.tmp; \
+ $(SED) -e 's;%SYSCONFDIR%;$(sysconfdir);' \
+ -e 's;%LOCALSTATEDIR%;$(localstatedir);' \
+ $(srcdir)/$$i > $$tmpcf ; \
+ done
+ touch all-cffiles
+
install-conf: FORCE
@-$(MKDIR) $(sysconfdir)
@for i in $(CFFILES); do \
- tmpcf=/tmp/$$i.$$ ; \
+ tmpcf=$$i.tmp ; \
if test $$i = slapd.conf ; then \
mode=600 ; \
else \
mode=644 ; \
fi ; \
- $(SED) -e 's;%SYSCONFDIR%;$(sysconfdir);' \
- -e 's;%LOCALSTATEDIR%;$(localstatedir);' \
- $(srcdir)/$$i > $$tmpcf ; \
if test ! -f $(sysconfdir)/$$i; then \
echo "installing $$i in $(sysconfdir)"; \
echo "$(INSTALL) $(INSTALLFLAGS) -m $$mode $$tmpcf $(sysconfdir)/$$i"; \
echo "PRESERVING EXISTING CONFIGURATION FILE $(sysconfdir)/$$i" ; \
fi; \
$(INSTALL) $(INSTALLFLAGS) -m $$mode $$tmpcf $(sysconfdir)/$$i.default ; \
- $(RM) -f $$tmpcf ; \
done
install-tools: FORCE