[netperf-talk] netperf compiling for arm linux

Holger Steudtner steudtne at cs.uni-bonn.de
Thu Jun 22 00:44:41 PDT 2006


Hello,


Rick Jones schrieb:

>> #>./configure CC=arm-linux-gcc
>> LDFLAGS=-L/usr/local/arm/3.4.1/arm-linux/lib --host arm --build
>> i686-pc-linux-gnu
> 
> Ah, cross compilation.  Always a joy... and something for which I have
> no opportunity to test myself :(
> 
>> for netperf-2.4.1 & 2.4.2:
>>
>> It stops within the configure process with the error
>>
>> #> checking for sys/select.h... yes
>> checking for sys/socket.h... (cached) yes
>> checking types of arguments for select... int,fd_set *,struct timeval *
>> checking whether setpgrp takes no argument... configure: error: cannot
>> check setpgrp when cross compiling
> 
> As a "workaround" you might try editing the configure script to
> comment-out the checks for setpgrp.  Apart from that I am at a loss and
> will have to rely on the others on the list.  I'm guessing the check for
> the argument relies on actually running a setpgrp() call, which I
> suppose one cannot really do when cross compiling.

This was a good hint and worked. I commented-out the following lines
(5930-5992) in netperf-2.4.2 configure script:

#echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5
#echo $ECHO_N "checking whether setpgrp takes no argument... $ECHO_C" >&6
#if test "${ac_cv_func_setpgrp_void+set}" = set; then
#  echo $ECHO_N "(cached) $ECHO_C" >&6
#else
#  if test "$cross_compiling" = yes; then
#  { { echo "$as_me:$LINENO: error: cannot check setpgrp when cross
compiling" >&5
#echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;}
#   { (exit 1); exit 1; }; }
#else
#  cat >conftest.$ac_ext <<_ACEOF
#/* confdefs.h.  */
#_ACEOF
#cat confdefs.h >>conftest.$ac_ext
#cat >>conftest.$ac_ext <<_ACEOF
#/* end confdefs.h.  */
##if HAVE_UNISTD_H
## include <unistd.h>
##endif
#
#int
#main ()
#{
#/* If this system has a BSD-style setpgrp which takes arguments,
#  setpgrp(1, 1) will fail with ESRCH and return -1, in that case
#  exit successfully. */
#  exit (setpgrp (1,1) == -1 ? 0 : 1);
#  ;
#  return 0;
#}
#_ACEOF
#rm -f conftest$ac_exeext
#if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
#  (eval $ac_link) 2>&5
#  ac_status=$?
#  echo "$as_me:$LINENO: \$? = $ac_status" >&5
#  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
#  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
#  (eval $ac_try) 2>&5
#  ac_status=$?
#  echo "$as_me:$LINENO: \$? = $ac_status" >&5
#  (exit $ac_status); }; }; then
#  ac_cv_func_setpgrp_void=no
#else
#  echo "$as_me: program exited with status $ac_status" >&5
#echo "$as_me: failed program was:" >&5
#sed 's/^/| /' conftest.$ac_ext >&5
#
#( exit $ac_status )
#ac_cv_func_setpgrp_void=yes
#fi
#rm -f core *.core gmon.out bb.out conftest$ac_exeext
conftest.$ac_objext conftest.$ac_ext
#fi
#fi
#echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5
#echo "${ECHO_T}$ac_cv_func_setpgrp_void" >&6
#if test $ac_cv_func_setpgrp_void = yes; then
#
#cat >>confdefs.h <<\_ACEOF
##define SETPGRP_VOID 1
#_ACEOF
#
#fi


Holger


More information about the netperf-talk mailing list