libnids libpcap libnet 安装中的错误解决方案(mark)

安装libpcap出现:

1:error: Your operating system's lex is insufficient to compile libpcap. ex is a lex replacement that has many advantages, including being able to compile libpcap.
需要更新lex  ,执行命令:sudo apt-get install flex

2:出现错误
yacc -d grammar.y
make: yacc:命令未找到
make: *** [grammar.c] 错误 127
需要安装yacc
inux下是用flex和bison来分别代替lex和yacc的,安装直接使用命令:
sudo apt-get install bison

*************************************

安装libnet:
1:error: C++ preprocessor "/lib/cpp" fails sanity check
安装 g++ 编译器 (一款linux、unix等操作系统下的C++编译器
使用命令:sudo apt-get install g++

可能出现libnet的版本不符合要求

***************************************
安装libnids:
1:checking for GLIB... configure: error: Package requirements (glib-2.0 >= 2.2.0) were not met.

直接安装命令:sudo apt-get install "libglib2.0-dev"

编译程序是发生错误:
undefined reference to `pcap_parse'
不知道是什么原因说没有安装libpcap.

直接安装apt-get
sudo apt-get install libpcap-dev
sudo apt-get install libnids-dev
sudo apt-get install libnet1-dev

编译获取http的程序时发现无法截取无线网络的数据包。

传送门:http://hi.baidu.com/jiaoyuyang/blog/item/3e0cf4f1412c9aa3a40f5238.html/cmtid/deb24cee71ee4a38adafd572

原文链接: https://www.cnblogs.com/henzhi/archive/2011/10/21/13493407.html

欢迎关注

微信关注下方公众号,第一时间获取干货硬货;公众号内回复【pdf】免费获取数百本计算机经典书籍

    libnids libpcap libnet 安装中的错误解决方案(mark)

原创文章受到原创版权保护。转载请注明出处:https://www.ccppcoding.com/archives/34798

非原创文章文中已经注明原地址,如有侵权,联系删除

关注公众号【高性能架构探索】,第一时间获取最新文章

转载文章受原作者版权保护。转载请注明原作者出处!

(0)
上一篇 2023年2月8日 上午11:41
下一篇 2023年2月8日 上午11:42

相关推荐