diff options
| -rw-r--r-- | configure.ac | 25 |
1 files changed, 17 insertions, 8 deletions
diff --git a/configure.ac b/configure.ac index e8ab77f0..204fc6e3 100644 --- a/configure.ac +++ b/configure.ac | |||
| @@ -1460,20 +1460,29 @@ AC_ARG_WITH(snmpget_command, | |||
| 1460 | ACX_HELP_STRING([--with-snmpget-command=PATH], | 1460 | ACX_HELP_STRING([--with-snmpget-command=PATH], |
| 1461 | [Path to snmpget command]), | 1461 | [Path to snmpget command]), |
| 1462 | PATH_TO_SNMPGET=$withval) | 1462 | PATH_TO_SNMPGET=$withval) |
| 1463 | AS_IF([test -n "$PATH_TO_SNMPGET"], [ | ||
| 1464 | AC_DEFINE_UNQUOTED(PATH_TO_SNMPGET,"$PATH_TO_SNMPGET",[path to snmpget binary]) | ||
| 1465 | EXTRAS="$EXTRAS check_hpjd check_snmp\$(EXEEXT)" | ||
| 1466 | ], [ | ||
| 1467 | AC_MSG_WARN([Get snmpget from https://net-snmp.sourceforge.io/ to make check_hpjd and check_snmp plugins]) | ||
| 1468 | ]) | ||
| 1469 | 1463 | ||
| 1470 | AC_PATH_PROG(PATH_TO_SNMPGETNEXT,snmpgetnext) | 1464 | AC_PATH_PROG(PATH_TO_SNMPGETNEXT,snmpgetnext) |
| 1471 | AC_ARG_WITH(snmpgetnext_command, | 1465 | AC_ARG_WITH(snmpgetnext_command, |
| 1472 | ACX_HELP_STRING([--with-snmpgetnext-command=PATH], | 1466 | ACX_HELP_STRING([--with-snmpgetnext-command=PATH], |
| 1473 | [Path to snmpgetnext command]), | 1467 | [Path to snmpgetnext command]), |
| 1474 | PATH_TO_SNMPGETNEXT=$withval) | 1468 | PATH_TO_SNMPGETNEXT=$withval) |
| 1475 | AS_IF([test -n "$PATH_TO_SNMPGETNEXT"], [ | 1469 | |
| 1476 | AC_DEFINE_UNQUOTED(PATH_TO_SNMPGETNEXT,"$PATH_TO_SNMPGETNEXT",[path to snmpgetnext binary]) | 1470 | AS_IF([test -n "$PATH_TO_SNMPGET"], [ |
| 1471 | AC_DEFINE_UNQUOTED(PATH_TO_SNMPGET,"$PATH_TO_SNMPGET",[path to snmpget binary]) | ||
| 1472 | EXTRAS="$EXTRAS check_hpjd" | ||
| 1473 | |||
| 1474 | dnl PATH_TO_SNMPGETNEXT is used unconditionally in check_snmp: | ||
| 1475 | dnl | ||
| 1476 | dnl https://github.com/nagios-plugins/nagios-plugins/issues/788 | ||
| 1477 | dnl | ||
| 1478 | AS_IF([test -n "$PATH_TO_SNMPGETNEXT"], [ | ||
| 1479 | AC_DEFINE_UNQUOTED(PATH_TO_SNMPGETNEXT,"$PATH_TO_SNMPGETNEXT",[path to snmpgetnext binary]) | ||
| 1480 | EXTRAS="$EXTRAS check_snmp\$(EXEEXT)" | ||
| 1481 | ], [ | ||
| 1482 | AC_MSG_WARN([Get snmpgetnext from https://net-snmp.sourceforge.io/ to build the check_snmp plugin]) | ||
| 1483 | ]) | ||
| 1484 | ], [ | ||
| 1485 | AC_MSG_WARN([Get snmpget from https://net-snmp.sourceforge.io/ to build the check_hpjd and check_snmp plugins]) | ||
| 1477 | ]) | 1486 | ]) |
| 1478 | 1487 | ||
| 1479 | if ( $PERL -M"Net::SNMP 3.6" -e 'exit' 2>/dev/null ) | 1488 | if ( $PERL -M"Net::SNMP 3.6" -e 'exit' 2>/dev/null ) |
