aboutsummaryrefslogtreecommitdiffstats
path: root/security/arm/Makefile
blob: 93b7480bb9cc1de5972bfca1c8e31100bc9c96d5 (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
# Created by: Carlo Strub
# $FreeBSD$

PORTNAME=   arm
DISTVERSION=    1.4.5.0
CATEGORIES= security net python
MASTER_SITES=   https://archive.torproject.org/arm/ \
        http://www.c-s.li/ports/
PKGNAMEPREFIX=  ${PYTHON_PKGNAMEPREFIX}

MAINTAINER= cs@FreeBSD.org
COMMENT=    Terminal status monitor for Tor

LICENSE=    GPLv3

MAN1=       arm.1
MANCOMPRESSED=  yes

USE_PYTHON= yes
USE_PYDISTUTILS=yes
USE_BZIP2=  yes
WRKSRC=     ${WRKDIR}/${PORTNAME}

DOCSDIR=    ${PREFIX}/share/doc/${PORTNAME}
PORTDOCS=   armrc.sample

OPTIONS_DEFINE= TOR \
        DOCS

OPTIONS_DEFAULT=TOR DOCS

TOR_DESC=   Enable local tor support

NO_STAGE=   yes
.include <bsd.port.options.mk>

.if ${PORT_OPTIONS:MTOR}
RUN_DEPENDS+=   lsof:${PORTSDIR}/sysutils/lsof \
        tor:${PORTSDIR}/security/tor
.endif

.include <bsd.port.pre.mk>

post-patch:
.if ${PORT_OPTIONS:MDOCS}
    @${REINPLACE_CMD} -e 's,/usr/share/doc,${PREFIX}/share/doc,g' \
        ${WRKSRC}/setup.py
.else
    @${REINPLACE_CMD} -e 's,/usr/share/doc/,${WRKSRC}/src,g' \
        ${WRKSRC}/setup.py
.endif

    @${REINPLACE_CMD} -e 's,/usr/bin,${PREFIX}/bin,g' \
        ${WRKSRC}/arm ${WRKSRC}/setup.py ${WRKSRC}/src/uninstall
    @${REINPLACE_CMD} -e 's,/usr/share/man/man1,${PREFIX}/man/man1,g' \
        ${WRKSRC}/setup.py
    @${REINPLACE_CMD} -e 's,/usr/share,${PYTHON_SITELIBDIR},g' \
        ${WRKSRC}/arm ${WRKSRC}/setup.py ${WRKSRC}/src/uninstall \
        ${WRKSRC}/src/gui/controller.py

.include <bsd.port.post.mk>