aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mixmaster/Makefile
blob: 6c5be08106a6c2214b8cfd598e20cd8c2a707cef (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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# Created by: Meyer Wolfsheim
# $FreeBSD$
#

PORTNAME=   mixmaster
PORTVERSION=    3.0.2d
PORTREVISION=   1
CATEGORIES= mail security
MASTER_SITES=   http://www.c-s.li/ports/
DISTFILES=  ${DISTNAME}${EXTRACT_SUFX} \
        mixmaster-update.pl.gz allpingers.txt.gz
EXTRACT_ONLY=   ${DISTNAME}${EXTRACT_SUFX}

MAINTAINER= cs@FreeBSD.org
COMMENT=    Cryptographically secure anonymous remailer

LIB_DEPENDS=    libpcre.so:${PORTSDIR}/devel/pcre

USES=       perl5 ncurses

BUILD_WRKSRC=   ${WRKSRC}/Mix/Src

PORTDOCS=   README HISTORY THANKS TODO
CONFIG_FILES=   abuse.txt.in dest.blk mix.cfg news.hlp pubring.mix type1.hlp \
        adminkey.txt end.hlp mix.cfg.ex pgp.hlp rab.blk usage.txt.in \
        blocked.txt.in header.blk mix.hlp pgponly.hlp reply.txt.in \
        dest.alw intro.hlp mlist.txt pubring.asc rlist.txt \
        allpingers.txt

OPTIONS_DEFINE= DOCS
OPTIONS_DEFAULT=DOCS

.include <bsd.port.options.mk>

.include <bsd.port.pre.mk>

.if ${OSVERSION} < 1000000
BROKEN=     Does not compile
.endif

post-patch:
    @${RM} ${WRKSRC}/Mix/conf/mix.cfg.orig
    @${REINPLACE_CMD} -e 's|%%ETCDIR%%|${ETCDIR}|' ${WRKSRC}/Mix/Src/config.h \
        ${WRKSRC}/Mix/Src/Makefile.in
    ${CP} ${WRKSRC}/Mix/Src/Makefile.in ${WRKSRC}/Mix/Src/Makefile

pre-install:
    ${GZCAT} ${DISTDIR}/mixmaster-update.pl.gz >${WRKDIR}/mixmaster-update.pl
    ${GZCAT} ${DISTDIR}/allpingers.txt.gz >${WRKSRC}/Mix/conf/allpingers.txt
    ${REINPLACE_CMD} -e "s|/etc/mixmaster|${ETCDIR}|g" ${WRKDIR}/mixmaster-update.pl
    ${REINPLACE_CMD} -e "s|/usr/bin|${PREFIX}/bin|g" ${WRKDIR}/mixmaster-update.pl
    ${MKDIR} ${ETCDIR}

do-install:
    ${INSTALL_PROGRAM} ${WRKSRC}/Mix/Src/mixmaster ${STAGEDIR}${PREFIX}/bin/mixmaster
    ${INSTALL_PROGRAM} ${WRKSRC}/Mix/Src/mpgp ${STAGEDIR}${PREFIX}/bin/mpgp
    ${INSTALL_PROGRAM} ${WRKSRC}/Mix/Src/remailer ${STAGEDIR}${PREFIX}/bin/remailer
    ${INSTALL_SCRIPT} ${WRKDIR}/mixmaster-update.pl ${STAGEDIR}${PREFIX}/bin/mixmaster-update
    ${INSTALL_MAN} ${WRKSRC}/Mix/mixmaster.1 ${STAGEDIR}${PREFIX}/man/man1/mixmaster.1
    ${INSTALL_MAN} ${WRKSRC}/Mix/mpgp.1 ${STAGEDIR}${PREFIX}/man/man1/mpgp.1
.if ${PORT_OPTIONS:MDOCS}
    @${MKDIR} ${STAGEDIR}${DOCSDIR}
    @${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/Mix/,} ${STAGEDIR}${DOCSDIR}/
.endif
.for FILE in ${CONFIG_FILES}
    @${MKDIR} ${STAGEDIR}${ETCDIR}
    @${INSTALL_DATA} ${WRKSRC}/Mix/conf/${FILE} ${STAGEDIR}${ETCDIR}/${FILE}.sample
.endfor

.include <bsd.port.post.mk>