summaryrefslogtreecommitdiffstats
path: root/net-p2p/nicotine-plus/Makefile
blob: 56205e8f8d16a07788211ee4e9576e10af55f518 (plain)
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
# New ports collection makefile for:	nicotine
# Date created:				19 Aug 2003
# Whom:					Adam Weinberger <adamw@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=	plus
PORTVERSION=	1.2.16
CATEGORIES=	net-p2p
MASTER_SITES=	SF/nicotine-${PORTNAME}/nicotine-${PORTNAME}/${PORTVERSION}
PKGNAMEPREFIX=	nicotine-
DISTNAME=	${PKGNAMEPREFIX:S/-/+/}-${PORTVERSION}

MAINTAINER=	acm@FreeBSD.org
COMMENT=	A fork of nicotine soulseek client

RUN_DEPENDS=	${PYTHON_SITELIBDIR}/_bsddb.so:${PORTSDIR}/databases/py-bsddb

CONFLICTS=	nicotine-[0-9]*

USE_BZIP2=		yes
USE_GNOME=		pygtk2
USE_PYTHON=		yes
USE_PYDISTUTILS=	yes
USE_GETTEXT=		yes
PYDISTUTILS_PKGNAME=	nicotine

DOCSDIR=	share/doc/${PKGNAMEPREFIX:S/-//}
DATADIR=	share/${PKGNAMEPREFIX:S/-//}
MAN1=		nicotine-import-winconfig.1 nicotine.1

OPTIONS=	GEOIP "Enable the GeoIP based country code blocker" on \
		PSYCO "Enable Psyco, the optimizing Python compiler" on \
		MUTAGEN "Enable Mutagen for audio metadata support" on \
		LIBSEXY	"Enable libsexy support"	on \
		MINIUPNPC "Enable upnp support"	on

.include <bsd.port.pre.mk>

.if defined(WITH_GEOIP)
RUN_DEPENDS+=	${PYTHON_SITELIBDIR}/GeoIP.so:${PORTSDIR}/net/py-GeoIP
.endif
.if defined(WITH_PSYCO) && ${ARCH} == "i386"
RUN_DEPENDS+=	${PYTHON_SITELIBDIR}/psyco/_psyco.so:${PORTSDIR}/devel/py-psyco
.endif
.if defined(WITH_MUTAGEN)
RUN_DEPENDS+=	${PYTHON_SITELIBDIR}/mutagen/__init__.py:${PORTSDIR}/audio/py-mutagen
.endif
.if defined(WITH_LIBSEXY)
RUN_DEPENDS+=	${PYTHON_SITELIBDIR}/gtk-2.0/sexy.so:${PORTSDIR}/x11-toolkits/py-sexy
.endif
.if defined(WITH_MINIUPNPC)
RUN_DEPENDS+=	${PYTHON_SITELIBDIR}/miniupnpc.so:${PORTSDIR}/net/py-miniupnpc
.endif

post-extract:
	@${MV} ${WRKSRC}/${PKGNAMEPREFIX:S/-//}.py ${WRKSRC}/${PKGNAMEPREFIX:S/-//}

post-patch:
.if defined(NOPORTDOCS)
	@${REINPLACE_CMD} -i "" -e 's|^doc_files.*|doc_files = ""|g' ${WRKSRC}/setup.py
.endif
	@${REINPLACE_CMD} -e \
		"s|sys\.prefix|\"${PREFIX}\"|g" -e \
			"s|nicotine.py|nicotine|g" ${WRKSRC}/setup.py

.include <bsd.port.post.mk>
OpenPOWER on IntegriCloud