2013-08-31 02:26:08 +02:00
|
|
|
# Created by: Corey Smith
|
2005-06-29 16:03:12 +02:00
|
|
|
# $FreeBSD$
|
|
|
|
|
|
|
|
PORTNAME= pynids
|
2010-12-23 02:17:49 +01:00
|
|
|
PORTVERSION= 0.6.1
|
2013-02-18 22:13:02 +01:00
|
|
|
PORTREVISION= 1
|
2005-06-29 16:03:12 +02:00
|
|
|
CATEGORIES= net python
|
2010-12-23 02:17:49 +01:00
|
|
|
MASTER_SITES= http://jon.oberheide.org/pynids/downloads/
|
2005-06-29 16:03:12 +02:00
|
|
|
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
|
|
|
|
DIST_SUBDIR= python
|
|
|
|
|
|
|
|
MAINTAINER= corsmith@gmail.com
|
|
|
|
COMMENT= Python interface to libnids
|
|
|
|
|
2010-12-23 02:17:49 +01:00
|
|
|
PATCH_DEPENDS= ${LIBNET_CONFIG}:${PORTSDIR}/net/libnet
|
2013-02-18 22:13:02 +01:00
|
|
|
LIB_DEPENDS= net:${PORTSDIR}/net/libnet
|
2005-06-29 16:03:12 +02:00
|
|
|
|
2013-08-31 02:26:08 +02:00
|
|
|
USES= pkgconfig
|
|
|
|
USE_GNOME= glib20
|
2005-06-29 16:03:12 +02:00
|
|
|
USE_PYTHON= yes
|
|
|
|
USE_PYDISTUTILS= yes
|
|
|
|
USE_PYTHON_PREFIX= yes
|
|
|
|
|
|
|
|
PLIST_FILES= %%PYTHON_SITELIBDIR%%/nidsmodule.so
|
|
|
|
|
2010-12-23 02:17:49 +01:00
|
|
|
LIBNET_CONFIG?= ${LOCALBASE}/bin/libnet11-config
|
2007-01-31 15:09:55 +01:00
|
|
|
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
|
|
|
|
.if exists(${LIBNET_CONFIG})
|
|
|
|
LIBNET_CFLAGS!= ${LIBNET_CONFIG} --cflags
|
|
|
|
LIBNET_LIBS!= ${LIBNET_CONFIG} --libs
|
|
|
|
.endif
|
|
|
|
|
|
|
|
post-extract:
|
2010-12-23 02:17:49 +01:00
|
|
|
@cd ${WRKSRC} && ${TAR} xzf libnids-1.24.tar.gz
|
2007-01-31 15:09:55 +01:00
|
|
|
|
2005-08-07 00:17:04 +02:00
|
|
|
post-patch:
|
2010-12-23 02:17:49 +01:00
|
|
|
@${CP} -f ${TEMPLATES}/config.guess ${WRKSRC}
|
|
|
|
@${CHMOD} a+rx ${WRKSRC}/config.guess
|
|
|
|
@${CP} -f ${TEMPLATES}/config.sub ${WRKSRC}
|
|
|
|
@${CHMOD} a+rx ${WRKSRC}/config.sub
|
2007-01-31 15:09:55 +01:00
|
|
|
@${REINPLACE_CMD} -e \
|
2010-12-23 02:17:49 +01:00
|
|
|
"s|/usr/local/include|${PREFIX}/include', '${LIBNET_CFLAGS:S/-I//}|; \
|
|
|
|
s|/usr/local/lib|${PREFIX}/lib', '${LIBNET_LIBS:N-l*:S/-L//}|" \
|
2007-01-31 15:09:55 +01:00
|
|
|
${WRKSRC}/setup.py
|
|
|
|
@${REINPLACE_CMD} -Ee \
|
|
|
|
's|(LNET_CFLAGS=).*|\1"`${LIBNET_CONFIG} --defines` ${LIBNET_CFLAGS}"|; \
|
2010-12-23 02:17:49 +01:00
|
|
|
s|(LNETLIB=).*|\1"${LIBNET_LIBS} -L${LOCALBASE}/lib"|; \
|
2007-01-31 15:09:55 +01:00
|
|
|
s|gcc|${CC}|' \
|
2010-12-23 02:17:49 +01:00
|
|
|
${WRKSRC}/libnids-1.24/configure
|
2007-01-31 15:09:55 +01:00
|
|
|
|
|
|
|
.include <bsd.port.post.mk>
|