]> git.sur5r.net Git - openldap/blob - clients/finger/Make-template
LDAPworld P3: SLAPD LDBM Generation with Multiple Backends
[openldap] / clients / finger / Make-template
1 #-----------------------------------------------------------------------------
2 # Copyright (c) 1994 Regents of the University of Michigan.
3 # All rights reserved.
4 #
5 # Redistribution and use in source and binary forms are permitted
6 # provided that this notice is preserved and that due credit is given
7 # to the University of Michigan at Ann Arbor. The name of the University
8 # may not be used to endorse or promote products derived from this
9 # software without specific prior written permission. This software
10 # is provided ``as is'' without express or implied warranty.
11 #
12 #       X.500 ldap finger daemon makefile
13 #
14 #-----------------------------------------------------------------------------
15
16 LDAPSRC = ../..
17 HDIR    = $(LDAPSRC)/include
18 LDIR    = $(LDAPSRC)/libraries
19 VERSIONFILE = $(LDAPSRC)/build/version
20
21 SRCS    = main.c
22 OBJS    = main.o
23
24 INCLUDES=-I$(HDIR)
25 DEFINES = $(DEFS)
26
27 CFLAGS  = $(INCLUDES) $(DEFINES) $(ACFLAGS)
28 LIBS    = -lldap -llber $(KRBLIBFLAG) $(KRBLIBS) $(ALIBS)
29
30 all:    in.xfingerd
31
32 in.xfingerd:    version.o
33         $(CC) $(ALDFLAGS) -o $@ $(OBJS) version.o \
34                 -L$(LDIR) $(LIBS)
35
36 version.c:      $(OBJS) $(LDIR)/libldap.a
37         $(RM) $@
38         (u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
39          t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
40         -e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
41         -e "s|%VERSION%|$${v}|" \
42         < Version.c > $@)
43
44 install:        in.xfingerd FORCE
45         -$(MKDIR) -p $(ETCDIR)
46         $(INSTALL) $(INSTALLFLAGS) -m 755 in.xfingerd $(ETCDIR)
47
48 lint:   FORCE
49         $(LINT) $(INCLUDES) $(DEFINES) $(SRCS)
50
51 5lint:  FORCE
52         $(5LINT) $(INCLUDES) $(DEFINES) $(SRCS)
53
54 clean:  FORCE
55         $(RM) *.o core a.out version.c in.xfingerd
56
57 depend: FORCE
58         $(MKDEP) $(INCLUDES) $(DEFINES) $(SRCS)
59
60 links:
61         @$(LN) .src/README .src/*.[ch] .
62
63 # DO NOT DELETE THIS LINE -- mkdep uses it.
64 # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
65
66 main.o: main.c ../../include/ldap.h ../../include/proto-ldap.h
67 main.o: ../../include/portable.h
68
69 # IF YOU PUT ANYTHING HERE IT WILL GO AWAY