aboutsummaryrefslogtreecommitdiffstats
path: root/security/gcipher/Makefile
blob: 37be716699cab33297cbf0852ee25f0f172cc31f (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
# New ports collection makefile for:    gcipher
# Date created:     25 June 2003
# Whom:         Shannon -jj Behrens <jjinux@yahoo.com>
#
# $FreeBSD$
#

PORTNAME=   gcipher
PORTVERSION=    1.1
PORTREVISION=   1
CATEGORIES= security gnome
MASTER_SITES=   SF

MAINTAINER= ports@FreeBSD.org
COMMENT=    A simple encryption tool

LICENSE=    BSD

USE_GNOME=  pygnome2
USE_PYTHON= yes

MAN1=       gcipher.1
LICENSE_FILES=  ${WRKSRC}/LICENSE

post-patch:
    @${REINPLACE_CMD} -e \
        '/^VERSION/s|=.*|= "${PORTVERSION}"|g ; \
         /^GLADEDIR/s|=.*|= "${DATADIR}/lib"|g' ${WRKSRC}/src/Const.py
    @${REINPLACE_CMD} -e \
        's|/usr/bin/python|${SETENV} python|g ; \
         s|^# sys.path.append|sys.path.append|g ; \
         s|/usr/share/gcipher/lib|${DATADIR}/lib|' ${WRKSRC}/src/gcipher

do-build:
    @${PYTHON_CMD} ${PYTHON_LIBDIR}/compileall.py ${WRKSRC}/src
    @${PYTHON_CMD} -O ${PYTHON_LIBDIR}/compileall.py ${WRKSRC}/src

do-install:
    ${INSTALL_SCRIPT} ${WRKSRC}/src/gcipher ${PREFIX}/bin
    ${INSTALL_MAN} ${WRKSRC}/gcipher.1 ${MANPREFIX}/man/man1
    ${INSTALL_DATA} ${WRKSRC}/src/gcipher.desktop ${PREFIX}/share/applications
    @${MKDIR} ${DATADIR}/lib
    @(cd ${WRKSRC}/src && \
        ${FIND} . -name '*.glade' \
            -o -name '*.gladep' \
            -o -name '*.py' \
            -o -name '*.pyc' \
            -o -name '*.pyo' | \
        ${CPIO} -pdm -R ${SHAREOWN}:${SHAREGRP} ${DATADIR}/lib)
    @${MKDIR} ${DATADIR}/plugins
    @(cd ${WRKSRC}/plugins && \
        ${FIND} . -name '*.glade' \
            -o -name '*.gladep' \
            -o -name '*.py' | \
        ${CPIO} -pdm -R ${SHAREOWN}:${SHAREGRP} ${DATADIR}/plugins)
    @${FIND} ${DATADIR} -type d | ${XARGS} ${CHMOD} a+rx
    @${FIND} ${DATADIR} -type f | ${XARGS} ${CHMOD} ${SHAREMODE}
.if !defined(NOPORTDOCS)
    @${MKDIR} ${DOCSDIR}
    @(cd ${WRKSRC} && \
        ${INSTALL_DATA} CONTRIB README ${DOCSDIR})
.endif

.include <bsd.port.mk>