aboutsummaryrefslogtreecommitdiffstats
path: root/www/web2ldap/Makefile
blob: 4a7cf75a1421d5bd426fd2fd0f21011c504e3706 (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
# New ports collection makefile for:   web2ldap
# Date created:        21 July 2000
# Whom:                Oddbjorn Steffensen <oddbjorn@tricknology.org>
#
# $FreeBSD$
#

PORTNAME=   web2ldap
PORTVERSION=    0.16.4
CATEGORIES= www
MASTER_SITES=   http://www.web2ldap.de/download/ \
        ftp://ftp.ipt.ru/pub/download/

MAINTAINER= bsam@ipt.ru
COMMENT=    Python-based WWW gateway to LDAP servers

RUN_DEPENDS=    ${PYTHON_SITELIBDIR}/_ldap.so:${PORTSDIR}/net/py-ldap2 \
        ${PYTHON_SITELIBDIR}/pyweblib/__init__.py:${PORTSDIR}/www/pyweblib \
        ${LOCALBASE}/etc/mime.types:${PORTSDIR}/misc/mime-support

USE_PYTHON= yes
USE_REINPLACE=  yes

SUB_FILES=  pkg-message

post-patch:
    @${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
        ${WRKSRC}/etc/web2ldap/web2ldapcnf/standalone.py
    @${FIND} ${WRKSRC} -name '*.orig'  -o -name '*.bak' | ${XARGS} ${RM}

do-build:
    @(cd ${WRKSRC} && ${PYTHON_CMD} ./sbin/compile.py)

do-install:
    @${ECHO_CMD} "==> Installing program files..."
    @${MKDIR} ${DATADIR}
    @(cd ${WRKSRC}; \
        ${FIND} * -type f | ${GREP} -vE "^htdocs" | ${CPIO} -pd ${DATADIR})

post-install:
.if !defined(NOPORTDOCS)
    @${ECHO_CMD} "==> Installing document files..."
    @(cd ${WRKSRC}; \
        ${FIND} * -type f | ${GREP} "^htdocs" | ${CPIO} -pd ${DOCSDIR})
.endif
    @${SETENV} "PKG_PREFIX=${PREFIX}" ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
    @${CAT} ${PKGMESSAGE}

.include <bsd.port.mk>