summaryrefslogtreecommitdiff
path: root/security/audit-packages/Makefile
blob: 2daf482586aa6b44a5c59eb0984e5043077e80d6 (plain)
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
# $NetBSD: Makefile,v 1.23 2003/07/09 13:01:59 aymeric Exp $

DISTNAME=	audit-packages-1.16
WRKSRC=		${WRKDIR}
CATEGORIES=	security pkgtools
MASTER_SITES=	# empty
DISTFILES=	# empty

MAINTAINER=	agc@netbsd.org
COMMENT=	tools to show vulnerabilities in installed packages

NO_CHECKSUM=    yes

.include "../../mk/bsd.prefs.mk"

.if ${OPSYS} == "SunOS"
# This doesn't create readable manual pages. "mandoc" should be added
# to zoularis.
NROFF=		nroff -man
.else
NROFF=		nroff -mandoc
.endif

do-build:
	@for f in audit-packages audit-packages.8 \
		download-vulnerability-list; do	\
		${SED} -e 's|@PKGVULNDIR@|${PKGVULNDIR}|g' 		\
			-e 's|@AWK@|${AWK}|g'				\
			-e 's|@FETCH_CMD@|${FETCH_CMD}|g'		\
			-e 's|@FETCH_CMD_SHORT@|${FETCH_CMD:T}|g'	\
			-e 's|@PKGSRCDIR@|${_PKGSRCDIR}|g'		\
			-e 's|@PKG_TOOLS_BIN@|${PKG_TOOLS_BIN}|g'	\
			-e 's|@SH@|${SH}|g'				\
			${FILESDIR}/$$f > ${WRKSRC}/$$f;		\
	done
	${NROFF} ${WRKSRC}/audit-packages.8 >${WRKSRC}/audit-packages.0

do-install:
	@for f in audit-packages download-vulnerability-list; do	\
		${INSTALL_SCRIPT} ${WRKSRC}/$$f ${PREFIX}/sbin;	\
	done
	${INSTALL_MAN} ${WRKSRC}/audit-packages.0 ${PREFIX}/man/cat8
	${INSTALL_MAN} ${WRKSRC}/audit-packages.8 ${PREFIX}/man/man8
	${LN} -sf audit-packages.0 ${PREFIX}/man/cat8/download-vulnerability-list.0
	${LN} -sf audit-packages.8 ${PREFIX}/man/man8/download-vulnerability-list.8

.include "../../mk/bsd.pkg.mk"