Commit d0339b19 authored by Kurt Zeilenga's avatar Kurt Zeilenga
Browse files

Fix VPATH includes/libraries

parent 57d861cd
......@@ -59,10 +59,12 @@ SENDMAIL = @SENDMAIL@
# 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@
......@@ -75,8 +77,8 @@ LIBTERMCAP = @LIBTERMCAP@
# 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)
......@@ -34,6 +35,6 @@ install: $(PROGRAMS) xrpcomp FORCE
-$(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
......@@ -2,9 +2,9 @@ SRCS= main.c
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)
......
......@@ -8,9 +8,9 @@ XSRCS= gwversion.o goversion.o
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)
......
......@@ -4,9 +4,8 @@ SRCS= main.c
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)
......
......@@ -4,9 +4,8 @@ XSRCS= version.c
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)
......
......@@ -5,9 +5,8 @@ SRCS = ldapsearch.c ldapmodify.c ldapdelete.c ldapmodrdn.c
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
......
......@@ -6,9 +6,8 @@ OBJS= main.o find.o mod.o print.o auth.o util.o help.o \
HDRS= ud.h
PROGRAMS= ud
VINCLUDEDIR= -I../../include
VLIBDIR= ../../libraries
VLIBS= -L$(VLIBDIR)
LDAP_INCDIR= ../../include
LDAP_LIBDIR= ../../libraries
XLIBS = $(LIBTERMCAP)
......
......@@ -6,6 +6,9 @@ SRCS = avl.c testavl.c
XSRCS = version.c
OBJS = avl.o
LDAP_INCDIR= ../../include
LDAP_LIBDIR= ../../libraries
LIBRARY = libavl.a
XPROGRAMS = testavl
......
......@@ -6,6 +6,9 @@ SRCS = decode.c encode.c io.c bprint.c
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
......
......@@ -3,9 +3,10 @@
##
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 \
......
......@@ -7,10 +7,11 @@ XPROGRAMS = testldbm
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)
......@@ -5,3 +5,7 @@
LIBRARY = libldif.a
SRCS = line64.c
OBJS = line64.o
LDAP_INCDIR= ../../include
LDAP_LIBDIR= ../../libraries
......@@ -7,5 +7,10 @@ XSRCS = version.c
SRCS = thread.c stack.c
OBJS = thread.o stack.o
LDAP_INCDIR= ../../include
LDAP_LIBDIR= ../../libraries
XDEFS = @LTHREAD_DEFS@
XLIBS = @LTHREAD_LIBS@
......@@ -6,4 +6,7 @@ LIBRARY = liblutil.a
SRCS = base64.c md5.c sha1.c
OBJS = base64.o md5.o sha1.o
LDAP_INCDIR= ../../include
LDAP_LIBDIR= ../../libraries
XDEFS = @LUTIL_DEFS@
......@@ -11,9 +11,8 @@ OBJS = main.o detach.o setproctitle.o request.o bind.o result.o error.o \
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@
......
......@@ -18,9 +18,8 @@ OBJS = main.o daemon.o connection.o search.o filter.o add.o charray.o \
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@
......@@ -70,7 +69,7 @@ libbackends.a: .backend
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 \
......
......@@ -7,12 +7,13 @@ OBJS = idl.o add.o search.o cache.o dbcache.o dn2id.o id2entry.o \
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
......@@ -25,7 +26,7 @@ libback-ldbm.a: version.o
@$(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
......@@ -18,7 +20,7 @@ libback-passwd.a: version.o
@$(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}|" \
......
......@@ -3,13 +3,15 @@ SRCS = init.c config.c fork.c search.c bind.c unbind.c add.c delete.c \
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
......@@ -20,7 +22,7 @@ libback-shell.a: version.o
@$(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}|" \
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment