1
0
mirror of https://github.com/nmap/nmap.git synced 2026-02-01 19:19:09 +00:00

With --with-libpcap=included, link driectly against libpcap/libpcap.a instead

of adding -Llibpcap/ -lpcap to LDFLAGS. The latter, at least on OS X, still
links dynamically against the system installation of libpcap. This is
consistent with how --with-libpcre=included works.
This commit is contained in:
david
2010-04-19 20:09:58 +00:00
parent 89ea71e792
commit a2b7e309ce
2 changed files with 23 additions and 31 deletions

View File

@@ -390,25 +390,25 @@ int main() {
LIBS="$LIBS_OLD"
fi
LIBPCAP_LIBS="-lpcap"
if test $have_libpcap = yes; then
PCAP_DEPENDS=""
PCAP_BUILD=""
PCAP_CLEAN=""
PCAP_DIST_CLEAN=""
AC_DEFINE(HAVE_LIBPCAP)
else
if test $have_libpcap != yes; then
AC_CONFIG_SUBDIRS(libpcap)
if test "${LIBPCAP_INC+set}" = "set"; then
LDFLAGS="-L$libpcapdir $_ldflags"
CPPFLAGS="$CPPFLAGS -I$LIBPCAP_INC"
else
LDFLAGS="-L$libpcapdir $LDFLAGS"
CPPFLAGS="$CPPFLAGS -I$libpcapdir"
fi
LIBPCAP_LIBS='$(LIBPCAPDIR)/libpcap.a'
PCAP_DEPENDS='$(LIBPCAPDIR)/libpcap.a'
PCAP_BUILD="pcap_build"
PCAP_CLEAN="pcap_clean"
PCAP_DIST_CLEAN="pcap_dist_clean"
else
AC_DEFINE(HAVE_LIBPCAP)
LIBPCAP_LIBS="-lpcap"
PCAP_DEPENDS=""
PCAP_BUILD=""
PCAP_CLEAN=""
PCAP_DIST_CLEAN=""
fi
AC_SUBST(PCAP_DEPENDS)
@@ -417,10 +417,6 @@ AC_SUBST(PCAP_CLEAN)
AC_SUBST(PCAP_DIST_CLEAN)
AC_SUBST(LIBPCAP_LIBS)
if test $have_libpcap != yes ; then
AC_CONFIG_SUBDIRS(libpcap)
fi
have_pcre=no
requested_included_pcre=no
LIBPCREDIR=libpcre