aboutsummaryrefslogtreecommitdiffstats
path: root/benchmarks/iperf
diff options
context:
space:
mode:
authormnag <mnag@FreeBSD.org>2006-04-24 22:30:00 +0800
committermnag <mnag@FreeBSD.org>2006-04-24 22:30:00 +0800
commitdd1b3266e8ba9a5652d00137214155bdf452b3e2 (patch)
tree68f0e140086923f6d126443e27049ccd0acd07de /benchmarks/iperf
parent2a6d94f3d608c62fe46369d1e491feb8233eb769 (diff)
downloadfreebsd-ports-gnome-dd1b3266e8ba9a5652d00137214155bdf452b3e2.tar.gz
freebsd-ports-gnome-dd1b3266e8ba9a5652d00137214155bdf452b3e2.tar.zst
freebsd-ports-gnome-dd1b3266e8ba9a5652d00137214155bdf452b3e2.zip
- Fix build when detect pthread_cancel (7.x)
- Fix configure detection of pthread_cancel on 4.x 5.x and 6.x - portlint(1) Notified by: kris
Diffstat (limited to 'benchmarks/iperf')
-rw-r--r--benchmarks/iperf/Makefile17
-rw-r--r--benchmarks/iperf/files/patch-compat__Thread.c11
2 files changed, 18 insertions, 10 deletions
diff --git a/benchmarks/iperf/Makefile b/benchmarks/iperf/Makefile
index 906ea52391b0..cf4ce326358d 100644
--- a/benchmarks/iperf/Makefile
+++ b/benchmarks/iperf/Makefile
@@ -15,37 +15,34 @@ MASTER_SITE_SUBDIR= ${PORTNAME}
MAINTAINER= mnag@FreeBSD.org
COMMENT= A tool to measure maximum TCP and UDP bandwidth
-NO_CDROM= "can't charge a fee for the software"
+NO_CDROM= can't charge a fee for the software
-HAS_CONFIGURE= yes
+GNU_CONFIGURE= yes
PLIST_FILES= bin/iperf
+PORTDOCS= *
OPTIONS= IPV6 "Enable support to IPv6" on \
THREADS "Enable threads support" on
.include <bsd.port.pre.mk>
-CONFIGURE_ARGS+= --prefix=${PREFIX}
-
.if defined(WITHOUT_IPV6)
CONFIGURE_ARGS+= --disable-ipv6
.endif
.if defined(WITHOUT_THREADS)
CONFIGURE_ARGS+= --disable-threads
-.endif
-
-.if !defined(NOPORTDOCS)
-PORTDOCS= *
+.else
+CONFIGURE_ENV+= CFLAGS=${PTHREAD_LIBS}
.endif
post-install:
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
-.for FILE in ${WRKSRC}/doc/*.html ${WRKSRC}/doc/*.gif
- @${INSTALL_DATA} ${WRKSRC}/${FILE} ${DOCSDIR}
+.for f in ${WRKSRC}/doc/*.html ${WRKSRC}/doc/*.gif
+ ${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}
.endfor
.endif
diff --git a/benchmarks/iperf/files/patch-compat__Thread.c b/benchmarks/iperf/files/patch-compat__Thread.c
new file mode 100644
index 000000000000..ecec1058f83e
--- /dev/null
+++ b/benchmarks/iperf/files/patch-compat__Thread.c
@@ -0,0 +1,11 @@
+--- ./compat/Thread.c.orig Mon Apr 24 11:02:47 2006
++++ ./compat/Thread.c Mon Apr 24 11:03:46 2006
+@@ -202,7 +202,7 @@
+ #if defined( HAVE_POSIX_THREAD )
+ // Cray J90 doesn't have pthread_cancel; Iperf works okay without
+ #ifdef HAVE_PTHREAD_CANCEL
+- pthread_cancel( oldTID );
++ pthread_cancel( thread->mTID );
+ #endif
+ #else // Win32
+ // this is a somewhat dangerous function; it's not