# Wireshark 4.4.5
# ===============
# Wireshark was formerly known as Ethereal. See the FAQ if you're curious
# about the name change:
# http://www.wireshark.org/faq.html
#
# If you have Ethereal installed, go to the bottom of my Ethereal howto for
# uninstallation instructions before you install Wireshark.
# User-install Ruby gem Asciidoctor
# (frowned upon, but you could also install system-wide as root)
# https://asciidoctor.org/
gem install --user-install asciidoctor
# Get the Wireshark tarball
cd
test -f installed/wireshark-4.4.5.tar.xz &&
mv installed/wireshark-4.4.5.tar.xz .
test ! -f wireshark-4.4.5.tar.xz &&
wget https://2.na.dl.wireshark.org/src/wireshark-4.4.5.tar.xz
# Only build 'tshark', do not build 'wireshark'
# -DBUILD_wireshark=OFF
# If you want man pages and installed Asciidoctor as your user, rather
# than system-wide, specify the path to it like so
# -DASCIIDOCTOR_EXECUTABLE=~/.local/share/gem/ruby/3.4.0/bin/asciidoctor
# You may or may not want to clean up old files here
# /usr/bin/
# capinfos captype dumpcap editcap idl2wrs mergecap randpkt
# rawshark reordercap sharkd text2pcap tshark wireshark
# /usr/doc/wireshark/
# /usr/lib*/wireshark/
# /usr/lib*/lib{wireshark,wiretap,swutil}.*
# /usr/man/man[14]/
# /usr/share/wireshark/
# Install it
make install
ldconfig
# View what was installed and where
cat install_manifest.txt | sort | less
# List available man pages
ls -1 doc/man_pages/*.[14] | cut -d'/' -f3 | cut -d'.' -f1
# Make sure your non-root user can remove the source later
chown -R $(logname) .
chmod -R u+w .
# Become yourself again
exit
# Save the tarball for later
cd
mkdir -p -m 0700 installed
rm -f installed/wireshark-*.tar.*
mv wireshark-4.4.5.tar.xz installed/
# ~/src/wireshark-4.4.5/resources/ for icons for the GUI wireshark
# If you ever want to uninstall Wireshark, this should do it:
cd
su
test -d src/wireshark-* && ( cd src/wireshark-* ; make uninstall )
for pfx in /usr /usr/local; do
( cd ${pfx}/bin ; rm -f capinfos dftest dumpcap editcap \
idl2wrs mergecap randpkt text2pcap tshark wireshark )
( cd ${pfx}/lib ; rm -f libwireshark.* libwiretap.* )
test -d ${pfx}/lib/wireshark && rm -r ${pfx}/lib/wireshark
test -d ${pfx}/lib64 &&
( cd ${pfx}/lib64
rm -f libwireshark.* libwiretap.*
test -d ./wireshark && rm -r ./wireshark )
( cd ${pfx}/man/man1 ; rm -f capinfos.1 dumpcap.1 editcap.1 \
idl2wrs.1 mergecap.1 tshark.1 text2pcap.1 wireshark.1 )
rm -f ${pfx}/man/man4/wireshark-filter.4
test -d ${pfx}/share/wireshark && rm -r ${pfx}/share/wireshark
done
ldconfig
exit
find ~/src -maxdepth 1 -type d -name "wireshark-*" -exec rm -r {} \;
rm -f ~/installed/wireshark-*.tar.*