Mercurial > bday
annotate makefile @ 24:c621d710d12e default tip
added VERSION to man page
author | markus schnalke <meillo@marmaro.de> |
---|---|
date | Mon, 24 Feb 2014 21:44:02 +0100 |
parents | 4abebbc5eb7e |
children |
rev | line source |
---|---|
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
1 # bday by meillo@marmaro.de |
0
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
2 |
16 | 3 VERSION = 0.2 |
0
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
4 |
23 | 5 DOCS=README COPYING ChangeLog |
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
6 |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
7 # paths |
16 | 8 PREFIX = /usr/local |
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
9 BINDIR = ${PREFIX}/bin |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
10 MANDIR = ${PREFIX}/share/man |
0
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
11 |
5
5af6bf2cb271
reads only stdin now, no files anymore; removed -f option aswell; code beatifing
meillo@marmaro.de
parents:
3
diff
changeset
|
12 CFLAGS=-O2 -Wall |
0
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
13 |
5
5af6bf2cb271
reads only stdin now, no files anymore; removed -f option aswell; code beatifing
meillo@marmaro.de
parents:
3
diff
changeset
|
14 all: build |
16 | 15 build: bday |
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
16 |
16 | 17 bday: bday.o |
18 $(CC) $(LDFLAGS) bday.o -o $@ | |
5
5af6bf2cb271
reads only stdin now, no files anymore; removed -f option aswell; code beatifing
meillo@marmaro.de
parents:
3
diff
changeset
|
19 |
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
20 dist: build changelog |
16 | 21 @mkdir -p bday-${VERSION} |
23 | 22 @cp bday bday.c bday.1 makefile ${DOCS} bday-${VERSION} |
16 | 23 @tar -czhf bday-${VERSION}.tar.gz bday-${VERSION} |
24 @rm -rf bday-${VERSION} | |
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
25 |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
26 changelog: |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
27 @echo generating changelog from mercurial log |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
28 @hg log -v --style changelog > ChangeLog |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
29 |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
30 install: |
16 | 31 @echo installing executable file to ${BINDIR} |
32 @mkdir -p ${BINDIR} | |
33 @cp bday ${BINDIR} | |
34 @chmod 755 ${BINDIR}/bday | |
35 @echo installing manual page to ${MANDIR}/man1 | |
36 @mkdir -p ${MANDIR}/man1 | |
37 @sed 's/VERSION/${VERSION}/g' <bday.1 >${MANDIR}/man1/bday.1 | |
38 @chmod 644 ${MANDIR}/man1/bday.1 | |
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
39 |
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
40 uninstall: |
16 | 41 @echo removing executable file from ${BINDIR} |
42 @rm -f ${BINDIR}/bday | |
43 @echo removing manual page from ${MANDIR}/man1 | |
44 @rm -f ${MANDIR}/man1/bday.1 | |
0
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
45 |
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
46 |
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
47 clean: |
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
48 rm -f *.o |
22b6e71de68e
initial commit; codebase from birthday; just the needed stuff; substituted getopt by own code
meillo@marmaro.de
parents:
diff
changeset
|
49 realclean: clean |
16 | 50 rm -f bday |
3
dc2f94280b01
new Makefile; removed MinWarn and MaxWarn; adjusted manpage
meillo@marmaro.de
parents:
1
diff
changeset
|
51 distclean: realclean |
16 | 52 @rm -f bday-*.tar.gz ChangeLog |