aboutsummaryrefslogtreecommitdiff
path: root/mail/milter-bogom/Makefile
blob: 6153c7679697c6b6c5a4285e28e635b9cb5f2f7c (plain) (blame)
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
48
49
50
51
52
53
54
55
56
# New ports collection makefile for:	milter-bogom
# Date created:			12 Feb 2005
# Whom:				Victor Balada Diaz <victor@bsdes.net>
#
# $FreeBSD$
#

PORTNAME=	bogom
PORTVERSION=	1.9.2
PORTREVISION=	2
CATEGORIES=	mail
MASTER_SITES=	http://www.usebox.net/jjm/bogom/ \
		http://blackshell.usebox.net/bogom/
PKGNAMEPREFIX=	milter-

MAINTAINER=	victor@bsdes.net
COMMENT=	Simple sendmail milter to interface bogofilter

RUN_DEPENDS=	bogofilter:${PORTSDIR}/mail/bogofilter

MAN8=		bogom.8

MAKE_ARGS=	CPPFLAGS="-DDEF_CONF=\\\"${PREFIX}/etc/bogom.conf\\\" ${PTHREAD_CFLAGS}" \
		LIBS="-lmilter ${PTHREAD_LIBS}"

USE_RC_SUBR=	milter-bogom
SUB_FILES=	pkg-message

PLIST_FILES=	sbin/bogom \
		etc/bogom.conf-example

PORTDOCS=	README CHANGELOG

post-patch:
	@${REINPLACE_CMD} -e 's|/etc|${PREFIX}/etc|g' ${WRKSRC}/bogom.8
	@${REINPLACE_CMD} -e \
		's|/usr/local/bin/bogofilter|${LOCALBASE}/bin/bogofilter|g' \
		${WRKSRC}/bogom.8 \
		${WRKSRC}/bogom.conf-example \
		${WRKSRC}/milter.c

do-install:
	@${INSTALL_PROGRAM} ${WRKSRC}/bogom ${PREFIX}/sbin
	@${INSTALL_MAN} ${WRKSRC}/bogom.8 ${MAN8PREFIX}/man/man8
	@${INSTALL_DATA} ${WRKSRC}/bogom.conf-example ${PREFIX}/etc
.if !defined(NOPORTDOCS)
	@${MKDIR} ${DOCSDIR}
.for f in ${PORTDOCS}
	@${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}
.endfor
.endif

post-install:
	@${CAT} ${PKGMESSAGE}

.include <bsd.port.mk>