【wireshark】fedora 或者ubuntu 源码编译安装wireshark1.70

由于担心直接用yum下载wireshark不是最新版本,而是稳定版本,这样可能不能解析我需要的BT-DHT包,所以直接从wireshark官网下载了wireshark1.70源码安装:


操作系统版本:fedora14

由于ubuntu使用的人很多,也给出他的解决方法


安装步骤:

1.在官网下载最新版本的wireshark1.70

http://www.wireshark.org/download.html

选择sourcecode源码下载

【wireshark】fedora 或者ubuntu 源码编译安装wireshark1.70_第1张图片


2.下载后得到文件wireshark-1.7.0.tar.bz2

将它解压并进入源文件目录编译安装:

$tar -xvf wireshark-1.7.0.tar.bz2 $cd wireshark-1.7.0 $./configure $make $sudo make install



我在编译中遇到的问题:

问题1:configure: error:checking for perl… /usr/bin/perl checking for bison… no checking for byacc… no checking for yacc… no configure: error: I couldn’t find yacc (or bison or …); make sure it’s installed and in your path

问题原因:我们没有安装flex和bison

fedora解决办法: sudo yum install flex bison

ubuntu解决方法:sudo apt-get install flex bison


问题2:configure: error: GTK+ 2.12 or later isn't available, so Wireshark can't be compiled

问题原因:我们没有安装GTK+的开发文件和GLib库

fedora解决办法:sudo yum install gtk2-devel glib2-devel

ubuntu解决方法:sudo apt-get install libgtk2.0-dev libglib2.0-dev

这里要注意,这个地方的处理方法和ubuntu当中不同,fedora自己将gtk+2.12改名为gtk2了,所以我们要安装gtk2-devel glib2-devel

如果你在fedora中使用sudo yum install libgtk2.0-dev libglib2.0-dev这个命令,会提示:

No package libgtk2.0-dev available.
No package libglib2.0-dev available.

错误:无须任何处理


问题3:

configure: error: Header file pcap.h not found; if you installed libpcap from source, did you also do "make install-incl", and if you installed a binary package of libpcap, is there also a developer's package of libpcap,and did you also install that package?

问题原因:因为我们没有安装libpcap

解决方法:

1.先到http://www.tcpdump.org/#latest-release下载libpcap


2.下载后得到文件libpcap-1.2.1.tar.gz

解压该文件并进入目录

$tar -xvf libpcap-1.2.1.tar.gz $cd libpcap-1.2.1 $./configure $make $sudo make install
 
   
 

 

你可能感兴趣的:(Flex,ubuntu,header,perl,gtk,yacc)