We have messages for pkg-config and for the old-fashioned search; print
a message if pkg-config failed but we found pcap-config.
Fix the suppression of messages with a QUIET argument.
# libpcap isn't available - not all systems ship pkg-config, and
# libpcap didn't have .pc files until libpcap 1.9.0.
#
- if(PCAP_FIND_QUIET)
+ if(PCAP_FIND_QUIETLY)
set(_quiet "QUIET")
endif()
# First, try pkg-config.
#
find_package(PkgConfig)
- pkg_search_module(CONFIG_PCAP ${QUIET} libpcap)
+ pkg_search_module(CONFIG_PCAP ${_quiet} libpcap)
if(NOT CONFIG_PCAP_FOUND)
#
if(PCAP_CONFIG)
#
# We have pcap-config; use it.
+ #
+ if(NOT "${_quiet}" STREQUAL "QUIET")
+ message(STATUS "Found pcap-config")
+ endif()
+
#
# if this is macOS or some other Darwin-based OS, check whether
# it's the system-supplied one.