libpcap
1.1、libpcap简介
是什么 ?:Packet(TCP/IP) Capture libray
开发语言:C
官方主页:http://www.tcpdump.org
源码仓库:https://github.com/the-tcpdump-group/libpcap
used by:TCPDumpwireshark
1.2、通过包管理器安装libpcap
操作系统包管理器安装命令
macOSHomeBrewbrew install libpcap
GNU/LinuxLinuxBrewbrew install libpcap
aptsudo apt-get install -y libpcap0.8 libpcap-dev
CentOSyumsudo yum install -y libpcap libpcap-devel
dnfsudo dnf install -y libpcap libpcap-devel
openSUSEzyppersudo zypper install -y libpcap1 libpcap-devel
Alpine Linuxapksudo apk add libpcap libpcap-dev

Arch Linux

ArcoLinux

Manjaro Linux

pacmansudo pacman -Syyu --noconfirm
sudo pacman -S    --noconfirm libpcap
1.3、通过编译源码安装libpcap
1.4、libpcap中包含的头文件
1.5、libpcap中包含的库文件
  • libpcap.{a | so | dylib}