KeyWords:
SysAdmin,
Solaris,
Iperf
Compiling Iperf on Solaris 10
Compiling
Iperf on Solaris 10 turned out to be more difficult than
foreseen; there are a few bugs in the configure scripts that must be corrected.
(Thanks to
0) Have the
g++
compiler ready:
# install the gcc/g++ compiler (will install dependent binutils)
pkg-get -i gcc4core gcc4g++ binutils
# make sure it's all in the PATH
PATH=$PATH:/opt/csw/gcc4/bin:/opt/csw/i386-pc-solaris2.8/bin
1) Run the
./configure
script, poiting it to the correct c++ compiler:
/tmp/iperf-2.0.4# ./configure CXX=/opt/csw/gcc4/bin/g++
2) Now patch the generated =Makefile='s, to
use "-lpthread -lrt" instead of "-pthread":
/tmp/iperf-2.0.4# find . -name Makefile | (while read file; do gsed -i -e 's/-lpthread/-lpthread -lrt/g;' $file; done)
3) Now
make
it and test it:
/tmp/iperf-2.0.4# make
...
/tmp/iperf-2.0.4# ./src/iperf -h
Usage: iperf [-s|-c host] [options]
iperf [-h|--help] [-v|--version]
...
Readers' comments