thisconfigdir=../../../..
myfulldir=plugins/kdb/ldap/ldap_util
mydir=plugins/kdb/ldap/ldap_util
BUILDTOP=$(REL)..$(S)..$(S)..$(S)..
DEFINES = -DKDB4_DISABLE
DEFS=
LOCALINCLUDES = -I. @KRB4_INCLUDES@ -I$(srcdir)/../libkdb_ldap -I$(SRCTOP)/lib/kdb
PROG_LIBPATH=-L$(TOPLIBD) $(KRB4_LIBPATH)
PROG_RPATH=$(KRB5_LIBDIR)
#KDB_DEP_LIB=$(DL_LIB) $(THREAD_LINKOPTS)
KDB_DEP_LIB=$(DL_LIB) -lkdb_ldap $(THREAD_LINKOPTS)

PROG = kdb5_ldap_util
OBJS = kdb5_ldap_util.o kdb5_ldap_list.o kdb5_ldap_realm.o kdb5_ldap_policy.o kdb5_ldap_services.o

GETDATE = ../../../../kadmin/cli/getdate.o

all:: $(PROG)

$(PROG): $(OBJS) $(KADMSRV_DEPLIBS) $(KRB4COMPAT_DEPLIBS) $(GETDATE)
	$(CC_LINK) -o $(PROG) $(OBJS) $(GETDATE) \
		$(KADMSRV_LIBS) $(KDB_DEP_LIB) $(KRB4COMPAT_LIBS)

install::
	$(INSTALL_PROGRAM) $(PROG) ${DESTDIR}$(ADMIN_BINDIR)/$(PROG)
	$(INSTALL_DATA) $(srcdir)/$(PROG).M ${DESTDIR}$(ADMIN_MANDIR)/$(PROG).8

clean::
	$(RM) $(PROG) $(OBJS) 
