-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile.in
93 lines (75 loc) · 2.29 KB
/
Makefile.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# $Id: Makefile.in,v 1.11 2003/09/17 06:41:25 joshk Exp $
# Small Makefile to ease building of maildirtree
# Used for make dist
VERSION = @PACKAGE_VERSION@
NAME = @PACKAGE_NAME@
exclusions = .cvsignore autogen.sh CVS maildirtree.1.sgml .svn
# Used for compilation targets
CC = @CC@
CFLAGS = @CFLAGS@
DEFS = -D_GNU_SOURCE
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
# Used for installation
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
mandir = @mandir@
OBJS = snprintf.o maildirtree.o
DBM = @DBM@
default: all
all: maildirtree maildirtree.1.gz
maildirtree.1.gz: maildirtree.1
gzip -9c $< > $@
maildirtree.1: $(wildcard maildirtree.1.sgml)
$(DBM) $< > $@
maildirtree: $(OBJS)
$(CC) $(CFLAGS) $(OBJS) -o $@
maildirtree.o: maildirtree.c config.h maildirtree.h snprintf.h
snprintf.o: snprintf.c config.h snprintf.h
%.o: %.c
$(CC) -c $(CFLAGS) $(DEFS) $< -o $@
config.h:
sh configure
clean:
rm -f *.o maildirtree maildirtree.1.gz core a.out
# We can delete maildirtree.1 if we know we can build it again.
ifneq (,$(wildcard maildirtree.1.sgml))
ifneq (,$(DBM))
rm -f maildirtree.1
endif
endif
distclean: clean
rm -f Makefile config.log config.status config.h *~
rm -rf autom4te.cache
install: maildirtree
$(INSTALL) -d $(DESTDIR)$(bindir)
$(INSTALL) -d $(DESTDIR)$(mandir)/man1/
$(INSTALL_PROGRAM) -m 755 $< $(DESTDIR)$(bindir)/
$(INSTALL) -m 644 maildirtree.1.gz $(DESTDIR)$(mandir)/man1/
uninstall:
rm -f $(DESTDIR)$(bindir)/maildirtree
rm -f $(DESTDIR)$(mandir)/man1/maildirtree.1.gz
dist: distclean
autoheader
autoconf
rm -rf autom4te.cache *~
ifeq (,$(wildcard install-sh))
cp -f /usr/share/automake/install-sh .
endif
docbook-to-man maildirtree.1.sgml > maildirtree.1
(cd .. && ln -sf $(CURDIR) $(NAME)-$(VERSION))
(cd .. && tar $(addprefix --exclude ,$(exclusions)) -chzf $(NAME)-$(VERSION).tar.gz $(NAME)-$(VERSION))
rm -rf ../$(NAME)-$(VERSION)
@echo; echo "Created source release $(VERSION):"; echo
@md5sum ../$(NAME)-$(VERSION).tar.gz
@echo
@tar tzvf ../$(NAME)-$(VERSION).tar.gz
@echo
@if test "`whoami`" = "joshk"; then \
rm -f ../$(NAME)-$(VERSION).tar.gz.sign; \
cd ..; \
gpg -o $(NAME)-$(VERSION).tar.gz.sign --sign -a -b $(NAME)-$(VERSION).tar.gz;\
fi
rm -f maildirtree.1
.PHONY: clean distclean install uninstall dist default all