1 #-----------------------------------------------------------------------------
2 # Copyright (c) 1994 Regents of the University of Michigan.
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.
12 # X.500 ldap fax mailer makefile
14 #-----------------------------------------------------------------------------
16 HDIR = $(LDAPSRC)/include
17 LDIR = $(LDAPSRC)/libraries
18 VERSIONFILE = $(LDAPSRC)/build/version
20 SRCS = rp500.c main.c faxtotpc.c
21 OBJS = rp500.o main.o faxtotpc.o
26 CFLAGS = $(INCLUDES) $(DEFINES) $(ACFLAGS)
27 LIBS = -lldap -llber $(KRBLIBFLAG) $(KRBLIBS) $(ALIBS)
32 $(CC) $(ALDFLAGS) -o $@ faxtotpc.o rp500.o rpversion.o \
36 $(CC) $(ALDFLAGS) -o $@ main.o fax5version.o faxtotpc.o \
39 rpversion.c: faxtotpc.o rp500.o $(LDIR)/libldap.a
41 (u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
42 t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
43 -e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
44 -e "s|%VERSION%|$${v}|" \
47 fax5version.c: main.o faxtotpc.o $(LDIR)/libldap.a
49 (u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
50 t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
51 -e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
52 -e "s|%VERSION%|$${v}|" \
55 install: rp500 xrpcomp fax500 FORCE
56 -$(MKDIR) -p $(ETCDIR) $(BINDIR)
57 $(INSTALL) $(INSTALLFLAGS) -m 755 rp500 $(ETCDIR)
58 $(SED) -e 's%ETCDIR%$(RUNTIMEETCDIR)%' xrpcomp > /tmp/xrpcomp.tmp
59 $(INSTALL) $(INSTALLFLAGS) -m 755 /tmp/xrpcomp.tmp $(BINDIR)/xrpcomp
60 $(RM) /tmp/xrpcomp.tmp
61 $(INSTALL) $(INSTALLFLAGS) -m 755 fax500 $(ETCDIR)
64 $(LINT) $(INCLUDES) $(DEFINES) $(SRCS)
67 $(5LINT) $(INCLUDES) $(DEFINES) $(SRCS)
70 $(RM) *.o core a.out rpversion.c fax5version.c rp500 fax500
73 $(MKDEP) $(INCLUDES) $(DEFINES) $(SRCS)
76 @$(LN) .src/README .src/xrpcomp .src/*.[ch] .
78 # DO NOT DELETE THIS LINE -- mkdep uses it.
79 # DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
81 rp500.o: rp500.c ../../include/ldapconfig.h ../../include/lber.h
82 rp500.o: ../../include/ldap.h
83 main.o: main.c ../../include/ldapconfig.h ../../include/portable.h
84 main.o: ../../include/lber.h ../../include/ldap.h
85 faxtotpc.o: faxtotpc.c
87 # IF YOU PUT ANYTHING HERE IT WILL GO AWAY