turn on some better compiler warnings.
[gregoa/bti.git] / Makefile.am
1 bin_PROGRAMS = \
2         bti
3
4 bin_SCRIPTS = \
5         bti-shrink-urls
6
7 bti_SOURCES = \
8         bti.h \
9         config.c \
10         bti.c
11
12 bti_CFLAGS = \
13         $(LIBCURL_CFLAGS) \
14         $(XML_CFLAGS) \
15         $(LIBPCRE_CFLAGS) \
16         $(LIBOAUTH_CFLAGS) \
17         -Wall
18
19 bti_LDADD = \
20         $(LIBCURL_LIBS) \
21         $(XML_LIBS) \
22         $(LIBPCRE_LIBS) \
23         $(LIBOAUTH_LIBS)
24
25 dist_man_MANS = \
26         bti.1 \
27         bti-shrink-urls.1
28
29 EXTRA_DIST = \
30         bti.xml \
31         bti-shrink-urls.xml \
32         bti.example \
33         bti-bashcompletion \
34         RELEASE-NOTES \
35         bti-shrink-urls
36
37 %.1: %.xml
38         $(XSLTPROC) -nonet http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
39
40 MAINTAINERCLEANFILES = \
41         $(dist_man_MANS)
42
43 git-clean:
44         rm -f Makefile.in
45
46 distclean-local:
47         rm -rf autom4te.cache
48
49 PREVIOUS_VERSION = 0`expr $(VERSION) - 1`
50
51 changelog:
52         @ head -1 ChangeLog | grep -q "to v$(PREVIOUS_VERSION)"
53         @ mv ChangeLog ChangeLog.tmp
54         @ echo "Summary of changes from v$(PREVIOUS_VERSION) to v$(VERSION)" >> ChangeLog
55         @ echo "============================================" >> ChangeLog
56         @ echo >> ChangeLog
57         @ git log --pretty=short $(PREVIOUS_VERSION)..HEAD | git shortlog  >> ChangeLog
58         @ echo >> ChangeLog
59         @ cat ChangeLog
60         @ cat ChangeLog.tmp >> ChangeLog
61         @ rm ChangeLog.tmp
62
63 git-release:
64         head -1 ChangeLog | grep -q "to v$(VERSION)"
65         head -1 RELEASE-NOTES | grep -q "bti $(VERSION)"
66         git commit -a -m "release $(VERSION)"
67         cat .git/refs/heads/master > .git/refs/tags/$(VERSION)
68         git gc
69         git prune
70
71 AUTOMAKE_OPTIONS = foreign