134 lines
4.0 KiB
Makefile
134 lines
4.0 KiB
Makefile
SHELL = /bin/sh
|
|
SRCS = trivial-rewrite.c rewrite.c resolve.c transport.c
|
|
OBJS = trivial-rewrite.o rewrite.o resolve.o transport.o
|
|
HDRS =
|
|
TESTSRC =
|
|
WARN = -W -Wformat -Wimplicit -Wmissing-prototypes \
|
|
-Wparentheses -Wstrict-prototypes -Wswitch -Wuninitialized \
|
|
-Wunused
|
|
DEFS = -I. -I$(INC_DIR) -D$(SYSTYPE)
|
|
CFLAGS = $(DEBUG) $(OPT) $(DEFS)
|
|
LIB =
|
|
TESTPROG=
|
|
PROG = trivial-rewrite
|
|
LIBS = ../lib/libmaster.a ../lib/libglobal.a ../lib/libutil.a
|
|
LIB_DIR = ../lib
|
|
INC_DIR = ../include
|
|
BIN_DIR = ../libexec
|
|
|
|
.c.o:; $(CC) $(CFLAGS) -c $*.c
|
|
|
|
all: $(PROG) $(LIB)
|
|
|
|
$(PROG): $(OBJS) $(LIBS)
|
|
$(CC) $(CFLAGS) -o $@ $(OBJS) $(LIBS) $(SYSLIBS)
|
|
|
|
Makefile: Makefile.in
|
|
(set -e; echo "# DO NOT EDIT"; $(OPTS) $(SHELL) ../makedefs; cat $?) >$@
|
|
|
|
test: $(TESTPROG)
|
|
|
|
$(BIN_DIR)/$(PROG): $(PROG)
|
|
cp $(PROG) $@
|
|
|
|
update: $(BIN_DIR)/$(PROG)
|
|
|
|
printfck: $(OBJS) $(PROG)
|
|
rm -rf printfck
|
|
mkdir printfck
|
|
cp *.h printfck
|
|
sed '1,/^# do not edit/!d' Makefile >printfck/Makefile
|
|
set -e; for i in *.c; do printfck -f .printfck $$i >printfck/$$i; done
|
|
cd printfck; make "INC_DIR=../../include" `cd ..; ls *.o`
|
|
|
|
lint:
|
|
lint $(DEFS) $(SRCS) $(LINTFIX)
|
|
|
|
clean:
|
|
rm -f *.o *core trivial-rewrite $(TESTPROG) junk $(LIB)
|
|
rm -rf printfck
|
|
|
|
tidy: clean
|
|
|
|
depend: $(MAKES)
|
|
(sed '1,/^# do not edit/!d' Makefile.in; \
|
|
set -e; for i in [a-z][a-z0-9]*.c; do \
|
|
$(CC) -E $(DEFS) $(INCL) $$i | sed -n -e '/^# *1 *"\([^"]*\)".*/{' \
|
|
-e 's//'`echo $$i|sed 's/c$$/o/'`': \1/' -e 'p' -e '}'; \
|
|
done) | grep -v '[.][o][:][ ][/]' >$$$$ && mv $$$$ Makefile.in
|
|
@make -f Makefile.in Makefile
|
|
|
|
# do not edit below this line - it is generated by 'make depend'
|
|
resolve.o: resolve.c
|
|
resolve.o: ../include/sys_defs.h
|
|
resolve.o: ../include/msg.h
|
|
resolve.o: ../include/vstring.h
|
|
resolve.o: ../include/vbuf.h
|
|
resolve.o: ../include/vstream.h
|
|
resolve.o: ../include/vstring_vstream.h
|
|
resolve.o: ../include/split_at.h
|
|
resolve.o: ../include/mail_params.h
|
|
resolve.o: ../include/mail_proto.h
|
|
resolve.o: ../include/iostuff.h
|
|
resolve.o: ../include/mail_addr.h
|
|
resolve.o: ../include/rewrite_clnt.h
|
|
resolve.o: ../include/resolve_local.h
|
|
resolve.o: ../include/mail_conf.h
|
|
resolve.o: ../include/quote_822_local.h
|
|
resolve.o: ../include/tok822.h
|
|
resolve.o: ../include/resolve_clnt.h
|
|
resolve.o: trivial-rewrite.h
|
|
resolve.o: transport.h
|
|
rewrite.o: rewrite.c
|
|
rewrite.o: ../include/sys_defs.h
|
|
rewrite.o: ../include/msg.h
|
|
rewrite.o: ../include/vstring.h
|
|
rewrite.o: ../include/vbuf.h
|
|
rewrite.o: ../include/vstream.h
|
|
rewrite.o: ../include/vstring_vstream.h
|
|
rewrite.o: ../include/split_at.h
|
|
rewrite.o: ../include/mail_params.h
|
|
rewrite.o: ../include/mail_proto.h
|
|
rewrite.o: ../include/iostuff.h
|
|
rewrite.o: ../include/resolve_local.h
|
|
rewrite.o: ../include/tok822.h
|
|
rewrite.o: ../include/resolve_clnt.h
|
|
rewrite.o: ../include/mail_conf.h
|
|
rewrite.o: trivial-rewrite.h
|
|
transport.o: transport.c
|
|
transport.o: ../include/sys_defs.h
|
|
transport.o: ../include/msg.h
|
|
transport.o: ../include/stringops.h
|
|
transport.o: ../include/mymalloc.h
|
|
transport.o: ../include/vstring.h
|
|
transport.o: ../include/vbuf.h
|
|
transport.o: ../include/split_at.h
|
|
transport.o: ../include/dict.h
|
|
transport.o: ../include/vstream.h
|
|
transport.o: ../include/argv.h
|
|
transport.o: ../include/mail_params.h
|
|
transport.o: ../include/maps.h
|
|
transport.o: transport.h
|
|
trivial-rewrite.o: trivial-rewrite.c
|
|
trivial-rewrite.o: ../include/sys_defs.h
|
|
trivial-rewrite.o: ../include/msg.h
|
|
trivial-rewrite.o: ../include/vstring.h
|
|
trivial-rewrite.o: ../include/vbuf.h
|
|
trivial-rewrite.o: ../include/vstream.h
|
|
trivial-rewrite.o: ../include/vstring_vstream.h
|
|
trivial-rewrite.o: ../include/split_at.h
|
|
trivial-rewrite.o: ../include/stringops.h
|
|
trivial-rewrite.o: ../include/dict.h
|
|
trivial-rewrite.o: ../include/argv.h
|
|
trivial-rewrite.o: ../include/mail_params.h
|
|
trivial-rewrite.o: ../include/mail_proto.h
|
|
trivial-rewrite.o: ../include/iostuff.h
|
|
trivial-rewrite.o: ../include/resolve_local.h
|
|
trivial-rewrite.o: ../include/mail_conf.h
|
|
trivial-rewrite.o: ../include/resolve_clnt.h
|
|
trivial-rewrite.o: ../include/rewrite_clnt.h
|
|
trivial-rewrite.o: ../include/tok822.h
|
|
trivial-rewrite.o: ../include/mail_server.h
|
|
trivial-rewrite.o: trivial-rewrite.h
|
|
trivial-rewrite.o: transport.h
|