Fix the CMake WinPcap library path check.

Look for wpcap.lib in WpdPack/Lib/x64 when our target platform is Win64.

Change-Id: I9a1bac22106bcb6a1f155ce83c02e344e6ec0d55
Reviewed-on: https://code.wireshark.org/review/3331
Reviewed-by: Gerald Combs <gerald@wireshark.org>
This commit is contained in:
Gerald Combs 2014-08-01 11:25:08 -07:00
parent fbc1a9af14
commit fb526204f8
1 changed files with 7 additions and 1 deletions

View File

@ -9,6 +9,12 @@
include( FindWSWinLibs )
FindWSWinLibs( "WpdPack" "PCAP_HINTS" )
# The 64-bit wpcap.lib is under /x64
set ( _PLATFORM_SUBDIR "" )
if( WIN32 AND $ENV{WIRESHARK_TARGET_PLATFORM} MATCHES "64" )
set ( _PLATFORM_SUBDIR "/x64" )
endif()
find_path( PCAP_INCLUDE_DIR
NAMES
pcap/pcap.h
@ -22,7 +28,7 @@ find_library( PCAP_LIBRARY
pcap
wpcap
HINTS
"${PCAP_HINTS}/lib"
"${PCAP_HINTS}/lib${_PLATFORM_SUBDIR}"
)