aboutsummaryrefslogtreecommitdiffstats
path: root/net/ntlmaps/Makefile
blob: 826b296a319976605edfb2a9d65114c7417339a6 (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
# New ports collection makefile for:    ntlmaps
# Date created:             1 August 2007
# Whom:                 kevlo
#
# $FreeBSD$

PORTNAME=   ntlmaps
PORTVERSION=    0.9.9.0.1
PORTREVISION=   1
CATEGORIES= net
MASTER_SITES=   ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}

MAINTAINER= kevlo@FreeBSD.org
COMMENT=    A proxy that authenticates the user using the NTLM protocol

USE_PYTHON= yes

DOCS=       COPYING Install.txt changelog.txt readme.txt research.txt

post-patch:
    ${REINPLACE_CMD} -e \
        's,^#! /usr/bin/python,#!${PYTHON_CMD},' ${WRKSRC}/main.py
    @${RM} -rf ${WRKSRC}/main.py.bak

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

do-install:
.if !defined(NOPORTDOCS)
    @${MKDIR} ${DOCSDIR}
.for file in ${DOCS}
    ${INSTALL_DATA} ${WRKSRC}/${file} ${DOCSDIR}
.endfor
.endif
    @${MKDIR} ${PYTHON_SITELIBDIR}/${PORTNAME}
    @${MKDIR} ${PREFIX}/share/examples/ntlmaps
    ${INSTALL_DATA} ${WRKSRC}/*.py* ${PYTHON_SITELIBDIR}/${PORTNAME}
    ${INSTALL_DATA} ${WRKSRC}/lib/*.py* ${PYTHON_SITELIBDIR}/${PORTNAME}
    ${CHMOD} +x ${PYTHON_SITELIBDIR}/${PORTNAME}/main.py
    ${LN} -fs ${PYTHON_SITELIBDIR}/${PORTNAME}/main.py ${PREFIX}/bin/ntlmaps
    ${INSTALL_DATA} ${WRKSRC}/server.cfg ${PREFIX}/share/examples/ntlmaps

.include <bsd.port.mk>