mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-15 03:01:09 +08:00
25 lines
624 B
Makefile
25 lines
624 B
Makefile
PROGRAMS = passwd-shell
|
|
|
|
SRCS = passwd-shell.c shellutil.c
|
|
XSRCS = pwd-version.c
|
|
OBJS = passwd-shell.o shellutil.o
|
|
|
|
LDAP_INCDIR= ../../../include
|
|
LDAP_LIBDIR= ../../../libraries
|
|
|
|
BUILD_OPT = "--enable-shell"
|
|
BUILD_SRV = @BUILD_SHELL@
|
|
|
|
all-local-srv: $(PROGRAMS)
|
|
|
|
passwd-shell: pwd-version.o
|
|
$(CC) $(LDFLAGS) -o $@ $(OBJS) pwd-version.o $(LIBS)
|
|
|
|
pwd-version.c: $(OBJS) $(LDAP_LIBDEPEND)
|
|
$(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}|" \
|
|
< $(srcdir)/pwd-Version.c > $@)
|