aboutsummaryrefslogtreecommitdiffstats
path: root/tools/switch_wireshark_fedora.sh
blob: c22a669f930b53a3631bbba7f9a80e6e68bf7e3a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/bin/sh

wirsrc="$HOME/src/wireshark/"
wirpkg="wireshark wireshark-devel wireshark-gnome"

if [ $# -lt 1 ]; then
  echo "usage: `basename $0` svn|pkg"
  exit 1
fi

set -x

if [ $1 == "svn" ]; then
  sudo yum remove $wirpkg
  cd $wirsrc
  make -j 4
  sudo make install
elif [ $1 == "pkg" ]; then
  cd $wirsrc
  sudo make uninstall
  sudo yum install $wirpkg
  sudo usermod -a -G wireshark `whoami`
fi