# Created by: Pete Fritchman <petef@databits.net>
# $FreeBSD: benchmarks/iperf/Makefile 334835 2013-11-25 11:33:41Z sunpoet $

PORTNAME=	iperf
PORTVERSION=	2.0.5
CATEGORIES=	benchmarks
MASTER_SITES=	SF/${PORTNAME}

MAINTAINER=	sunpoet@FreeBSD.org
COMMENT=	Tool to measure maximum TCP and UDP bandwidth

LICENSE=	BSD

OPTIONS_DEFINE=	DOCS IPV6 THREADS
OPTIONS_DEFAULT=THREADS

GNU_CONFIGURE=	yes

PLIST_FILES=	bin/iperf \
		man/man1/iperf.1.gz
PORTDOCS=	*

IPV6_CATEGORIES=	ipv6
IPV6_CONFIGURE_ENABLE=	ipv6
THREADS_CONFIGURE_ENABLE=	threads
THREADS_LDFLAGS=	-pthread

.include <bsd.port.options.mk>

post-install:
.if ${PORT_OPTIONS:MDOCS}
	${MKDIR} ${STAGEDIR}${DOCSDIR}/
	cd ${WRKSRC}/ && ${INSTALL_DATA} README doc/*.gif doc/*.html ${STAGEDIR}${DOCSDIR}/
.endif

.include <bsd.port.mk>
