Mac Homebrew and Wireshark

74

14

I've installed Wireshark(.org) using Homebrew.

brew install wireshark

at the end the script says

==> ./configure --prefix=/usr/local/Cellar/wireshark/1.2.7 --disable-dependency-tracking --disable-wireshark
==> make
==> make install
==> Caveats
We don't build the X11 enabled GUI by default
==> Summary
/usr/local/Cellar/wireshark/1.2.7: 167 files, 50M, built in 5.4 minutes

I'm not able to find the 'wireshark' GUI.
Any idea of how to build it?

Thanks

miku8

Posted 2010-05-29T13:46:37.960

Reputation: 841

Answers

106

$ brew options wireshark

Shows you options for wireshark, which lists --with-qt5. QT is the GUI toolkit that Wireshark uses since 1.10. Thus, install wireshark using the following command:

$ brew install wireshark --with-qt5

Or if you already have wireshark previosly:

$ brew reinstall wireshark --with-qt5

If you do not add this option the commandline tool tshark will be installed.

jonchang

Posted 2010-05-29T13:46:37.960

Reputation: 1 246

15First time I've ever had a formula not install by default. It would be better if there was a --without-gui instead of blindly continuing without any GUI which most who install wireshark are probably expecting. – Sukima – 2014-08-06T16:44:31.260

@hanxue how do I run it after installing it? – Zoltán – 2015-09-03T14:15:03.143

I used the reinstall command, but to make it work I had to re-create the symlinks as explained in this github issue:

rm '/usr/local/bin/wireshark' && brew link --overwrite wireshark

– subelsky – 2016-07-11T20:19:13.093

Just thought I'd add it appears the recommended option is now --with-qt5. I received this warning when trying as defined above: Warning: wireshark: --with-qt was deprecated; using --with-qt5 instead! – Slump – 2016-09-06T17:03:24.637

8Note that beginning with Wireshark 1.10.0 QT is used instead of GTK. So you can use the option --with-qt – hanxue – 2013-10-21T15:00:40.317

8brew reinstall wireshark --with-qt – Louis – 2014-05-17T12:56:18.893

9

The new approach is to use brew install wireshark --with-qt.

The --with-x option no longer works.

More details on the switch to QT: https://blog.wireshark.org/2013/10/switching-to-qt/

Paul Wenzel

Posted 2010-05-29T13:46:37.960

Reputation: 191

4

Well, the system did warn you that it wouldn't install the X11 GUI. So maybe there is an option in the configuration phase that enables it? You'd need a whole extra set of stuff to run X11.

At http://www.wireshark.org/download.html there is a binary downstaller you could use...

Henno

Posted 2010-05-29T13:46:37.960

Reputation: 639

Thanks for your response. I've X11, I just don't understand what I'm missing. I should build wireshark gui in some way I suppose... no mention of how to do it with homebrew. this is the script 'http://github.com/mxcl/homebrew/blob/master/Library/Formula/wireshark.rb' sorry I'm newbie

– miku8 – 2010-05-29T14:58:57.630

Do it without the --disable-wireshark in the script. So edit the script... Maybe you'll get a problem with dependencies as well, so you could remove the --disable-dependency-tracking as well, but then of course you could get errors as well.... You do know that at the wireshark site there is a complete binary build of wireshark, installer and all ? That's a lot easier. – Henno – 2010-05-29T17:53:28.080

3

There is a Mac .dmg app installer from the http://www.wireshark.org website. You must wait a while for it to start X11. It will seem as though it is not working, but the app is just very slow.

Elaine Morrison

Posted 2010-05-29T13:46:37.960

Reputation: 31

Direct link: https://1.na.dl.wireshark.org/osx/Wireshark%203.0.6%20Intel%2064.dmg

– user674669 – 2019-11-14T12:52:38.423

2

At some point, a cask formula was added. So the following command will actually install Wireshark, with the UI, as a regular app:

brew cask install wireshark

And you can then find it in Applications or via Spotlight.

mherzig

Posted 2010-05-29T13:46:37.960

Reputation: 121

1

You appear to have disabled the building of the GUI with the --disable-wireshark option to the configure script .

You need to clean up from the previous build, run configure without the --disable-wireshark and then rebuild.

Unfortunately I can't help you do this on your OS as I have no knowledge of it.

user35787

Posted 2010-05-29T13:46:37.960

Reputation:

1

My reputation is too low to comment on @jonchang's answer, and I realize that this is old, but in case others find this...

brew install wireshark --with-qt

as indicated in @jonchang's answer worked for me (use brew reinstall wireshark --with-qt, as mentioned by @Louis if you've already installed wireshark without qt).

As for running it, it doesn't install an OS X application, but you should then be able to run qt from the command line:

/usr/local/Cellar/wireshark/{{version}}/bin/wireshark-qt

Tyler Stevens

Posted 2010-05-29T13:46:37.960

Reputation: 11