Skip to content

Commit 4a3d448

Browse files
committed
autoconf: tweaks to the check for --static-pcap-only support.
Use the -s and -q flags to suppress output from grep, rather than directing the standard output and error to /dev/null; they've been in the Single UNIX Specification since at least UNIX 98. Wrap "Checking..." and result messages around the test.
1 parent da482a1 commit 4a3d448

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

aclocal.m4

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -657,10 +657,13 @@ AC_DEFUN(AC_LBL_LIBPCAP,
657657
# statically linked, and provide only the direct
658658
# dependencies with --static-pcap-only.
659659
#
660-
if grep "static-pcap-only" "$PCAP_CONFIG" >/dev/null 2>&1
660+
AC_MSG_CHECKING([whether $PCAP_CONFIG supports --static-pcap-only])
661+
if grep -s -q "static-pcap-only" "$PCAP_CONFIG"
661662
then
663+
AC_MSG_RESULT([yes])
662664
static_opt="--static-pcap-only"
663665
else
666+
AC_MSG_RESULT([no])
664667
static_opt="--static"
665668
fi
666669
$2="-I$local_pcap_dir $$2"

0 commit comments

Comments
 (0)