forked from ajacoutot/toad
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
39 lines (29 loc) · 923 Bytes
/
Makefile
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
PREFIX?= /usr/local
BINDIR= ${PREFIX}/libexec
MANDIR= ${PREFIX}/man/man
SHAREDIR= ${PREFIX}/share
EXAMPLEDIR= ${SHAREDIR}/examples/toad
PROG= toadd
MAN= toad.8 toadd.8
INSTALL_DIR= install -d -o root -g wheel -m 755
INSTALL_SCRIPT= install -c -S -o root -g bin -m 555
CPPFLAGS+= -DLIBEXECDIR=\"${BINDIR}\"
LDADD= -lutil
WARNINGS= Yes
CFLAGS+= -Werror
CLEANFILES= hotplug-scripts
all:
sed -e 's,@PREFIX@,${PREFIX},g' ${.CURDIR}/hotplug-scripts.in > \
${.CURDIR}/hotplug-scripts
afterinstall:
${INSTALL_DIR} -d ${DESTDIR}${EXAMPLEDIR}
${INSTALL_SCRIPT} ${.CURDIR}/hotplug-scripts ${DESTDIR}${EXAMPLEDIR}
${INSTALL_SCRIPT} ${.CURDIR}/toad.pl ${DESTDIR}${BINDIR}/toad
maninstall:
makewhatis ${PREFIX}/man
uninstall:
rm ${DESTDIR}${BINDIR}/toad ${DESTDIR}${BINDIR}/${PROG}
rm ${DESTDIR}${MANDIR}8/toad.8 ${DESTDIR}${MANDIR}8/toadd.8
rm -r ${EXAMPLEDIR}
makewhatis ${PREFIX}/man
.include <bsd.prog.mk>