diff options
author | Matteo Bernardini <ponce@slackbuilds.org> | 2017-06-03 19:57:54 +0200 |
---|---|---|
committer | Robby Workman <rworkman@slackbuilds.org> | 2021-04-17 23:31:01 -0500 |
commit | 08f5bb5962a9e5de1b2d0b3a0653d559a88b5e4f (patch) | |
tree | 0cd1f8bff7bba70d364bbd00df12d8e2ca3c0901 /network/iperf | |
parent | affc987b149c3be5e8eb58589e6e17b511f523eb (diff) | |
download | slackbuilds-08f5bb5962a9e5de1b2d0b3a0653d559a88b5e4f.tar.gz |
network/iperf: Updated for version 2.0.8.
Signed-off-by: Matteo Bernardini <ponce@slackbuilds.org>
Diffstat (limited to 'network/iperf')
-rw-r--r-- | network/iperf/iperf.SlackBuild | 29 | ||||
-rw-r--r-- | network/iperf/iperf.info | 6 | ||||
-rw-r--r-- | network/iperf/patches/0_iperf-2.0.8-debuginfo.patch | 17 | ||||
-rw-r--r-- | network/iperf/patches/1_iperf-2.0.8-bindfail.patch | 42 | ||||
-rw-r--r-- | network/iperf/patches/2_iperf-2.0.8-math.patch | 75 |
5 files changed, 153 insertions, 16 deletions
diff --git a/network/iperf/iperf.SlackBuild b/network/iperf/iperf.SlackBuild index f8c40ab1e8..d4c970ca8b 100644 --- a/network/iperf/iperf.SlackBuild +++ b/network/iperf/iperf.SlackBuild @@ -8,13 +8,13 @@ # http://www.slackwiki.org/Writing_A_SlackBuild_Script PRGNAM=iperf -VERSION=${VERSION:-2.0.5} +VERSION=${VERSION:-2.0.8} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac @@ -25,8 +25,8 @@ TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" @@ -49,10 +49,15 @@ tar xvf $CWD/$PRGNAM-$VERSION.tar.gz cd $PRGNAM-$VERSION chown -R root:root . find -L . \ - \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \ - -exec chmod 755 {} \; -o \ - \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ - -exec chmod 644 {} \; + \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ + -o -perm 511 \) -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ + -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; + +# Thanks fedora for these +for i in $CWD/patches/* ; do patch -p1 < $i ; done + +autoreconf -fi CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ @@ -68,13 +73,11 @@ CXXFLAGS="$SLKCFLAGS" \ make make install DESTDIR=$PKG -find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ +find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true -( cd $PKG/usr/man - find . -type f -exec gzip -9 {} \; - for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done -) +find $PKG/usr/man -type f -exec gzip -9 {} \; +for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp -a AUTHORS ChangeLog COPYING INSTALL README doc/index.html $PKG/usr/doc/$PRGNAM-$VERSION diff --git a/network/iperf/iperf.info b/network/iperf/iperf.info index fbb6e24fa4..730b096a3b 100644 --- a/network/iperf/iperf.info +++ b/network/iperf/iperf.info @@ -1,8 +1,8 @@ PRGNAM="iperf" -VERSION="2.0.5" +VERSION="2.0.8" HOMEPAGE="https://sourceforge.net/projects/iperf/" -DOWNLOAD="https://downloads.sourceforge.net/iperf/iperf-2.0.5.tar.gz" -MD5SUM="44b5536b67719f4250faed632a3cd016" +DOWNLOAD="https://downloads.sourceforge.net/iperf2/iperf-2.0.8.tar.gz" +MD5SUM="e5887f799d8dc64a974c6c2f2e5cc339" DOWNLOAD_x86_64="" MD5SUM_x86_64="" REQUIRES="" diff --git a/network/iperf/patches/0_iperf-2.0.8-debuginfo.patch b/network/iperf/patches/0_iperf-2.0.8-debuginfo.patch new file mode 100644 index 0000000000..2a3ad246ee --- /dev/null +++ b/network/iperf/patches/0_iperf-2.0.8-debuginfo.patch @@ -0,0 +1,17 @@ +diff -NarpU5 iperf-2.0.8/configure.ac iperf-2.0.8.debuginfo/configure.ac +--- iperf-2.0.8/configure.ac 2015-04-02 16:51:48.000000000 -0400 ++++ iperf-2.0.8.debuginfo/configure.ac 2015-04-10 10:11:33.287445003 -0400 +@@ -42,13 +42,11 @@ AC_ARG_ENABLE(kalman, AC_HELP_STRING([-- + dnl =================================================================== + dnl Checks for programs + dnl =================================================================== + + AC_PROG_CXX +-CXXFLAGS=`echo " $CXXFLAGS " | sed -e "s/ -g / /"` # do not want it implicitly + AC_PROG_CC +-CFLAGS=`echo " $CFLAGS " | sed -e "s/ -g / /"` # do not want it implicitly + AC_ISC_POSIX + AC_PROG_INSTALL + AC_PROG_MAKE_SET + AC_PROG_RANLIB + AC_LANG(C) diff --git a/network/iperf/patches/1_iperf-2.0.8-bindfail.patch b/network/iperf/patches/1_iperf-2.0.8-bindfail.patch new file mode 100644 index 0000000000..b18b2cffed --- /dev/null +++ b/network/iperf/patches/1_iperf-2.0.8-bindfail.patch @@ -0,0 +1,42 @@ +diff -NarpU5 iperf-2.0.8/src/Client.cpp iperf-2.0.8.bindfail/src/Client.cpp +--- iperf-2.0.8/src/Client.cpp 2015-04-02 16:51:48.000000000 -0400 ++++ iperf-2.0.8.bindfail/src/Client.cpp 2015-04-10 10:05:38.279936555 -0400 +@@ -701,20 +701,20 @@ void Client::Connect( ) { + AF_INET + #endif + : AF_INET); + + mSettings->mSock = socket( domain, type, 0 ); +- WARN_errno( mSettings->mSock == INVALID_SOCKET, "socket" ); ++ FAIL_errno( mSettings->mSock == INVALID_SOCKET, "socket", mSettings ); + + SetSocketOptions( mSettings ); + + SockAddr_localAddr( mSettings ); + if ( mSettings->mLocalhost != NULL ) { + // bind socket to local address + rc = bind( mSettings->mSock, (sockaddr*) &mSettings->local, + SockAddr_get_sizeof_sockaddr( &mSettings->local ) ); +- WARN_errno( rc == SOCKET_ERROR, "bind" ); ++ FAIL_errno( rc == SOCKET_ERROR, "bind", mSettings ); + } + // connect socket + rc = connect( mSettings->mSock, (sockaddr*) &mSettings->peer, + SockAddr_get_sizeof_sockaddr( &mSettings->peer )); + FAIL_errno( rc == SOCKET_ERROR, "connect", mSettings ); +diff -NarpU5 iperf-2.0.8/src/Listener.cpp iperf-2.0.8.bindfail/src/Listener.cpp +--- iperf-2.0.8/src/Listener.cpp 2015-04-02 16:51:48.000000000 -0400 ++++ iperf-2.0.8.bindfail/src/Listener.cpp 2015-04-10 10:06:23.279699885 -0400 +@@ -342,11 +342,11 @@ void Listener::Listen( ) { + WARN_errno( rc == SOCKET_ERROR, "WSAJoinLeaf (aka bind)" ); + } else + #endif + { + rc = bind( mSettings->mSock, (sockaddr*) &mSettings->local, mSettings->size_local ); +- WARN_errno( rc == SOCKET_ERROR, "bind" ); ++ FAIL_errno( rc == SOCKET_ERROR, "bind", mSettings ); + } + // listen for connections (TCP only). + // default backlog traditionally 5 + if ( !isUDP( mSettings ) ) { + rc = listen( mSettings->mSock, 5 ); diff --git a/network/iperf/patches/2_iperf-2.0.8-math.patch b/network/iperf/patches/2_iperf-2.0.8-math.patch new file mode 100644 index 0000000000..1a943f5f2c --- /dev/null +++ b/network/iperf/patches/2_iperf-2.0.8-math.patch @@ -0,0 +1,75 @@ +diff -NarU5 a/include/headers.h b/include/headers.h +--- a/include/headers.h 2015-04-02 16:51:48.000000000 -0400 ++++ b/include/headers.h 2016-03-16 14:52:14.386853750 -0400 +@@ -80,11 +80,10 @@ + #include <assert.h> + #include <ctype.h> + #include <errno.h> + #include <string.h> + #include <time.h> +-#include <math.h> + #include <float.h> + #include <sys/types.h> + + #ifdef WIN32 + +diff -NarU5 a/src/Client.cpp b/src/Client.cpp +--- a/src/Client.cpp 2015-04-02 16:51:48.000000000 -0400 ++++ b/src/Client.cpp 2016-03-16 14:52:14.387853701 -0400 +@@ -50,10 +50,11 @@ + * A client thread initiates a connect to the server and handles + * sending and receiving data, then closes the socket. + * ------------------------------------------------------------------- */ + + #include <time.h> ++#include <cmath> + #include "headers.h" + #include "Client.hpp" + #include "Thread.h" + #include "SocketAddr.h" + #include "PerfSocket.hpp" +diff -NarU5 a/src/ReportDefault.c b/src/ReportDefault.c +--- a/src/ReportDefault.c 2015-04-02 16:51:49.000000000 -0400 ++++ b/src/ReportDefault.c 2016-03-16 14:52:14.387853701 -0400 +@@ -47,10 +47,11 @@ + * ReportDefault.c + * by Kevin Gibbs <kgibbs@nlanr.net> + * + * ________________________________________________________________ */ + ++#include <math.h> + #include "headers.h" + #include "Settings.hpp" + #include "util.h" + #include "Reporter.h" + #include "report_default.h" +diff -NarU5 a/src/Reporter.c b/src/Reporter.c +--- a/src/Reporter.c 2015-04-02 16:51:49.000000000 -0400 ++++ b/src/Reporter.c 2016-03-16 14:52:14.388853652 -0400 +@@ -47,10 +47,11 @@ + * Reporter.c + * by Kevin Gibbs <kgibbs@nlanr.net> + * + * ________________________________________________________________ */ + ++#include <math.h> + #include "headers.h" + #include "Settings.hpp" + #include "util.h" + #include "Reporter.h" + #include "Thread.h" +diff -NarU5 a/src/Server.cpp b/src/Server.cpp +--- a/src/Server.cpp 2015-04-02 16:51:49.000000000 -0400 ++++ b/src/Server.cpp 2016-03-16 14:52:14.388853652 -0400 +@@ -52,10 +52,11 @@ + * Handles sending and receiving data, and then closes socket. + * Changes to this version : The server can be run as a daemon + * ------------------------------------------------------------------- */ + + #define HEADERS() ++#include <cmath> + #include "headers.h" + #include "Server.hpp" + #include "List.h" + #include "Extractor.h" + #include "Reporter.h" |