# Version
VERSIONFILE = $(top_srcdir)/build/version
-INCLUDEDIR = -I$(top_srcdir)/include
+INCLUDEDIR = $(top_srcdir)/include
+LDAP_INCPATH = -I$(LDAP_INCDIR) -I$(INCLUDEDIR)
+LDAP_LIBPATH = -L$(LDAP_LIBDIR)
-LDAP_LIBS = -lldif -lldap -llber
-LDAP_LIBDEPEND = $(VLIBDIR)/libldif.a $(VLIBDIR)/libldap.a $(VLIBDIR)/liblber.a
+LDAP_LIBS = $(LDAP_LIBPATH) -lldif -lldap -llber
+LDAP_LIBDEPEND = $(LDAP_LIBDIR)/libldif.a $(LDAP_LIBDIR)/libldap.a $(LDAP_LIBDIR)/liblber.a
# AutoConfig generated
AC_CC = @CC@
# Our Defaults
CC = $(AC_CC)
-DEFS = $(LDAP_DEFS) $(VINCLUDEDIR) $(INCLUDEDIR) $(XDEFS) $(AC_DEFS)
-LIBS = $(VLIBS) $(LDAP_LIBS) $(XLIBS) $(AC_LIBS)
+DEFS = $(LDAP_DEFS) $(LDAP_INCPATH) $(XINCPATH) $(XDEFS) $(AC_DEFS)
+LIBS = $(LDAP_LIBS) $(XLIBS) $(AC_LIBS)
CFLAGS = $(AC_CFLAGS) $(DEFS) $(DEFINES)
LDFLAGS = $(AC_LDFLAGS)
+PROGRAMS= rp500 fax500
+
SRCS= main.c faxtotpc.c rp500.c
XSRCS=fax5version.c rpversion.c
+
FAX5OBJS = main.o faxtotpc.o
RPOBJS = rp500.o faxtotpc.o
-PROGRAMS= rp500 fax500
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
rp500 : rpversion.o
$(CC) $(LDFLAGS) -o $@ $(RPOBJS) rpversion.o $(LIBS)
-$(MKDIR) -p $(libexecdir)
$(INSTALL) $(INSTALLFLAGS) -m 755 rp500 $(libexecdir)
$(INSTALL) $(INSTALLFLAGS) -m 755 fax500 $(libexecdir)
- $(SED) -e 's%LIBEXECDIR%$(libexecdir)%' xrpcomp > /tmp/xrpcomp.tmp
+ $(SED) -e 's%LIBEXECDIR%$(libexecdir)%' $(srcdir)/xrpcomp > /tmp/xrpcomp.tmp
$(INSTALL) $(INSTALLFLAGS) -m 755 /tmp/xrpcomp.tmp $(libexecdir)/xrpcomp
$(RM) /tmp/xrpcomp.tmp
XSRCS= version.c
OBJS= main.o
PROGRAMS= in.xfingerd
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
in.xfingerd : version.o
$(CC) $(LDFLAGS) -o $@ version.o $(OBJS) $(LIBS)
GOOBJS = go500.o detach.o setproctitle.o
GWOBJS = go500gw.o detach.o setproctitle.o
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
+
go500 : goversion.o
$(CC) $(LDFLAGS) -o $@ $(GOOBJS) goversion.o $(LIBS)
XSRCS= version.c
OBJS= main.o
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
mail500 : version.o
$(CC) $(LDFLAGS) -o $@ version.o $(OBJS) $(LIBS)
OBJS= main.o cmds.o help.o query.o
HDRS= rcpt500.h
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
rcpt500 : version.o
$(CC) $(LDFLAGS) -o $@ version.o $(OBJS) $(LIBS)
OBJS = ldapsearch.o ldapmodify.o ldapdelete.o ldapmodrdn.o
XLIBS = -llber -lldap
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
XSRCS = ldsversion.c ldmversion.c lddversion.c ldrversion.c
HDRS= ud.h
PROGRAMS= ud
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
XLIBS = $(LIBTERMCAP)
XSRCS = version.c
OBJS = avl.o
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
+
LIBRARY = libavl.a
XPROGRAMS = testavl
OBJS = decode.o encode.o io.o bprint.o
XSRCS = version.c
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
+
LIBRARY = liblber.a
install-local: $(LIBRARY) FORCE
##
LIBRARY = libldap.a
PROGRAMS = ltest ttest
-VINCLUDEDIR = -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L(VLIBDIR)
+
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
+
SRCS = bind.c open.c result.c error.c compare.c search.c \
modify.c add.c modrdn.c delete.c abandon.c ufn.c cache.c \
SRCS = ldbm.c
OBJS = ldbm.o
-XDEFS = @LDBM_DEFS@
-XLIBS = @LDBM_LIBS@
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
-LIBS = -L$(LDAP_LIBDIR) -lavl $(AC_LIBS)
+XDEFS = @LDBM_DEFS@
+XLIBS = @LDBM_LIBS@ -lavl
testldbm: libldbm.a testldbm.o
$(CC) $(LDFLAGS) -o $@ testldbm.o $(LIBS)
LIBRARY = libldif.a
SRCS = line64.c
OBJS = line64.o
+
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
+
SRCS = thread.c stack.c
OBJS = thread.o stack.o
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
+
XDEFS = @LTHREAD_DEFS@
XLIBS = @LTHREAD_LIBS@
+
+
SRCS = base64.c md5.c sha1.c
OBJS = base64.o md5.o sha1.o
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
+
XDEFS = @LUTIL_DEFS@
abandon.o syntax.o association.o kerberos.o LDAP_tables.o \
certificate.o
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
BUILD_OPT = "--enable-ldapd"
BUILD_SRV = @BUILD_LDAPD@
detach.o strdup.o tempnam.o repl.o lock.o \
schema.o schemaparse.o monitor.o configinfo.o
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
BUILD_OPT = "--enable-slapd"
BUILD_SRV = @BUILD_SLAPD@
fi
@ls -l libbackends.a
-version.c: libbackends.a $(OBJS) \
+version.c: libbackends.a $(OBJS) $(LDAP_LIBDEPEND) \
$(LDAP_LIBDIR)/liblber.a \
$(LDAP_LIBDIR)/liblldbm.a \
$(LDAP_LIBDIR)/liblavl.a \
modify.o modrdn.o delete.o init.o config.o bind.o attr.o \
filterindex.o unbind.o kerberos.o close.o
-VINCLUDEDIR= -I../../../include -I$(srcdir)/..
+LDAP_INCDIR= ../../../include
+LDAP_LIBDIR= ../../../libraries
BUILD_OPT = "--enable-ldbm"
BUILD_SRV = @BUILD_LDBM@
-XINCLUDEDIR = -I..
+XINCPATH = -I.. -I$(srcdir)/..
XDEFS = @SLAPD_DEFS@ @LDBM_DEFS@ @LTHREAD_DEFS@ @LUTIL_DEFS@
PROGRAMS = libback-ldbm.a
@$(RANLIB) $@
@touch ../.backend
-version.c: $(OBJS)
+version.c: $(OBJS) $(LDAP_LIBDEPEND)
$(RM) $@
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` \
h=`$(HOSTNAME)` t=`$(DATE)`; \
SRCS = search.c config.c
OBJS = search.o config.o
-VINCLUDEDIR= -I../../../include
+LDAP_INCDIR= ../../../include
+LDAP_LIBDIR= ../../../libraries
BUILD_OPT = "--enable-passwd"
BUILD_SRV = @BUILD_PASSWD@
PROGRAMS= libback-passwd.a
-XINCLUDEDIR= -I..
+
+XINCPATH = -I.. -I$(srcdir)/..
XDEFS = @LTHREAD_DEFS@
all-local: FORCE
@$(RANLIB) $@
@touch ../.backend
-version.c: $(OBJS)
+version.c: $(OBJS) $(LDAP_LIBDEPEND)
$(RM) $@
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
OBJS = init.o config.o fork.o search.o bind.o unbind.o add.o delete.o \
modify.o modrdn.o compare.o abandon.o result.o
-VINCLUDEDIR= -I../../../include
+LDAP_INCDIR= ../../../include
+LDAP_LIBDIR= ../../../libraries
BUILD_OPT = "--enable-shell"
BUILD_SRV = @BUILD_SHELL@
PROGRAMS = libback-shell.a
-XINCLUDEDIR = -I..
+
+XINCPATH = -I.. -I$(srcdir)/..
XDEFS = @LTHREAD_DEFS@
all-local: FORCE
@$(RANLIB) $@
@touch ../.backend
-version.c: $(OBJS)
+version.c: $(OBJS) $(LDAP_LIBDEPEND)
$(RM) $@
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
XSRCS = pwd-version.c
OBJS = passwd-shell.o shellutil.o
-VINCLUDEDIR= -I../../../include
+LDAP_INCDIR= ../../../include
+LDAP_LIBDIR= ../../../libraries
passwd-shell: pwd-version.o
$(CC) $(LDFLAGS) -o $@ $(OBJS) pwd-version.o $(LIBS)
-pwd-version.c: $(OBJS)
+pwd-version.c: $(OBJS) $(LDAP_LIBDEPEND)
$(RM) $@
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
HAVE_ISODE = @HAVE_ISODE@
BUILD_LDBM = @BUILD_LDBM@
-VINCLUDEDIR= -I../../../include
-VLIBDIR= ../../../libraries
-VLIBS = -L$(VLIBDIR)
+LDAP_INCDIR= ../../../include
+LDAP_LIBDIR= ../../../libraries
PROGRAMS=ldif2index ldif2ldbm ldbmcat ldif2id2entry \
ldif2id2children centipede ldbmtest ldif
reject.o replica.o replog.o ri.o rq.o sanity.o st.o \
tsleep.o
-VINCLUDEDIR= -I../../include
-VLIBDIR= ../../libraries
-VLIBS= -L$(VLIBDIR)
+LDAP_INCDIR= ../../include
+LDAP_LIBDIR= ../../libraries
BUILD_OPT = "--enable-slurpd"
BUILD_SRV = @BUILD_SLURPD@
slurpd: version.o
$(CC) $(LDFLAGS) -o $@ $(OBJS) version.o $(LIBS)
-version.c: $(OBJS) $(LDAP_LIBDIR)/liblber.a $(LDAP_LIBDIR)/libldap.a
+version.c: $(OBJS) $(LDAP_LIBDEPEND)
$(RM) $@
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \