summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac263
1 files changed, 174 insertions, 89 deletions
diff --git a/configure.ac b/configure.ac
index 0a554af..e6a40d3 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,10 +1,11 @@
1dnl Process this file with autoconf to produce a configure script. 1dnl Process this file with autoconf to produce a configure script.
2AC_PREREQ(2.59) 2AC_PREREQ(2.64)
3AC_INIT(monitoring-plugins,2.1.2) 3AC_INIT(monitoring-plugins,2.3git)
4AC_CONFIG_SRCDIR(NPTest.pm) 4AC_CONFIG_SRCDIR(NPTest.pm)
5AC_CONFIG_FILES([gl/Makefile]) 5AC_CONFIG_FILES([gl/Makefile])
6AC_CONFIG_AUX_DIR(build-aux) 6AC_CONFIG_AUX_DIR(build-aux)
7AM_INIT_AUTOMAKE([1.8.3]) 7AM_INIT_AUTOMAKE([1.8.3])
8AM_SILENT_RULES([yes])
8AM_MAINTAINER_MODE([enable]) 9AM_MAINTAINER_MODE([enable])
9AC_CONFIG_HEADERS([config.h]) 10AC_CONFIG_HEADERS([config.h])
10AC_CANONICAL_HOST 11AC_CANONICAL_HOST
@@ -273,26 +274,33 @@ AC_ARG_WITH([radius], [AS_HELP_STRING([--without-radius], [Skips the radius plug
273dnl Check for radius libraries 274dnl Check for radius libraries
274AS_IF([test "x$with_radius" != "xno"], [ 275AS_IF([test "x$with_radius" != "xno"], [
275 _SAVEDLIBS="$LIBS" 276 _SAVEDLIBS="$LIBS"
276 AC_CHECK_LIB(freeradius-client,rc_read_config) 277 AC_CHECK_LIB(radcli,rc_read_config)
277 if test "$ac_cv_lib_freeradius_client_rc_read_config" = "yes"; then 278 if test "$ac_cv_lib_radcli_rc_read_config" = "yes"; then
278 EXTRAS="$EXTRAS check_radius\$(EXEEXT)" 279 EXTRAS="$EXTRAS check_radius\$(EXEEXT)"
279 RADIUSLIBS="-lfreeradius-client" 280 RADIUSLIBS="-lradcli"
280 AC_SUBST(RADIUSLIBS) 281 AC_SUBST(RADIUSLIBS)
281 else 282 else
282 AC_CHECK_LIB(radiusclient-ng,rc_read_config) 283 AC_CHECK_LIB(freeradius-client,rc_read_config)
283 if test "$ac_cv_lib_radiusclient_ng_rc_read_config" = "yes"; then 284 if test "$ac_cv_lib_freeradius_client_rc_read_config" = "yes"; then
284 EXTRAS="$EXTRAS check_radius\$(EXEEXT)" 285 EXTRAS="$EXTRAS check_radius\$(EXEEXT)"
285 RADIUSLIBS="-lradiusclient-ng" 286 RADIUSLIBS="-lfreeradius-client"
286 AC_SUBST(RADIUSLIBS) 287 AC_SUBST(RADIUSLIBS)
287 else 288 else
288 AC_CHECK_LIB(radiusclient,rc_read_config) 289 AC_CHECK_LIB(radiusclient-ng,rc_read_config)
289 if test "$ac_cv_lib_radiusclient_rc_read_config" = "yes"; then 290 if test "$ac_cv_lib_radiusclient_ng_rc_read_config" = "yes"; then
290 EXTRAS="$EXTRAS check_radius\$(EXEEXT)" 291 EXTRAS="$EXTRAS check_radius\$(EXEEXT)"
291 RADIUSLIBS="-lradiusclient" 292 RADIUSLIBS="-lradiusclient-ng"
292 AC_SUBST(RADIUSLIBS) 293 AC_SUBST(RADIUSLIBS)
293 else 294 else
294 AC_MSG_WARN([Skipping radius plugin]) 295 AC_CHECK_LIB(radiusclient,rc_read_config)
295 AC_MSG_WARN([install radius libs to compile this plugin (see REQUIREMENTS).]) 296 if test "$ac_cv_lib_radiusclient_rc_read_config" = "yes"; then
297 EXTRAS="$EXTRAS check_radius\$(EXEEXT)"
298 RADIUSLIBS="-lradiusclient"
299 AC_SUBST(RADIUSLIBS)
300 else
301 AC_MSG_WARN([Skipping radius plugin])
302 AC_MSG_WARN([install radius libs to compile this plugin (see REQUIREMENTS).])
303 fi
296 fi 304 fi
297 fi 305 fi
298 fi 306 fi
@@ -320,6 +328,25 @@ AS_IF([test "x$with_ldap" != "xno"], [
320 LIBS="$_SAVEDLIBS" 328 LIBS="$_SAVEDLIBS"
321]) 329])
322 330
331
332AC_ARG_WITH([systemd], [AS_HELP_STRING([--without-systemd], [Skips systemd support])])
333
334dnl Check for libsystemd
335AS_IF([test "x$with_systemd" != "xno"], [
336 _SAVEDLIBS="$LIBS"
337 AC_CHECK_LIB(systemd,sd_get_sessions,,,-lsystemd)
338 if test "$ac_cv_lib_systemd_sd_get_sessions" = "yes"; then
339 SYSTEMDLIBS="-lsystemd"
340 SYSTEMDINCLUDE=""
341 AC_SUBST(SYSTEMDLIBS)
342 AC_SUBST(SYSTEMDINCLUDE)
343 else
344 AC_MSG_WARN([Skipping systemd support])
345 fi
346 LIBS="$_SAVEDLIBS"
347])
348
349
323dnl Check for headers used by check_ide_smart 350dnl Check for headers used by check_ide_smart
324case $host in 351case $host in
325 *linux*) 352 *linux*)
@@ -378,12 +405,48 @@ if test "$ac_cv_header_wtsapi32_h" = "yes"; then
378 AC_SUBST(WTSAPI32LIBS) 405 AC_SUBST(WTSAPI32LIBS)
379fi 406fi
380 407
408_can_enable_check_curl=no
409dnl Check for cURL library
410LIBCURL_CHECK_CONFIG(yes, 7.15.2, [
411 _can_enable_check_curl=yes
412 LIBCURLINCLUDE="$LIBCURL_CPPFLAGS"
413 LIBCURLLIBS="$LIBCURL"
414 LIBCURLCFLAGS="$LIBCURL_CPPFLAGS"
415 AC_SUBST(LIBCURLINCLUDE)
416 AC_SUBST(LIBCURLLIBS)
417 AC_SUBST(LIBCURLCFLAGS)
418 ], [
419 _can_enable_check_curl=no
420 AC_MSG_WARN([Skipping curl plugin])
421 AC_MSG_WARN([install libcurl libs to compile this plugin (see REQUIREMENTS).])
422])
423
424dnl Check for uriparser library
425URIPARSER_CHECK(yes, 0.7.5, [
426 URIPARSERINCLUDE="$URIPARSER_CPPFLAGS"
427 URIPARSERLIBS="$URIPARSER"
428 URIPARSERCFLAGS="$URIPARSER_CPPFLAGS"
429 AC_SUBST(URIPARSERINCLUDE)
430 AC_SUBST(URIPARSERLIBS)
431 AC_SUBST(URIPARSERCFLAGS)
432 ], [
433 _can_enable_check_curl=no
434 AC_MSG_WARN([Skipping curl plugin])
435 AC_MSG_WARN([install the uriparser library to compile this plugin (see REQUIREMENTS).])
436])
437
438dnl prerequisites met, enable the plugin
439if test x$_can_enable_check_curl = xyes; then
440 EXTRAS="$EXTRAS check_curl\$(EXEEXT)"
441fi
442AC_CONFIG_FILES([plugins/picohttpparser/Makefile])
443
381dnl Fallback to who(1) if the system doesn't provide an utmpx(5) interface 444dnl Fallback to who(1) if the system doesn't provide an utmpx(5) interface
382if test "$ac_cv_header_utmpx_h" = "no" -a "$ac_cv_header_wtsapi32_h" = "no" 445if test "$ac_cv_header_utmpx_h" = "no" -a "$ac_cv_header_wtsapi32_h" = "no"
383then 446then
384 AC_PATH_PROG(PATH_TO_WHO,who) 447 AC_PATH_PROG(PATH_TO_WHO,who)
385 448
386 if [$PATH_TO_WHO -q 2>/dev/null | egrep -i "^# users=[0-9]+$" >/dev/null] 449 if [$PATH_TO_WHO -q 2>/dev/null | grep -E -i "^# users=[0-9]+$" >/dev/null]
387 then 450 then
388 ac_cv_path_to_who="$PATH_TO_WHO -q" 451 ac_cv_path_to_who="$PATH_TO_WHO -q"
389 else 452 else
@@ -493,15 +556,15 @@ if ! test x"$with_openssl" = x"no"; then
493 dnl Check for crypto lib 556 dnl Check for crypto lib
494 _SAVEDLIBS="$LIBS" 557 _SAVEDLIBS="$LIBS"
495 LIBS="-L${with_openssl}/lib" 558 LIBS="-L${with_openssl}/lib"
496 AC_CHECK_LIB(crypto,CRYPTO_lock) 559 AC_CHECK_LIB(crypto,CRYPTO_new_ex_data)
497 if test "$ac_cv_lib_crypto_CRYPTO_lock" = "yes"; then 560 if test "$ac_cv_lib_crypto_CRYPTO_new_ex_data" = "yes"; then
498 dnl Check for SSL lib 561 dnl Check for SSL lib
499 AC_CHECK_LIB(ssl,main, SSLLIBS="-lssl -lcrypto",,-lcrypto) 562 AC_CHECK_LIB(ssl,main, SSLLIBS="-lssl -lcrypto",,-lcrypto)
500 fi 563 fi
501 LIBS="$_SAVEDLIBS" 564 LIBS="$_SAVEDLIBS"
502 565
503 dnl test headers and libs to decide whether check_http should use SSL 566 dnl test headers and libs to decide whether check_http should use SSL
504 if test "$ac_cv_lib_crypto_CRYPTO_lock" = "yes"; then 567 if test "$ac_cv_lib_crypto_CRYPTO_new_ex_data" = "yes"; then
505 if test "$ac_cv_lib_ssl_main" = "yes"; then 568 if test "$ac_cv_lib_ssl_main" = "yes"; then
506 if test "$FOUNDINCLUDE" = "yes"; then 569 if test "$FOUNDINCLUDE" = "yes"; then
507 FOUNDOPENSSL="yes" 570 FOUNDOPENSSL="yes"
@@ -558,7 +621,6 @@ AC_C_CONST
558AC_STRUCT_TM 621AC_STRUCT_TM
559AC_TYPE_PID_T 622AC_TYPE_PID_T
560AC_TYPE_SIZE_T 623AC_TYPE_SIZE_T
561AC_TYPE_SIGNAL
562 624
563AC_CACHE_CHECK([for va_copy],ac_cv_HAVE_VA_COPY,[ 625AC_CACHE_CHECK([for va_copy],ac_cv_HAVE_VA_COPY,[
564AC_TRY_LINK([#include <stdarg.h> 626AC_TRY_LINK([#include <stdarg.h>
@@ -732,7 +794,7 @@ dnl Removing this for the moment - Ton
732dnl Using /usr/ucb/ps on Solaris systems, to avoid truncation 794dnl Using /usr/ucb/ps on Solaris systems, to avoid truncation
733dnl Limitation that command name is not available 795dnl Limitation that command name is not available
734dnl elif test "$ac_cv_uname_s" = "SunOS" && /usr/ucb/ps -alxwwn 2>/dev/null | \ 796dnl elif test "$ac_cv_uname_s" = "SunOS" && /usr/ucb/ps -alxwwn 2>/dev/null | \
735dnl egrep -i ["^ *F +UID +PID +PPID +%C +PRI +NI +SZ +RSS +WCHAN +S +TT +TIME +COMMAND"] > /dev/null 797dnl grep -E -i ["^ *F +UID +PID +PPID +%C +PRI +NI +SZ +RSS +WCHAN +S +TT +TIME +COMMAND"] > /dev/null
736dnl then 798dnl then
737dnl ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procpcpu,&procvsz,&procrss,procstat,&pos]" 799dnl ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procpcpu,&procvsz,&procrss,procstat,&pos]"
738dnl ac_cv_ps_command="/usr/ucb/ps -alxwwn" 800dnl ac_cv_ps_command="/usr/ucb/ps -alxwwn"
@@ -740,10 +802,20 @@ dnl ac_cv_ps_format=["%*s %d %d %d %d %*d %*d %d %d%*[ 0123456789abcdef]%[OSRZT
740dnl ac_cv_ps_cols=8 802dnl ac_cv_ps_cols=8
741dnl AC_MSG_RESULT([$ac_cv_ps_command]) 803dnl AC_MSG_RESULT([$ac_cv_ps_command])
742 804
805dnl This one is the exact same test as the next one but includes etime
806elif ps axwo 'stat comm vsz rss user uid pid ppid etime args' 2>/dev/null | \
807 grep -E -i ["^ *STAT +[UCOMAND]+ +VSZ +RSS +USER +UID +PID +PPID +ELAPSED +COMMAND"] > /dev/null
808then
809 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procetime,procprog,&pos]"
810 ac_cv_ps_command="$PATH_TO_PS axwo 'stat uid pid ppid vsz rss pcpu etime comm args'"
811 ac_cv_ps_format="%s %d %d %d %d %d %f %s %s %n"
812 ac_cv_ps_cols=10
813 AC_MSG_RESULT([$ac_cv_ps_command])
814
743dnl Some gnu/linux systems (debian for one) don't like -axwo and need axwo. 815dnl Some gnu/linux systems (debian for one) don't like -axwo and need axwo.
744dnl so test for this first... 816dnl so test for this first...
745elif ps axwo 'stat comm vsz rss user uid pid ppid args' 2>/dev/null | \ 817elif ps axwo 'stat comm vsz rss user uid pid ppid args' 2>/dev/null | \
746 egrep -i ["^ *STAT +[UCOMAND]+ +VSZ +RSS +USER +UID +PID +PPID +COMMAND"] > /dev/null 818 grep -E -i ["^ *STAT +[UCOMAND]+ +VSZ +RSS +USER +UID +PID +PPID +COMMAND"] > /dev/null
747then 819then
748 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 820 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
749 ac_cv_ps_command="$PATH_TO_PS axwo 'stat uid pid ppid vsz rss pcpu comm args'" 821 ac_cv_ps_command="$PATH_TO_PS axwo 'stat uid pid ppid vsz rss pcpu comm args'"
@@ -755,7 +827,7 @@ dnl For OpenBSD 3.2 & 3.3. Must come before ps -weo
755dnl Should also work for FreeBSD 5.2.1 and 5.3 827dnl Should also work for FreeBSD 5.2.1 and 5.3
756dnl STAT UCOMM VSZ RSS USER PPID COMMAND 828dnl STAT UCOMM VSZ RSS USER PPID COMMAND
757elif ps -axwo 'stat comm vsz rss user uid pid ppid args' 2>/dev/null | \ 829elif ps -axwo 'stat comm vsz rss user uid pid ppid args' 2>/dev/null | \
758 egrep -i ["^ *STAT +[UCOMAND]+ +VSZ +RSS +USER +UID +PID +PPID +COMMAND"] > /dev/null 830 grep -E -i ["^ *STAT +[UCOMAND]+ +VSZ +RSS +USER +UID +PID +PPID +COMMAND"] > /dev/null
759then 831then
760 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 832 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
761 ac_cv_ps_command="$PATH_TO_PS -axwo 'stat uid pid ppid vsz rss pcpu comm args'" 833 ac_cv_ps_command="$PATH_TO_PS -axwo 'stat uid pid ppid vsz rss pcpu comm args'"
@@ -767,7 +839,7 @@ dnl Some *BSDs have different format for ps. This is mainly to catch FreeBSD 4.
767dnl Limitation: Only first 16 chars returned for ucomm field 839dnl Limitation: Only first 16 chars returned for ucomm field
768dnl Must come before ps -weo 840dnl Must come before ps -weo
769elif ps -axwo 'stat uid pid ppid vsz rss pcpu ucomm command' 2>/dev/null | \ 841elif ps -axwo 'stat uid pid ppid vsz rss pcpu ucomm command' 2>/dev/null | \
770 egrep -i ["^ *STAT +UID +PID +PPID +VSZ +RSS +%CPU +UCOMM +COMMAND"] > /dev/null 842 grep -E -i ["^ *STAT +UID +PID +PPID +VSZ +RSS +%CPU +UCOMM +COMMAND"] > /dev/null
771then 843then
772 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 844 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
773 ac_cv_ps_command="$PATH_TO_PS -axwo 'stat uid pid ppid vsz rss pcpu ucomm command'" 845 ac_cv_ps_command="$PATH_TO_PS -axwo 'stat uid pid ppid vsz rss pcpu ucomm command'"
@@ -777,7 +849,7 @@ then
777 849
778dnl STAT UCOMM VSZ RSS USER UID PPID COMMAND 850dnl STAT UCOMM VSZ RSS USER UID PPID COMMAND
779elif ps -weo 'stat comm vsz rss user uid pid ppid etime args' 2>/dev/null | \ 851elif ps -weo 'stat comm vsz rss user uid pid ppid etime args' 2>/dev/null | \
780 egrep -i ["^ *S[TAUES]* +[UCOMDNA]+ +[VSIZE]+ +R[S]+ +U[SER]+ +U[ID]+ +P[ID]+ +P[PID]+ +[ELAPSD]+ +[RGSCOMDNA]+"] >/dev/null 852 grep -E -i ["^ *S[TAUES]* +[UCOMDNA]+ +[VSIZE]+ +R[S]+ +U[SER]+ +U[ID]+ +P[ID]+ +P[PID]+ +[ELAPSD]+ +[RGSCOMDNA]+"] >/dev/null
781then 853then
782 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procetime,procprog,&pos]" 854 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procetime,procprog,&pos]"
783 ac_cv_ps_command="$PATH_TO_PS -weo 'stat uid pid ppid vsz rss pcpu etime comm args'" 855 ac_cv_ps_command="$PATH_TO_PS -weo 'stat uid pid ppid vsz rss pcpu etime comm args'"
@@ -787,7 +859,7 @@ then
787 859
788dnl FreeBSD 860dnl FreeBSD
789elif ps waxco 'state command vsz rss uid user pid ppid' 2>/dev/null | \ 861elif ps waxco 'state command vsz rss uid user pid ppid' 2>/dev/null | \
790 egrep -i ["^STAT +COMMAND +VSZ +RSS +UID +USER +PID +PPID"] >/dev/null 862 grep -E -i ["^STAT +COMMAND +VSZ +RSS +UID +USER +PID +PPID"] >/dev/null
791then 863then
792 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 864 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
793 ac_cv_ps_command="$PATH_TO_PS waxco 'state uid pid ppid vsz rss pcpu command command'" 865 ac_cv_ps_command="$PATH_TO_PS waxco 'state uid pid ppid vsz rss pcpu command command'"
@@ -797,7 +869,7 @@ then
797 869
798dnl BSD-like mode in RH 6.1 870dnl BSD-like mode in RH 6.1
799elif ps waxno 'state comm vsz rss uid user pid ppid args' 2>/dev/null | \ 871elif ps waxno 'state comm vsz rss uid user pid ppid args' 2>/dev/null | \
800 egrep -i ["^S +COMMAND +VSZ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null 872 grep -E -i ["^S +COMMAND +VSZ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null
801then 873then
802 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 874 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
803 ac_cv_ps_command="$PATH_TO_PS waxno 'state uid pid ppid vsz rss pcpu comm args'" 875 ac_cv_ps_command="$PATH_TO_PS waxno 'state uid pid ppid vsz rss pcpu comm args'"
@@ -809,7 +881,7 @@ dnl SunOS 4.1.3:
809dnl F UID PID PPID CP PRI NI SZ RSS WCHAN STAT TT TIME COMMAND 881dnl F UID PID PPID CP PRI NI SZ RSS WCHAN STAT TT TIME COMMAND
810dnl Need the head -1 otherwise test will work because arguments are found 882dnl Need the head -1 otherwise test will work because arguments are found
811elif ps -laxnwww 2>/dev/null | head -1 | \ 883elif ps -laxnwww 2>/dev/null | head -1 | \
812 egrep -i ["^ *F(LAGS)? +UID +PID +PPID +CP +PRI +NI +(SZ)|(VSZ)|(SIZE) +RSS +WCHAN +STAT? +TTY? +TIME +COMMAND"] >/dev/null 884 grep -E -i ["^ *F(LAGS)? +UID +PID +PPID +CP +PRI +NI +(SZ)|(VSZ)|(SIZE) +RSS +WCHAN +STAT? +TTY? +TIME +COMMAND"] >/dev/null
813then 885then
814 ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procvsz,&procrss,procstat,&pos,procprog]" 886 ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procvsz,&procrss,procstat,&pos,procprog]"
815 ac_cv_ps_command="$PATH_TO_PS -laxnwww" 887 ac_cv_ps_command="$PATH_TO_PS -laxnwww"
@@ -822,7 +894,7 @@ dnl FLAGS UID PID PPID PRI NI SIZE RSS WCHAN STA TTY TIME COMMA
822dnl 100 0 1 0 0 0 776 76 c0131c8c S ffff 0:11 init [2] 894dnl 100 0 1 0 0 0 776 76 c0131c8c S ffff 0:11 init [2]
823dnl 895dnl
824elif ps laxnwww 2>/dev/null | \ 896elif ps laxnwww 2>/dev/null | \
825 egrep -i ["^ *F(LAGS)? +UID +PID +PPID +PRI +NI +(VSZ)|(SIZE) +RSS +WCHAN +STAT? TTY +TIME +COMMAND"] >/dev/null 897 grep -E -i ["^ *F(LAGS)? +UID +PID +PPID +PRI +NI +(VSZ)|(SIZE) +RSS +WCHAN +STAT? TTY +TIME +COMMAND"] >/dev/null
826then 898then
827 ac_cv_ps_varlist="[&procuid,&procpid,&procppid,procstat,&procvsz,&procrss,&pos,procprog]" 899 ac_cv_ps_varlist="[&procuid,&procpid,&procppid,procstat,&procvsz,&procrss,&pos,procprog]"
828 ac_cv_ps_command="$PATH_TO_PS laxnwww" 900 ac_cv_ps_command="$PATH_TO_PS laxnwww"
@@ -832,7 +904,7 @@ then
832 904
833dnl OpenBSD (needs to come early because -exo appears to work, but does not give all procs) 905dnl OpenBSD (needs to come early because -exo appears to work, but does not give all procs)
834elif ps -axo 'stat comm vsz rss user uid pid ppid args' 2>/dev/null | \ 906elif ps -axo 'stat comm vsz rss user uid pid ppid args' 2>/dev/null | \
835 egrep -i ["^ *S[TAUES]* +[UCOMDNA]+ +[VSIZE]+ +R[S]+ +U[SER]+ +U[ID]+ +P[PID]+ +P[PID]+ +[RGSCOMDNA]+"] >/dev/null 907 grep -E -i ["^ *S[TAUES]* +[UCOMDNA]+ +[VSIZE]+ +R[S]+ +U[SER]+ +U[ID]+ +P[PID]+ +P[PID]+ +[RGSCOMDNA]+"] >/dev/null
836then 908then
837 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 909 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
838 ac_cv_ps_command="$PATH_TO_PS -axo 'stat uid pid ppid vsz rss pcpu comm args'" 910 ac_cv_ps_command="$PATH_TO_PS -axo 'stat uid pid ppid vsz rss pcpu comm args'"
@@ -845,7 +917,7 @@ dnl Has /usr/bin/ps and /sbin/ps - force sbin version
845dnl Can't use vsize and rssize because comes back with text (eg, 1.5M instead 917dnl Can't use vsize and rssize because comes back with text (eg, 1.5M instead
846dnl of 1500). Will need big changes to check_procs to support 918dnl of 1500). Will need big changes to check_procs to support
847elif /sbin/ps -eo 'stat uid pid ppid pcpu etime comm args' 2>/dev/null | \ 919elif /sbin/ps -eo 'stat uid pid ppid pcpu etime comm args' 2>/dev/null | \
848 egrep -i ["^ *S +[UID]+ +[PID]+ +[PID]+ +[%CPU]+ +[ELAPSD]+ +[COMMAND]+ +[COMMAND]+"] > /dev/null 920 grep -E -i ["^ *S +[UID]+ +[PID]+ +[PID]+ +[%CPU]+ +[ELAPSD]+ +[COMMAND]+ +[COMMAND]+"] > /dev/null
849then 921then
850 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procpcpu,procetime,procprog,&pos]" 922 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procpcpu,procetime,procprog,&pos]"
851 ac_cv_ps_command="/sbin/ps -eo 'stat uid pid ppid pcpu etime comm args'" 923 ac_cv_ps_command="/sbin/ps -eo 'stat uid pid ppid pcpu etime comm args'"
@@ -854,7 +926,7 @@ then
854 AC_MSG_RESULT([$ac_cv_ps_command]) 926 AC_MSG_RESULT([$ac_cv_ps_command])
855 927
856elif ps -eo 's comm vsz rss user uid pid ppid args' 2>/dev/null | \ 928elif ps -eo 's comm vsz rss user uid pid ppid args' 2>/dev/null | \
857 egrep -i ["^S[TAUES]* +C[OMDNA]+ +[VSIZE]+ +U[SER]+ +U[ID]+ +P[PID]+ +P[PID]+ +[RGSCOMDNA]+"] >/dev/null 929 grep -E -i ["^S[TAUES]* +C[OMDNA]+ +[VSIZE]+ +U[SER]+ +U[ID]+ +P[PID]+ +P[PID]+ +[RGSCOMDNA]+"] >/dev/null
858then 930then
859 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 931 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
860 ac_cv_ps_command="$PATH_TO_PS -eo 's uid pid ppid vsz rss pcpu comm args'" 932 ac_cv_ps_command="$PATH_TO_PS -eo 's uid pid ppid vsz rss pcpu comm args'"
@@ -864,7 +936,7 @@ then
864 936
865dnl AIX 4.3.3 and 5.1 do not have an rss field 937dnl AIX 4.3.3 and 5.1 do not have an rss field
866elif ps -eo 'stat uid pid ppid vsz pcpu comm args' 2>/dev/null | \ 938elif ps -eo 'stat uid pid ppid vsz pcpu comm args' 2>/dev/null | \
867 egrep -i ["^ *S[TAUES]* +UID +PID +PPID +VSZ +%CPU +COMMAND +COMMAND"] >/dev/null 939 grep -E -i ["^ *S[TAUES]* +UID +PID +PPID +VSZ +%CPU +COMMAND +COMMAND"] >/dev/null
868then 940then
869 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procpcpu,procprog,&pos]" 941 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procpcpu,procprog,&pos]"
870 ac_cv_ps_command="$PATH_TO_PS -eo 'stat uid pid ppid vsz pcpu comm args'" 942 ac_cv_ps_command="$PATH_TO_PS -eo 'stat uid pid ppid vsz pcpu comm args'"
@@ -874,18 +946,18 @@ then
874 946
875dnl Solaris 2.6 947dnl Solaris 2.6
876elif ps -Ao 's comm vsz rss uid user pid ppid args' 2>/dev/null | \ 948elif ps -Ao 's comm vsz rss uid user pid ppid args' 2>/dev/null | \
877 egrep -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null 949 grep -E -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null
878then 950then
879 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 951 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
880 ac_cv_ps_command="$PATH_TO_PS -Ao 's uid pid ppid vsz rss pcpu comm args'" 952 ac_cv_ps_command="$PATH_TO_PS -Ao 's uid pid ppid vsz rss pcpu comm args'"
881 # There must be no space between the %s and %n due to a wierd problem in sscanf where 953 # There must be no space between the %s and %n due to a weird problem in sscanf where
882 # it will return %n as longer than the line length 954 # it will return %n as longer than the line length
883 ac_cv_ps_format="%s %d %d %d %d %d %f %s%n" 955 ac_cv_ps_format="%s %d %d %d %d %d %f %s%n"
884 ac_cv_ps_cols=9 956 ac_cv_ps_cols=9
885 AC_MSG_RESULT([$ac_cv_ps_command]) 957 AC_MSG_RESULT([$ac_cv_ps_command])
886 958
887elif ps -Ao 'status comm vsz rss uid user pid ppid args' 2>/dev/null | \ 959elif ps -Ao 'status comm vsz rss uid user pid ppid args' 2>/dev/null | \
888 egrep -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null 960 grep -E -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null
889then 961then
890 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 962 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
891 ac_cv_ps_command="$PATH_TO_PS -Ao 'status uid pid ppid vsz rss pcpu comm args'" 963 ac_cv_ps_command="$PATH_TO_PS -Ao 'status uid pid ppid vsz rss pcpu comm args'"
@@ -894,7 +966,7 @@ then
894 AC_MSG_RESULT([$ac_cv_ps_command]) 966 AC_MSG_RESULT([$ac_cv_ps_command])
895 967
896elif ps -Ao 'state comm vsz rss uid user pid ppid args' 2>/dev/null | \ 968elif ps -Ao 'state comm vsz rss uid user pid ppid args' 2>/dev/null | \
897 egrep -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null 969 grep -E -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null
898then 970then
899 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 971 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
900 ac_cv_ps_command="$PATH_TO_PS -Ao 'state uid pid ppid vsz rss pcpu comm args'" 972 ac_cv_ps_command="$PATH_TO_PS -Ao 'state uid pid ppid vsz rss pcpu comm args'"
@@ -904,7 +976,7 @@ then
904 976
905dnl wonder who takes state instead of stat 977dnl wonder who takes state instead of stat
906elif ps -ao 'state command vsz rss user pid ppid args' 2>/dev/null | \ 978elif ps -ao 'state command vsz rss user pid ppid args' 2>/dev/null | \
907 egrep -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null 979 grep -E -i ["^S[TAUES]* +C[OMDNA]+ +V[SIZE]+ +RSS +UID +USER +PID +PPID +[RGSCOMDNA]+"] >/dev/null
908then 980then
909 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]" 981 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&procpcpu,procprog,&pos]"
910 ac_cv_ps_command="$PATH_TO_PS -ao 'state uid pid ppid vsz rss pcpu command args'" 982 ac_cv_ps_command="$PATH_TO_PS -ao 'state uid pid ppid vsz rss pcpu command args'"
@@ -914,7 +986,7 @@ then
914 986
915dnl IRIX 53 987dnl IRIX 53
916elif ps -el 2>/dev/null | \ 988elif ps -el 2>/dev/null | \
917 egrep -i ["^ *F +S +UID +PID +PPID +C +PRI +NI +P +SZ +RSS +WCHAN +TTY +TIME +[RGSCOMDNA]+"] >/dev/null 989 grep -E -i ["^ *F +S +UID +PID +PPID +C +PRI +NI +P +SZ +RSS +WCHAN +TTY +TIME +[RGSCOMDNA]+"] >/dev/null
918then 990then
919 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&pos,procprog]" 991 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procrss,&pos,procprog]"
920 ac_cv_ps_command="$PATH_TO_PS -el (IRIX 53)" 992 ac_cv_ps_command="$PATH_TO_PS -el (IRIX 53)"
@@ -924,7 +996,7 @@ then
924 996
925dnl IRIX 63 997dnl IRIX 63
926elif ps -el 2>/dev/null | \ 998elif ps -el 2>/dev/null | \
927 egrep -i ["^ *F +S +UID +PID +PPID +C +PRI +NI +P +ADDR +SZ +RSS +WCHAN +TTY +TIME +[RGSCOMDNA]+"] >/dev/null 999 grep -E -i ["^ *F +S +UID +PID +PPID +C +PRI +NI +P +ADDR +SZ +RSS +WCHAN +TTY +TIME +[RGSCOMDNA]+"] >/dev/null
928then 1000then
929 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&pos,procprog]" 1001 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&pos,procprog]"
930 ac_cv_ps_command="$PATH_TO_PS -el (IRIX 63)" 1002 ac_cv_ps_command="$PATH_TO_PS -el (IRIX 63)"
@@ -937,7 +1009,7 @@ dnl S UID RUID USER RUSER PID PPID VSZ %CPU COMMAND
937dnl S 0 400 root oracle 2805 1 12904 0.00 ora_dism_SEA1X ora_dism_SEA1X 1009dnl S 0 400 root oracle 2805 1 12904 0.00 ora_dism_SEA1X ora_dism_SEA1X
938dnl S 400 400 oracle oracle 19261 1 126488 0.00 tnslsnr /u01/app/oracle/product/db/11.2.0.3/bin/tnslsnr LISTENER -inherit 1010dnl S 400 400 oracle oracle 19261 1 126488 0.00 tnslsnr /u01/app/oracle/product/db/11.2.0.3/bin/tnslsnr LISTENER -inherit
939elif env UNIX95=1 ps -eo 'state uid ruid user ruser pid ppid vsz pcpu comm args' 2>/dev/null | head -n 1 | \ 1011elif env UNIX95=1 ps -eo 'state uid ruid user ruser pid ppid vsz pcpu comm args' 2>/dev/null | head -n 1 | \
940 egrep -i ["^ *S +UID +RUID +USER +RUSER +PID +PPID +VSZ +%CPU +COMMAND +COMMAND"] >/dev/null 1012 grep -E -i ["^ *S +UID +RUID +USER +RUSER +PID +PPID +VSZ +%CPU +COMMAND +COMMAND"] >/dev/null
941then 1013then
942 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procpcpu,procprog,&pos]" 1014 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&procvsz,&procpcpu,procprog,&pos]"
943 ac_cv_ps_command="$PATH_TO_ENV UNIX95=1 $PATH_TO_PS -eo 'state uid pid ppid vsz pcpu comm args'" 1015 ac_cv_ps_command="$PATH_TO_ENV UNIX95=1 $PATH_TO_PS -eo 'state uid pid ppid vsz pcpu comm args'"
@@ -949,7 +1021,7 @@ dnl AIX 4.1:
949dnl F S UID PID PPID C PRI NI ADDR SZ RSS WCHAN TTY TIME CMD 1021dnl F S UID PID PPID C PRI NI ADDR SZ RSS WCHAN TTY TIME CMD
950dnl 303 A 0 0 0 120 16 -- 1c07 20 24 - 0:45 swapper 1022dnl 303 A 0 0 0 120 16 -- 1c07 20 24 - 0:45 swapper
951elif ps -el 2>/dev/null | \ 1023elif ps -el 2>/dev/null | \
952 egrep -i ["^ *F +S +UID +PID +PPID +C +PRI +NI +ADDR +SZ +WCHAN +TTY +TIME +[RGSCOMDNA]+"] >/dev/null 1024 grep -E -i ["^ *F +S +UID +PID +PPID +C +PRI +NI +ADDR +SZ +WCHAN +TTY +TIME +[RGSCOMDNA]+"] >/dev/null
953then 1025then
954 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&pos,procprog]" 1026 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&pos,procprog]"
955 ac_cv_ps_command="$PATH_TO_PS -el (AIX 4.1 and HP-UX)" 1027 ac_cv_ps_command="$PATH_TO_PS -el (AIX 4.1 and HP-UX)"
@@ -959,7 +1031,7 @@ then
959 1031
960dnl AIX? 1032dnl AIX?
961elif ps glaxen 2>/dev/null | \ 1033elif ps glaxen 2>/dev/null | \
962 egrep -i ["^ *F +UID +PID +PPID +PRI +NI +VSZ +RSS +WCHAN +STAT +TTY +TIME +COMMAND"] >/dev/null 1034 grep -E -i ["^ *F +UID +PID +PPID +PRI +NI +VSZ +RSS +WCHAN +STAT +TTY +TIME +COMMAND"] >/dev/null
963then 1035then
964 ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procvsz,&procrss,procstat,&pos,procprog]" 1036 ac_cv_ps_varlist="[&procuid,&procpid,&procppid,&procvsz,&procrss,procstat,&pos,procprog]"
965 ac_cv_ps_command="$PATH_TO_PS glaxen" 1037 ac_cv_ps_command="$PATH_TO_PS glaxen"
@@ -973,7 +1045,7 @@ dnl Some truncation will happen in UCOMM column
973dnl STAT VSZ RSS UID PPID %CPU UCOMM COMMAND 1045dnl STAT VSZ RSS UID PPID %CPU UCOMM COMMAND
974dnl Ss 52756 22496 501 1 6.9 Window Manager /System/Library/CoreServices/WindowServer -daemon 1046dnl Ss 52756 22496 501 1 6.9 Window Manager /System/Library/CoreServices/WindowServer -daemon
975elif ps wwaxo 'state vsz rss uid pid ppid pcpu ucomm command' 2>/dev/null | \ 1047elif ps wwaxo 'state vsz rss uid pid ppid pcpu ucomm command' 2>/dev/null | \
976 egrep -i ["^STAT +VSZ +RSS +UID +PPID +%CPU +UCOMM +COMMAND"] >/dev/null 1048 grep -E -i ["^STAT +VSZ +RSS +UID +PPID +%CPU +UCOMM +COMMAND"] >/dev/null
977then 1049then
978 ac_cv_ps_command="$PATH_TO_PS wwaxo 'state vsz rss uid pid ppid pcpu ucomm command'" 1050 ac_cv_ps_command="$PATH_TO_PS wwaxo 'state vsz rss uid pid ppid pcpu ucomm command'"
979 ac_cv_ps_varlist="[procstat,&procvsz,&procrss,&procuid,&procpid,&procppid,&procpcpu,procprog,&pos]" 1051 ac_cv_ps_varlist="[procstat,&procvsz,&procrss,&procuid,&procpid,&procppid,&procpcpu,procprog,&pos]"
@@ -983,7 +1055,7 @@ then
983 1055
984dnl UnixWare 1056dnl UnixWare
985elif ps -Al 2>/dev/null | \ 1057elif ps -Al 2>/dev/null | \
986 egrep -i ["^ *F +S +UID +PID +PPID +CLS +PRI +NI +C +ADDR +SZ +WCHAN +TTY +TIME +COMD"] >/dev/null 1058 grep -E -i ["^ *F +S +UID +PID +PPID +CLS +PRI +NI +C +ADDR +SZ +WCHAN +TTY +TIME +COMD"] >/dev/null
987then 1059then
988 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&pos,procprog]" 1060 ac_cv_ps_varlist="[procstat,&procuid,&procpid,&procppid,&pos,procprog]"
989 ac_cv_ps_command="$PATH_TO_PS -Al" 1061 ac_cv_ps_command="$PATH_TO_PS -Al"
@@ -1009,6 +1081,10 @@ if test -n "$ac_cv_ps_varlist" ; then
1009 AC_DEFINE(PS_USES_PROCETIME,"yes", 1081 AC_DEFINE(PS_USES_PROCETIME,"yes",
1010 [Whether the ps utility uses the "procetime" field]) 1082 [Whether the ps utility uses the "procetime" field])
1011 fi 1083 fi
1084 if echo "$ac_cv_ps_varlist" | grep "procpcpu" >/dev/null; then
1085 AC_DEFINE(PS_USES_PROCPCPU,"yes",
1086 [Whether the ps utility uses the "procpcpu" field])
1087 fi
1012fi 1088fi
1013 1089
1014AC_PATH_PROG(PATH_TO_PING,ping) 1090AC_PATH_PROG(PATH_TO_PING,ping)
@@ -1047,14 +1123,22 @@ then
1047 1123
1048elif [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \ 1124elif [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \
1049 $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \ 1125 $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \
1050 egrep -i "^round-trip|^rtt" >/dev/null 1126 grep -E -i "^round-trip|^rtt" >/dev/null
1051then 1127then
1052 with_ping_command="$PATH_TO_PING -n -U -c %d %s" 1128 with_ping_command="$PATH_TO_PING -n -U -c %d %s"
1053 ac_cv_ping_packets_first=yes 1129 ac_cv_ping_packets_first=yes
1054 AC_MSG_RESULT([$with_ping_command]) 1130 AC_MSG_RESULT([$with_ping_command])
1055 1131
1132elif $PATH_TO_PING -4 -n -U -w 10 -c 1 127.0.0.1 2>/dev/null | \
1133 grep -E -i "^round-trip|^rtt" >/dev/null
1134then
1135 # check if -4 is supported - issue #1550
1136 with_ping_command="$PATH_TO_PING -4 -n -U -w %d -c %d %s"
1137 ac_cv_ping_packets_first=yes
1138 ac_cv_ping_has_timeout=yes
1139 AC_MSG_RESULT([$with_ping_command])
1056elif $PATH_TO_PING -n -U -w 10 -c 1 127.0.0.1 2>/dev/null | \ 1140elif $PATH_TO_PING -n -U -w 10 -c 1 127.0.0.1 2>/dev/null | \
1057 egrep -i "^round-trip|^rtt" >/dev/null 1141 grep -E -i "^round-trip|^rtt" >/dev/null
1058then 1142then
1059 with_ping_command="$PATH_TO_PING -n -U -w %d -c %d %s" 1143 with_ping_command="$PATH_TO_PING -n -U -w %d -c %d %s"
1060 ac_cv_ping_packets_first=yes 1144 ac_cv_ping_packets_first=yes
@@ -1062,52 +1146,52 @@ then
1062 AC_MSG_RESULT([$with_ping_command]) 1146 AC_MSG_RESULT([$with_ping_command])
1063 1147
1064elif $PATH_TO_PING -n -U -c 1 127.0.0.1 2>/dev/null | \ 1148elif $PATH_TO_PING -n -U -c 1 127.0.0.1 2>/dev/null | \
1065 egrep -i "^round-trip|^rtt" >/dev/null 1149 grep -E -i "^round-trip|^rtt" >/dev/null
1066then 1150then
1067 with_ping_command="$PATH_TO_PING -n -U -c %d %s" 1151 with_ping_command="$PATH_TO_PING -n -U -c %d %s"
1068 ac_cv_ping_packets_first=yes 1152 ac_cv_ping_packets_first=yes
1069 AC_MSG_RESULT([$with_ping_command]) 1153 AC_MSG_RESULT([$with_ping_command])
1070 1154
1071elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \ 1155elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \
1072 egrep -i "^round-trip|^rtt" >/dev/null 1156 grep -E -i "^round-trip|^rtt" >/dev/null
1073then 1157then
1074 with_ping_command="$PATH_TO_PING -n -c %d %s" 1158 with_ping_command="$PATH_TO_PING -n -c %d %s"
1075 ac_cv_ping_packets_first=yes 1159 ac_cv_ping_packets_first=yes
1076 AC_MSG_RESULT([$with_ping_command]) 1160 AC_MSG_RESULT([$with_ping_command])
1077 1161
1078elif $PATH_TO_PING -n 127.0.0.1 -c 1 2>/dev/null | \ 1162elif $PATH_TO_PING -n 127.0.0.1 -c 1 2>/dev/null | \
1079 egrep -i "^round-trip|^rtt" >/dev/null 1163 grep -E -i "^round-trip|^rtt" >/dev/null
1080then 1164then
1081 with_ping_command="$PATH_TO_PING -n %s -c %d" 1165 with_ping_command="$PATH_TO_PING -n %s -c %d"
1082 AC_MSG_RESULT([$with_ping_command]) 1166 AC_MSG_RESULT([$with_ping_command])
1083 1167
1084elif $PATH_TO_PING 127.0.0.1 -n 1 2>/dev/null | \ 1168elif $PATH_TO_PING 127.0.0.1 -n 1 2>/dev/null | \
1085 egrep -i "^round-trip|^rtt" >/dev/null 1169 grep -E -i "^round-trip|^rtt" >/dev/null
1086then 1170then
1087 with_ping_command="$PATH_TO_PING %s -n %d" 1171 with_ping_command="$PATH_TO_PING %s -n %d"
1088 AC_MSG_RESULT([$with_ping_command]) 1172 AC_MSG_RESULT([$with_ping_command])
1089 1173
1090elif $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \ 1174elif $PATH_TO_PING -n -s 127.0.0.1 56 1 2>/dev/null | \
1091 egrep -i "^round-trip|^rtt" >/dev/null 1175 grep -E -i "^round-trip|^rtt" >/dev/null
1092then 1176then
1093 with_ping_command="$PATH_TO_PING -n -s %s 56 %d" 1177 with_ping_command="$PATH_TO_PING -n -s %s 56 %d"
1094 AC_MSG_RESULT([$with_ping_command]) 1178 AC_MSG_RESULT([$with_ping_command])
1095 1179
1096elif $PATH_TO_PING -n -h 127.0.0.1 -s 56 -c 1 2>/dev/null | \ 1180elif $PATH_TO_PING -n -h 127.0.0.1 -s 56 -c 1 2>/dev/null | \
1097 egrep -i "^round-trip|^rtt" >/dev/null 1181 grep -E -i "^round-trip|^rtt" >/dev/null
1098then 1182then
1099 with_ping_command="$PATH_TO_PING -n -h %s -s 56 -c %d" 1183 with_ping_command="$PATH_TO_PING -n -h %s -s 56 -c %d"
1100 AC_MSG_RESULT([$with_ping_command]) 1184 AC_MSG_RESULT([$with_ping_command])
1101 1185
1102elif $PATH_TO_PING -n -s 56 -c 1 127.0.0.1 2>/dev/null | \ 1186elif $PATH_TO_PING -n -s 56 -c 1 127.0.0.1 2>/dev/null | \
1103 egrep -i "^round-trip|^rtt" >/dev/null 1187 grep -E -i "^round-trip|^rtt" >/dev/null
1104then 1188then
1105 with_ping_command="$PATH_TO_PING -n -s 56 -c %d %s" 1189 with_ping_command="$PATH_TO_PING -n -s 56 -c %d %s"
1106 ac_cv_ping_packets_first=yes 1190 ac_cv_ping_packets_first=yes
1107 AC_MSG_RESULT([$with_ping_command]) 1191 AC_MSG_RESULT([$with_ping_command])
1108 1192
1109elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \ 1193elif $PATH_TO_PING -n -c 1 127.0.0.1 2>/dev/null | \
1110 egrep -i "^round-trip|^rtt" >/dev/null 1194 grep -E -i "^round-trip|^rtt" >/dev/null
1111then 1195then
1112 with_ping_command="$PATH_TO_PING -n -c %d %s" 1196 with_ping_command="$PATH_TO_PING -n -c %d %s"
1113 ac_cv_ping_packets_first=yes 1197 ac_cv_ping_packets_first=yes
@@ -1163,14 +1247,14 @@ elif [[ "z$ac_cv_uname_o" = "zCygwin" -a "x$PATH_TO_PING" != "x" ]]; then
1163elif test "x$PATH_TO_PING6" != "x"; then 1247elif test "x$PATH_TO_PING6" != "x"; then
1164 if [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \ 1248 if [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \
1165 $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \ 1249 $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \
1166 egrep -i "^round-trip|^rtt" >/dev/null 1250 grep -E -i "^round-trip|^rtt" >/dev/null
1167 then 1251 then
1168 with_ping6_command="$PATH_TO_PING6 -n -U -c %d %s" 1252 with_ping6_command="$PATH_TO_PING6 -n -U -c %d %s"
1169 ac_cv_ping6_packets_first=yes 1253 ac_cv_ping6_packets_first=yes
1170 AC_MSG_RESULT([$with_ping6_command]) 1254 AC_MSG_RESULT([$with_ping6_command])
1171 1255
1172 elif $PATH_TO_PING6 -n -U -w 10 -c 1 ::1 2>/dev/null | \ 1256 elif $PATH_TO_PING6 -n -U -w 10 -c 1 ::1 2>/dev/null | \
1173 egrep -i "^round-trip|^rtt" >/dev/null 1257 grep -E -i "^round-trip|^rtt" >/dev/null
1174 then 1258 then
1175 with_ping6_command="$PATH_TO_PING6 -n -U -w %d -c %d %s" 1259 with_ping6_command="$PATH_TO_PING6 -n -U -w %d -c %d %s"
1176 ac_cv_ping6_packets_first=yes 1260 ac_cv_ping6_packets_first=yes
@@ -1178,52 +1262,52 @@ elif test "x$PATH_TO_PING6" != "x"; then
1178 AC_MSG_RESULT([$with_ping6_command]) 1262 AC_MSG_RESULT([$with_ping6_command])
1179 1263
1180 elif $PATH_TO_PING6 -n -U -c 1 ::1 2>/dev/null | \ 1264 elif $PATH_TO_PING6 -n -U -c 1 ::1 2>/dev/null | \
1181 egrep -i "^round-trip|^rtt" >/dev/null 1265 grep -E -i "^round-trip|^rtt" >/dev/null
1182 then 1266 then
1183 with_ping6_command="$PATH_TO_PING6 -n -U -c %d %s" 1267 with_ping6_command="$PATH_TO_PING6 -n -U -c %d %s"
1184 ac_cv_ping6_packets_first=yes 1268 ac_cv_ping6_packets_first=yes
1185 AC_MSG_RESULT([$with_ping6_command]) 1269 AC_MSG_RESULT([$with_ping6_command])
1186 1270
1187 elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \ 1271 elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \
1188 egrep -i "^round-trip|^rtt" >/dev/null 1272 grep -E -i "^round-trip|^rtt" >/dev/null
1189 then 1273 then
1190 with_ping6_command="$PATH_TO_PING6 -n -c %d %s" 1274 with_ping6_command="$PATH_TO_PING6 -n -c %d %s"
1191 ac_cv_ping6_packets_first=yes 1275 ac_cv_ping6_packets_first=yes
1192 AC_MSG_RESULT([$with_ping6_command]) 1276 AC_MSG_RESULT([$with_ping6_command])
1193 1277
1194 elif $PATH_TO_PING6 -n ::1 -c 1 2>/dev/null | \ 1278 elif $PATH_TO_PING6 -n ::1 -c 1 2>/dev/null | \
1195 egrep -i "^round-trip|^rtt" >/dev/null 1279 grep -E -i "^round-trip|^rtt" >/dev/null
1196 then 1280 then
1197 with_ping6_command="$PATH_TO_PING6 -n %s -c %d" 1281 with_ping6_command="$PATH_TO_PING6 -n %s -c %d"
1198 AC_MSG_RESULT([$with_ping6_command]) 1282 AC_MSG_RESULT([$with_ping6_command])
1199 1283
1200 elif $PATH_TO_PING6 ::1 -n 1 2>/dev/null | \ 1284 elif $PATH_TO_PING6 ::1 -n 1 2>/dev/null | \
1201 egrep -i "^round-trip|^rtt" >/dev/null 1285 grep -E -i "^round-trip|^rtt" >/dev/null
1202 then 1286 then
1203 with_ping6_command="$PATH_TO_PING6 %s -n %d" 1287 with_ping6_command="$PATH_TO_PING6 %s -n %d"
1204 AC_MSG_RESULT([$with_ping6_command]) 1288 AC_MSG_RESULT([$with_ping6_command])
1205 1289
1206 elif $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \ 1290 elif $PATH_TO_PING6 -n -s ::1 56 1 2>/dev/null | \
1207 egrep -i "^round-trip|^rtt" >/dev/null 1291 grep -E -i "^round-trip|^rtt" >/dev/null
1208 then 1292 then
1209 with_ping6_command="$PATH_TO_PING6 -n -s %s 56 %d" 1293 with_ping6_command="$PATH_TO_PING6 -n -s %s 56 %d"
1210 AC_MSG_RESULT([$with_ping6_command]) 1294 AC_MSG_RESULT([$with_ping6_command])
1211 1295
1212 elif $PATH_TO_PING6 -n -h ::1 -s 56 -c 1 2>/dev/null | \ 1296 elif $PATH_TO_PING6 -n -h ::1 -s 56 -c 1 2>/dev/null | \
1213 egrep -i "^round-trip|^rtt" >/dev/null 1297 grep -E -i "^round-trip|^rtt" >/dev/null
1214 then 1298 then
1215 with_ping6_command="$PATH_TO_PING6 -n -h %s -s 56 -c %d" 1299 with_ping6_command="$PATH_TO_PING6 -n -h %s -s 56 -c %d"
1216 AC_MSG_RESULT([$with_ping6_command]) 1300 AC_MSG_RESULT([$with_ping6_command])
1217 1301
1218 elif $PATH_TO_PING6 -n -s 56 -c 1 ::1 2>/dev/null | \ 1302 elif $PATH_TO_PING6 -n -s 56 -c 1 ::1 2>/dev/null | \
1219 egrep -i "^round-trip|^rtt" >/dev/null 1303 grep -E -i "^round-trip|^rtt" >/dev/null
1220 then 1304 then
1221 with_ping6_command="$PATH_TO_PING6 -n -s 56 -c %d %s" 1305 with_ping6_command="$PATH_TO_PING6 -n -s 56 -c %d %s"
1222 ac_cv_ping6_packets_first=yes 1306 ac_cv_ping6_packets_first=yes
1223 AC_MSG_RESULT([$with_ping_command]) 1307 AC_MSG_RESULT([$with_ping_command])
1224 1308
1225 elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \ 1309 elif $PATH_TO_PING6 -n -c 1 ::1 2>/dev/null | \
1226 egrep -i "^round-trip|^rtt" >/dev/null 1310 grep -E -i "^round-trip|^rtt" >/dev/null
1227 then 1311 then
1228 with_ping6_command="$PATH_TO_PING6 -n -c %d %s" 1312 with_ping6_command="$PATH_TO_PING6 -n -c %d %s"
1229 ac_cv_ping6_packets_first=yes 1313 ac_cv_ping6_packets_first=yes
@@ -1234,59 +1318,59 @@ elif test "x$PATH_TO_PING6" != "x"; then
1234elif test "x$PATH_TO_PING" != "x"; then 1318elif test "x$PATH_TO_PING" != "x"; then
1235 if [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \ 1319 if [[ "z$ac_cv_uname_s" = "zUnixWare" ]] && \
1236 $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \ 1320 $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \
1237 egrep -i "^round-trip|^rtt" >/dev/null 1321 grep -E -i "^round-trip|^rtt" >/dev/null
1238 then 1322 then
1239 with_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s" 1323 with_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s"
1240 ac_cv_ping6_packets_first=yes 1324 ac_cv_ping6_packets_first=yes
1241 AC_MSG_RESULT([$with_ping6_command]) 1325 AC_MSG_RESULT([$with_ping6_command])
1242 1326
1243 elif $PATH_TO_PING -A inet6 -n -U -c 1 ::1 2>/dev/null | \ 1327 elif $PATH_TO_PING -A inet6 -n -U -c 1 ::1 2>/dev/null | \
1244 egrep -i "^round-trip|^rtt" >/dev/null 1328 grep -E -i "^round-trip|^rtt" >/dev/null
1245 then 1329 then
1246 with_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s" 1330 with_ping6_command="$PATH_TO_PING -A inet6 -n -U -c %d %s"
1247 ac_cv_ping6_packets_first=yes 1331 ac_cv_ping6_packets_first=yes
1248 AC_MSG_RESULT([$with_ping6_command]) 1332 AC_MSG_RESULT([$with_ping6_command])
1249 1333
1250 elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \ 1334 elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \
1251 egrep -i "^round-trip|^rtt" >/dev/null 1335 grep -E -i "^round-trip|^rtt" >/dev/null
1252 then 1336 then
1253 with_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s" 1337 with_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s"
1254 ac_cv_ping6_packets_first=yes 1338 ac_cv_ping6_packets_first=yes
1255 AC_MSG_RESULT([$with_ping6_command]) 1339 AC_MSG_RESULT([$with_ping6_command])
1256 1340
1257 elif $PATH_TO_PING -A inet6 -n ::1 -c 1 2>/dev/null | \ 1341 elif $PATH_TO_PING -A inet6 -n ::1 -c 1 2>/dev/null | \
1258 egrep -i "^round-trip|^rtt" >/dev/null 1342 grep -E -i "^round-trip|^rtt" >/dev/null
1259 then 1343 then
1260 with_ping6_command="$PATH_TO_PING -A inet6 -n %s -c %d" 1344 with_ping6_command="$PATH_TO_PING -A inet6 -n %s -c %d"
1261 AC_MSG_RESULT([$with_ping6_command]) 1345 AC_MSG_RESULT([$with_ping6_command])
1262 1346
1263 elif $PATH_TO_PING -A inet6 ::1 -n 1 2>/dev/null | \ 1347 elif $PATH_TO_PING -A inet6 ::1 -n 1 2>/dev/null | \
1264 egrep -i "^round-trip|^rtt" >/dev/null 1348 grep -E -i "^round-trip|^rtt" >/dev/null
1265 then 1349 then
1266 with_ping6_command="$PATH_TO_PING -A inet6 %s -n %d" 1350 with_ping6_command="$PATH_TO_PING -A inet6 %s -n %d"
1267 AC_MSG_RESULT([$with_ping6_command]) 1351 AC_MSG_RESULT([$with_ping6_command])
1268 1352
1269 elif $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \ 1353 elif $PATH_TO_PING -A inet6 -n -s ::1 56 1 2>/dev/null | \
1270 egrep -i "^round-trip|^rtt" >/dev/null 1354 grep -E -i "^round-trip|^rtt" >/dev/null
1271 then 1355 then
1272 with_ping6_command="$PATH_TO_PING -A inet6 -n -s %s 56 %d" 1356 with_ping6_command="$PATH_TO_PING -A inet6 -n -s %s 56 %d"
1273 AC_MSG_RESULT([$with_ping6_command]) 1357 AC_MSG_RESULT([$with_ping6_command])
1274 1358
1275 elif $PATH_TO_PING -A inet6 -n -h ::1 -s 56 -c 1 2>/dev/null | \ 1359 elif $PATH_TO_PING -A inet6 -n -h ::1 -s 56 -c 1 2>/dev/null | \
1276 egrep -i "^round-trip|^rtt" >/dev/null 1360 grep -E -i "^round-trip|^rtt" >/dev/null
1277 then 1361 then
1278 with_ping6_command="$PATH_TO_PING -A inet6 -n -h %s -s 56 -c %d" 1362 with_ping6_command="$PATH_TO_PING -A inet6 -n -h %s -s 56 -c %d"
1279 AC_MSG_RESULT([$with_ping6_command]) 1363 AC_MSG_RESULT([$with_ping6_command])
1280 1364
1281 elif $PATH_TO_PING -A inet6 -n -s 56 -c 1 ::1 2>/dev/null | \ 1365 elif $PATH_TO_PING -A inet6 -n -s 56 -c 1 ::1 2>/dev/null | \
1282 egrep -i "^round-trip|^rtt" >/dev/null 1366 grep -E -i "^round-trip|^rtt" >/dev/null
1283 then 1367 then
1284 with_ping6_command="$PATH_TO_PING -A inet6 -n -s 56 -c %d %s" 1368 with_ping6_command="$PATH_TO_PING -A inet6 -n -s 56 -c %d %s"
1285 ac_cv_ping6_packets_first=yes 1369 ac_cv_ping6_packets_first=yes
1286 AC_MSG_RESULT([$with_ping_command]) 1370 AC_MSG_RESULT([$with_ping_command])
1287 1371
1288 elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \ 1372 elif $PATH_TO_PING -A inet6 -n -c 1 ::1 2>/dev/null | \
1289 egrep -i "^round-trip|^rtt" >/dev/null 1373 grep -E -i "^round-trip|^rtt" >/dev/null
1290 then 1374 then
1291 with_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s" 1375 with_ping6_command="$PATH_TO_PING -A inet6 -n -c %d %s"
1292 ac_cv_ping6_packets_first=yes 1376 ac_cv_ping6_packets_first=yes
@@ -1486,7 +1570,7 @@ if test -n "$PATH_TO_SUDO"
1486then 1570then
1487 AC_DEFINE_UNQUOTED(PATH_TO_SUDO,"$PATH_TO_SUDO",[path to sudo]) 1571 AC_DEFINE_UNQUOTED(PATH_TO_SUDO,"$PATH_TO_SUDO",[path to sudo])
1488else 1572else
1489 AC_MSG_WARN([Could not find sudo or eqivalent]) 1573 AC_MSG_WARN([Could not find sudo or equivalent])
1490fi 1574fi
1491 1575
1492AC_PATH_PROG(PATH_TO_MAILQ,mailq) 1576AC_PATH_PROG(PATH_TO_MAILQ,mailq)
@@ -1497,7 +1581,7 @@ if test -n "$PATH_TO_MAILQ"
1497then 1581then
1498 AC_DEFINE_UNQUOTED(PATH_TO_MAILQ,"$PATH_TO_MAILQ",[path to mailq]) 1582 AC_DEFINE_UNQUOTED(PATH_TO_MAILQ,"$PATH_TO_MAILQ",[path to mailq])
1499else 1583else
1500 AC_MSG_WARN([Could not find mailq or eqivalent]) 1584 AC_MSG_WARN([Could not find mailq or equivalent])
1501fi 1585fi
1502 1586
1503AC_PATH_PROG(PATH_TO_QMAIL_QSTAT,qmail-qstat) 1587AC_PATH_PROG(PATH_TO_QMAIL_QSTAT,qmail-qstat)
@@ -1508,7 +1592,7 @@ if test -n "$PATH_TO_QMAIL_QSTAT"
1508then 1592then
1509 AC_DEFINE_UNQUOTED(PATH_TO_QMAIL_QSTAT,"$PATH_TO_QMAIL_QSTAT",[path to qmail-qstat]) 1593 AC_DEFINE_UNQUOTED(PATH_TO_QMAIL_QSTAT,"$PATH_TO_QMAIL_QSTAT",[path to qmail-qstat])
1510else 1594else
1511 AC_MSG_WARN([Could not find qmail-qstat or eqivalent]) 1595 AC_MSG_WARN([Could not find qmail-qstat or equivalent])
1512fi 1596fi
1513 1597
1514dnl SWAP info required is amount allocated/available and amount free 1598dnl SWAP info required is amount allocated/available and amount free
@@ -1523,16 +1607,16 @@ then
1523 ac_cv_have_swap=yes 1607 ac_cv_have_swap=yes
1524 ac_cv_swap_command="$PATH_TO_SWAP -l" 1608 ac_cv_swap_command="$PATH_TO_SWAP -l"
1525 if [$PATH_TO_SWAP -l 2>/dev/null | \ 1609 if [$PATH_TO_SWAP -l 2>/dev/null | \
1526 egrep -i "^lswap +path +pri +swaplo +blocks +free +maxswap" \ 1610 grep -E -i "^lswap +path +pri +swaplo +blocks +free +maxswap" \
1527 >/dev/null] 1611 >/dev/null]
1528 then 1612 then
1529 ac_cv_swap_format=[" %*d %*s %*d,%*d %*d %*d %f %f"] 1613 ac_cv_swap_format=[" %*d %*s %*d,%*d %*d %*d %lu %lu"]
1530 ac_cv_swap_conv=2048 1614 ac_cv_swap_conv=2048
1531 AC_MSG_RESULT([using IRIX format swap]) 1615 AC_MSG_RESULT([using IRIX format swap])
1532 1616
1533 elif [$PATH_TO_SWAP -l 2>/dev/null | egrep -i "^path +dev +swaplo +blocks +free" >/dev/null] 1617 elif [$PATH_TO_SWAP -l 2>/dev/null | grep -E -i "^path +dev +swaplo +blocks +free" >/dev/null]
1534 then 1618 then
1535 ac_cv_swap_format=["%*s %*[0-9,-] %*d %f %f"] 1619 ac_cv_swap_format=["%*s %*[0-9,-] %*d %lu %lu"]
1536 ac_cv_swap_conv=2048 1620 ac_cv_swap_conv=2048
1537 AC_MSG_RESULT([using Unixware format swap]) 1621 AC_MSG_RESULT([using Unixware format swap])
1538 else 1622 else
@@ -1549,23 +1633,23 @@ AC_PATH_PROG(PATH_TO_SWAPINFO,swapinfo)
1549if (test -n "$PATH_TO_SWAPINFO") 1633if (test -n "$PATH_TO_SWAPINFO")
1550then 1634then
1551AC_MSG_CHECKING([for $PATH_TO_SWAPINFO format]) 1635AC_MSG_CHECKING([for $PATH_TO_SWAPINFO format])
1552if [$PATH_TO_SWAPINFO -k 2>&1 | egrep -i "^Device" >/dev/null] 1636if [$PATH_TO_SWAPINFO -k 2>&1 | grep -E -i "^Device" >/dev/null]
1553then 1637then
1554 ac_cv_have_swap=yes 1638 ac_cv_have_swap=yes
1555 ac_cv_swap_command="$PATH_TO_SWAPINFO -k" 1639 ac_cv_swap_command="$PATH_TO_SWAPINFO -k"
1556 1640
1557 if [$PATH_TO_SWAPINFO -k 2>/dev/null | egrep -i "^Device +1K-blocks +Used +Avail" >/dev/null] 1641 if [$PATH_TO_SWAPINFO -k 2>/dev/null | grep -E -i "^Device +1K-blocks +Used +Avail" >/dev/null]
1558 then 1642 then
1559 ac_cv_swap_format=["%*s %f %*d %f"] 1643 ac_cv_swap_format=["%*s %lu %*d %lu"]
1560 ac_cv_swap_conv=1024 1644 ac_cv_swap_conv=1024
1561 AC_MSG_RESULT([using FreeBSD format swapinfo]) 1645 AC_MSG_RESULT([using FreeBSD format swapinfo])
1562 fi 1646 fi
1563 1647
1564elif [$PATH_TO_SWAPINFO -dfM 2>/dev/null | egrep -i "^TYPE +AVAIL +USED +FREE" >/dev/null] 1648elif [$PATH_TO_SWAPINFO -dfM 2>/dev/null | grep -E -i "^TYPE +AVAIL +USED +FREE" >/dev/null]
1565then 1649then
1566 ac_cv_have_swap=yes 1650 ac_cv_have_swap=yes
1567 ac_cv_swap_command="$PATH_TO_SWAPINFO -dfM" 1651 ac_cv_swap_command="$PATH_TO_SWAPINFO -dfM"
1568 ac_cv_swap_format=["%*s %f %*d %f"] 1652 ac_cv_swap_format=["%*s %lu %*d %lu"]
1569 ac_cv_swap_conv=1024 1653 ac_cv_swap_conv=1024
1570 AC_MSG_RESULT([using HP-UX format swapinfo]) 1654 AC_MSG_RESULT([using HP-UX format swapinfo])
1571fi 1655fi
@@ -1576,11 +1660,11 @@ AC_PATH_PROG(PATH_TO_LSPS,lsps)
1576if (test -n "$PATH_TO_LSPS") 1660if (test -n "$PATH_TO_LSPS")
1577then 1661then
1578AC_MSG_CHECKING([for $PATH_TO_LSPS format]) 1662AC_MSG_CHECKING([for $PATH_TO_LSPS format])
1579if [$PATH_TO_LSPS -a 2>/dev/null | egrep -i "^Page Space" > /dev/null] 1663if [$PATH_TO_LSPS -a 2>/dev/null | grep -E -i "^Page Space" > /dev/null]
1580then 1664then
1581 ac_cv_have_swap=yes 1665 ac_cv_have_swap=yes
1582 ac_cv_swap_command="$PATH_TO_LSPS -a" 1666 ac_cv_swap_command="$PATH_TO_LSPS -a"
1583 ac_cv_swap_format=["%*s %*s %*s %f%*s %f %*s"] 1667 ac_cv_swap_format=["%*s %*s %*s %lu%*s %lu %*s"]
1584 ac_cv_swap_conv=1 1668 ac_cv_swap_conv=1
1585 AC_MSG_RESULT([using AIX lsps]) 1669 AC_MSG_RESULT([using AIX lsps])
1586fi 1670fi
@@ -1766,7 +1850,7 @@ AM_GNU_GETTEXT([external], [need-ngettext])
1766AM_GNU_GETTEXT_VERSION(0.15) 1850AM_GNU_GETTEXT_VERSION(0.15)
1767 1851
1768dnl Check for Redhat spopen problem 1852dnl Check for Redhat spopen problem
1769dnl Wierd problem where ECHILD is returned from a wait call in error 1853dnl Weird problem where ECHILD is returned from a wait call in error
1770dnl Only appears to affect nslookup and dig calls. Only affects redhat around 1854dnl Only appears to affect nslookup and dig calls. Only affects redhat around
1771dnl 2.6.9-11 (okay in 2.6.9-5). Redhat investigating root cause 1855dnl 2.6.9-11 (okay in 2.6.9-5). Redhat investigating root cause
1772dnl We patch plugins/popen.c 1856dnl We patch plugins/popen.c
@@ -1778,7 +1862,7 @@ AC_ARG_ENABLE(redhat-pthread-workaround,
1778 [ac_cv_enable_redhat_pthread_workaround=$enableval], 1862 [ac_cv_enable_redhat_pthread_workaround=$enableval],
1779 [ac_cv_enable_redhat_pthread_workaround=test]) 1863 [ac_cv_enable_redhat_pthread_workaround=test])
1780if test "$ac_cv_enable_redhat_pthread_workaround" = "test" ; then 1864if test "$ac_cv_enable_redhat_pthread_workaround" = "test" ; then
1781 if echo $ac_cv_uname_r | egrep "\.EL(smp)?$" >/dev/null 2>&1 ; then 1865 if echo $ac_cv_uname_r | grep -E "\.EL(smp)?$" >/dev/null 2>&1 ; then
1782 AC_MSG_NOTICE([See https://www.monitoring-plugins.org/doc/faq/configure-hangs.html if this next part takes a long time]) 1866 AC_MSG_NOTICE([See https://www.monitoring-plugins.org/doc/faq/configure-hangs.html if this next part takes a long time])
1783 AC_MSG_CHECKING(for redhat spopen problem) 1867 AC_MSG_CHECKING(for redhat spopen problem)
1784 ( cd config_test && make && make test ) > /dev/null 2>&1 1868 ( cd config_test && make && make test ) > /dev/null 2>&1
@@ -1875,4 +1959,5 @@ ACX_FEATURE([enable],[perl-modules])
1875ACX_FEATURE([with],[cgiurl]) 1959ACX_FEATURE([with],[cgiurl])
1876ACX_FEATURE([with],[trusted-path]) 1960ACX_FEATURE([with],[trusted-path])
1877ACX_FEATURE([enable],[libtap]) 1961ACX_FEATURE([enable],[libtap])
1878 1962ACX_FEATURE([with],[libcurl])
1963ACX_FEATURE([with],[uriparser])