aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile68
1 files changed, 0 insertions, 68 deletions
diff --git a/Makefile b/Makefile
deleted file mode 100644
index 71eda6b..0000000
--- a/Makefile
+++ /dev/null
@@ -1,68 +0,0 @@
1# See LICENSE file for copyright and license details.
2
3VERSION = post-2.0.2
4
5PREFIX = /usr/local
6MANPREFIX = ${PREFIX}/share/man
7
8CPPFLAGS = -DVERSION=\"${VERSION}\"
9CFLAGS = -std=c99 -pthread -pedantic -Wall -Wextra \
10 -Wno-unused-parameter -O3 ${CPPFLAGS}
11DBGFLAGS = -std=c99 -pthread -pedantic -Wall -Wextra \
12 -Wno-unused-parameter -g ${CPPFLAGS}
13
14CC = cc
15
16all: nissy
17
18nissy: clean
19 ${CC} ${CFLAGS} -o nissy src/*.c
20
21nissy.exe:
22 x86_64-w64-mingw32-gcc ${CFLAGS} -static -o nissy.exe src/*.c
23
24debug:
25 ${CC} ${DBGFLAGS} -o nissy src/*.c
26
27test:
28 ${CC} ${DBGFLAGS} -DTEST -o test src/*.c tests/*.c
29
30clean:
31 rm -rf nissy nissy*.exe nissy*.tar.gz doc/nissy.html doc/nissy.pdf
32
33dist: clean nissy.exe
34 mkdir -p nissy-${VERSION}
35 cp -R LICENSE Makefile INSTALL doc src nissy-${VERSION}
36 groff -Tpdf -mandoc doc/nissy.1 > doc/nissy.pdf
37 groff -Thtml -mandoc doc/nissy.1 > doc/nissy.html
38 cp doc/nissy.pdf nissy-${VERSION}/doc/nissy.pdf
39 cp doc/nissy.html nissy-${VERSION}/doc/nissy.html
40 tar -cf nissy-${VERSION}.tar nissy-${VERSION}
41 gzip nissy-${VERSION}.tar
42 rm -rf nissy-${VERSION}
43 mv nissy.exe nissy-${VERSION}.exe
44
45upload: dist
46 rsync -v --rsync-path=openrsync nissy-${VERSION}.exe \
47 tronto.net:/var/www/htdocs/nissy.tronto.net/
48 rsync -v --rsync-path=openrsync nissy-${VERSION}.tar.gz \
49 tronto.net:/var/www/htdocs/nissy.tronto.net/
50
51website:
52 rsync -rv --rsync-path=openrsync \
53 www/ tronto.net:/var/www/htdocs/nissy.tronto.net
54
55install: nissy
56 mkdir -p ${DESTDIR}${PREFIX}/bin
57 cp -f nissy ${DESTDIR}${PREFIX}/bin/nissy
58 chmod 755 ${DESTDIR}${PREFIX}/bin/nissy
59 mkdir -p ${DESTDIR}${MANPREFIX}/man1
60 sed "s/VERSION/${VERSION}/g" < doc/nissy.1 \
61 > ${DESTDIR}${MANPREFIX}/man1/nissy.1
62 chmod 644 ${DESTDIR}${MANPREFIX}/man1/nissy.1
63
64uninstall:
65 rm -rf ${DESTDIR}${PREFIX}/bin/nissy ${DESTDIR}${MANPREFIX}/man1/nissy.1
66 for s in ${SCRIPTS}; do rm -rf ${DESTDIR}${PREFIX}/bin/$$s; done
67
68.PHONY: all debug test clean dist install uninstall upload

Generated with cgit - Back to sebastiano.tronto.net