Wireshark-dev: Re: [Wireshark-dev] How to build wireshark on Windows 8.1 with Visual Studio 201

From: Graham Bloice <graham.bloice@xxxxxxxxxxxxx>
Date: Tue, 10 Jun 2014 10:11:53 +0100
On 10 June 2014 09:23, Joerg Mayer <jmayer@xxxxxxxxx> wrote:
Hello Giorgio,

On Tue, Jun 10, 2014 at 10:00:47AM +0200, Giorgio Buffa wrote:
> I would like to develop a dissector, from the current stable release
> (1.10.7). Is it possible to build wireshark using Microsoft Visual Studio
> Express 2013 for Windows Desktop, on Windows 8.1?
>
> I was not able to find a step-by step guide for this. Do you have any
> pointers/suggestion for this?

https://www.wireshark.org/docs/wsdg_html_chunked/
or
ftp://ftp.wireshark.org/docs

Btw, if you start development now, you may want to consider developing
for 1.12 which is close to release although it looks like we do not yet
have packages on ftp.wireshark.org for it.


I have built (an x86 version) Wireshark from the current master (obtained via git) using VS2013 Pro, not Express but I believe it should work.  You must use the "Desktop" editions of Express.

Some slight modifications from the Developers Guide mentioned by Joerg above:
  1. Start with a nice clean unmodified copy of the sources first.
  2. Download an appropriate version of QT for use with VS2013, I used http://download.qt-project.org/official_releases/qt/5.3/5.3.0/qt-opensource-windows-x86-msvc2013-5.3.0.exe, install it and find and locate the path to the bin directory.
  3. You must obtain a copy of win32.mak either from an older SDK or older version of VS and copy it into C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include
  4. From the Start Menu (or Screen for Win 8+) open a Visual studio Command prompt for the type of build you are making (x86 or x64).
  5. Set the following environment variables adjusting the paths as required.  Note that WIRESHARK_BASE_DIR is the parent directory for your git source tree and QT5_BASE_DIR is the parent directory for the QT bin directory:
    1. set CYGWIN=nodosfilewarning
    2. set WIRESHARK_BASE_DIR=E:\Wireshark
    3. set WIRESHARK_TARGET_PLATFORM=win32
    4. set QT5_BASE_DIR=C:\Qt\Qt5.3.0\5.3\msvc2013
  6. Did I mention no modified sources?  Now follow the dev guide to install the libraries, and then build.
  7. QT requires some other DLL's to run, I used the windeployqt tool from the QT bin directory to handle this.  cd from the top of your source tree into wireshark-qt-release, then execute path\to\windeployqt --release qtshark.exe.
Any installer built may not install all the required DLL's for QT, that's still a work in progress at the moment.

--
Graham Bloice