openldap/servers/slapd/shell-backends/Make-template
Kurt Zeilenga d2ef362f99 Removed use of paths not defined in ldapconfig.h.edit.
Fixed Dependency Generation not to mess with Make-templates.
	side effect: depends are not carried forward after "make makefiles"
1998-08-20 03:56:19 +00:00

62 lines
1.7 KiB
Text

#-----------------------------------------------------------------------------
# Copyright (c) 1995 Regents of the University of Michigan.
# All rights reserved.
#
# Redistribution and use in source and binary forms are permitted
# provided that this notice is preserved and that due credit is given
# to the University of Michigan at Ann Arbor. The name of the University
# may not be used to endorse or promote products derived from this
# software without specific prior written permission. This software
# is provided ``as is'' without express or implied warranty.
#
# makefile for shell backends to use with stand-alone LDAP server
#
#-----------------------------------------------------------------------------
LDAPSRC = ../../..
HDIR = $(LDAPSRC)/include
LDIR = $(LDAPSRC)/libraries
VERSIONFILE = $(LDAPSRC)/build/version
CMNSRCS = shellutil.c
CMNOBJS = shellutil.o
PWDSRCS = passwd-shell.c
PWDOBJS = passwd-shell.o pwd-version.o
INCLUDES= -I. -I.. -I$(HDIR)
DEFINES = $(DEFS) $(THREADS)
CFLAGS = $(INCLUDES) $(THREADSINCLUDE) $(DEFINES) $(ACFLAGS)
LDFLAGS = -L$(LDIR) $(KRBLIBFLAG)
LIBS = -llber $(KRBLIBS) $(ALIBS)
all: passwd-shell
passwd-shell: $(PWDOBJS) $(CMNOBJS)
$(CC) $(ALDFLAGS) -o $@ $(PWDOBJS) $(CMNOBJS) \
$(LDFLAGS) $(LIBS)
pwd-version.c: $(OBJS)
$(RM) $@
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
-e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
-e "s|%VERSION%|$${v}|" \
< pwd-Version.c > $@)
install: FORCE
lint: FORCE
$(LINT) $(INCLUDES) $(DEFINES) $(SRCS)
5lint: FORCE
$(5LINT) $(INCLUDES) $(DEFINES) $(SRCS)
clean: FORCE
$(RM) passwd-shell pwd-version.c *.o core a.out version.c
depend: FORCE
$(MKDEP) $(INCLUDES) $(DEFINES) $(SRCS)
links:
@$(LN) .src/*.[ch] .