Commit Graph

927 Commits

Author SHA1 Message Date
Guy Harris bce5ec919e Use the new cfile_XXX_failure_message() routines more broadly.
Change-Id: I7814b3fd0353f4836ae61cbdbd4e13f659cbcb59
Reviewed-on: https://code.wireshark.org/review/21239
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-20 07:19:41 +00:00
Guy Harris b0c48f3b4f editcap now uses stuff from libui.
Change-Id: Ifa5cda67305682909559963ea5ce90cecc0c8e6e
Reviewed-on: https://code.wireshark.org/review/21238
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-20 03:26:34 +00:00
Ahmad Fatoum cfab5ef035 Add libxml2 as optional dependency
This can be used by dissectors that need to parse out-of-band
configuration.

Change-Id: I13c0a2f408fb5c21bad7ab3d7971e0fa8ed7d783
Reviewed-on: https://code.wireshark.org/review/20912
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-04-19 10:41:55 +00:00
Jakub Zawadzki ca29ec9e77 sharkd: support for "downloading" decoded RTP stream in wave-like format.
Change-Id: Ic6b241f9b7ed302e7b11644e63230474d5933a85
Reviewed-on: https://code.wireshark.org/review/20963
Petri-Dish: Jakub Zawadzki <darkjames-ws@darkjames.pl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jakub Zawadzki <darkjames-ws@darkjames.pl>
2017-04-17 07:29:31 +00:00
Ahmad Fatoum e66f9c7b6d CMake: include PKG_INCLUDE_DIR if PKG_INCLUDE_DIRS is undefined
FindLibXml2.cmake populates LIBXML2_INCLUDE_DIR and leaves
LIBXML2_INCLUDE_DIRS undefined.

Libxml2 inclusion as optional dependency is suggested in Change-Id
I13c0a2f408fb5c21bad7ab3d7971e0fa8ed7d783.

Change-Id: If49c778230e99af4b2ebb97dcb2f8acb4b55aa88
Reviewed-on: https://code.wireshark.org/review/21109
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-04-15 15:37:28 +00:00
Joerg Mayer bf5fd112bc Functions that put large amounts of static data onto the stack may be
worth looking at every now and then.

The value of 16384 is the same as the default in VS.

Change-Id: I68fd51e373437088f59c1e197d1a889f856caded
Reviewed-on: https://code.wireshark.org/review/21030
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-04-14 11:29:31 +00:00
Alexis La Goutte c6fb9ee214 Add -Wduplicated-branches to extra warnings
Change-Id: I11d60b4405f4fde039affcdeebb13a3ceb2aded6
Reviewed-on: https://code.wireshark.org/review/20428
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-04-12 11:28:16 +00:00
Guy Harris 77cad8561c Move the filter file reading code to libui.
It doesn't belong in libwireshark, as it doesn't affect dissection, but
it *does* belong in libui, as it's helper code for the UIs.

Change-Id: I8a5e0640a299a08e9ec1917dd253197438ebfdbc
Reviewed-on: https://code.wireshark.org/review/20974
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-09 04:25:52 +00:00
Guy Harris a5fadc99ff Link dftest with libui.
No need to select one source file from libui and build it independently;
just go ahead and link.

Change-Id: I7ae5d8f9b83832518a4fb3430cb348e8c4d6b7ab
Reviewed-on: https://code.wireshark.org/review/20968
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-08 22:00:19 +00:00
Guy Harris 8f2b1bf9ca Link rawshark with libui.
No need to select one source file from libui and build it independently;
just go ahead and link.

Change-Id: Ie451b736411bcdac52ccde56f329c933a0065ead
Reviewed-on: https://code.wireshark.org/review/20967
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-08 21:44:36 +00:00
Guy Harris 357cfd3b03 A bunch of "{Mac} OS X" -> "macOS" changes.
Avoid anachronisms, however; there was no "macOS 10.0" or even "OS X
10.0", for example.  It was "Mac OS X" until 10.8 (although 10.7 was
sometimes called "OS X" and sometimes called "Mac OS X"), and it was "OS
X" from 10.8 to 10.11.

Change-Id: Ie4a848997dcc6c45c2245c1fb84ec526032375c3
Reviewed-on: https://code.wireshark.org/review/20933
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-04-05 19:16:22 +00:00
Martin Kaiser 1e5f39dfec cmake: add feature info for yapp
Explain what it is and where to get it from.

Change-Id: I0a02f1c3c25b76772dddda95d8e6c410b595c036
Reviewed-on: https://code.wireshark.org/review/20886
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-04-04 11:39:27 +00:00
Joerg Mayer 0b6b152694 Remove echld/.
It has been unsupported for some years and when talking about removing it
in the past I received some positive and no negative feedback.

There is one instance of echld left:
capchild/capture_sync.c:                 * echld might have already reaped the child.

Can that case be removed or should be comment be updated to something more
accurate? (left for a separate patch)

Change-Id: Idac397158dd86fd0728eb95379449ee4a463fc28
Reviewed-on: https://code.wireshark.org/review/20619
Petri-Dish: Jörg Mayer <jmayer@loplof.de>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-03-19 15:13:14 +00:00
Erik de Jong f1c75cf6ef Rewrite dissectors to use Libgcrypt functions.
As discussed on the mailinglist, rewriting dissectors to use Libgcrypt
functions as Libgcrypt will be mandatory after change 20030.
Removal of following functions:
- crypt_md4
- crypt_rc4*
- aes_cmac_encrypt_*
- md5_*
- sha1_*
- sha256_*

Further candidates:
- aes_*
- rijndael_*
- ...

Added functions:
- ws_hmac_buffer

Added const macros:
- HASH_MD5_LENGTH
- HASH_SHA1_LENGTH

Changes on epan/crypt/* verified with captures from
https://wiki.wireshark.org/HowToDecrypt802.11
Changes on packet-snmp.c and packet-radius.c verified with captures from
https://wiki.wireshark.org/SampleCapture
Changes on packet-tacacs.c verified with capture from
http://ccie-in-3-months.blogspot.nl/2009/04/decoding-login-credentials-regardless.html

Change-Id: Iea6ba2bf207cf0f1bf2117068fb1abcfeaafaa46
Link: https://www.wireshark.org/lists/wireshark-dev/201702/msg00011.html
Reviewed-on: https://code.wireshark.org/review/20095
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-03-02 23:58:05 +00:00
Roland Knall 321386e9f4 PluginIF: AdditionalToolbar
Creates an interface for plugins and other parts of the code, to
add a new toolbar to the system and have various widget types interact
with this toolbar.

All toolbars added via this interface, will be added to an additional
submenu called "Additional Toolbars" within Wireshark.

Also a demo plugin is being provided, demonstrating various features
of the toolbar, including updating the gui elements. It also demonstrates
how to update toolbar items.

Change-Id: I8d0351224b3d7f4b90220d58970b51695551d7e3
Reviewed-on: https://code.wireshark.org/review/19803
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2017-02-24 08:12:46 +00:00
Alexis La Goutte fdecfa6c30 cmake: Add some missing SET_FEATURE_INFO
for nghttp2, lz4, snappy

Change-Id: I0788c2105b69ba2ae781709fb5e16e13b5ca1533
Reviewed-on: https://code.wireshark.org/review/20200
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-02-21 05:40:59 +00:00
Alexis La Goutte 66e45419b1 cmake: SET_FEATURE_INFO don't need to add www: for URL
Change-Id: If01c008690dc1956b42d63d67942414063f3e76c
Reviewed-on: https://code.wireshark.org/review/20199
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-02-21 05:39:47 +00:00
Gerald Combs a5a8fce06e Qt: Warn the user about DBAR 1.8 on Windows.
At startup, dig through the registry looking for shell extensions. If
any of them match known Dell Backup and Recovery DLL names and the DLL
version matches 1.8.*.*, show the user a warning dialog.

This is a bit extreme but I'm not sure what else to do. Dell is a popular
computer manufacturer and bug reports keep trickling in.

Change-Id: I6d1bd6c56850279356570154d231b07facb30cff
Bug: 12036
Ping-bug: 12701
Ping-bug: 13414
Reviewed-on: https://code.wireshark.org/review/16861
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2017-02-16 16:58:12 +00:00
Peter Wu 6b84ddee83 Make Libgcrypt a mandatory dependency
Removed all guards for HAVE_LIBGCRYPT, change autotools and CMake to
error out if it is not available. Update release notes, developer
documentation and README with the new status. Clarify relation with
GnuTLS in macosx-setup.sh. Install Libgcrypt via brew script.

Motivation for this change is that many dissectors depend on Libgcrypt
and having it optional increases the maintenance burden (there have been
several compile issues in the past due to the optional status).
Furthermore, wsutil has crypto code that can be replaced by Libgcrypt.

Change-Id: Idf0021b8c4cd5db70b8766f7dcc2a8b3acbf042f
Link: https://www.wireshark.org/lists/wireshark-dev/201702/msg00011.html
Reviewed-on: https://code.wireshark.org/review/20030
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-02-13 18:35:47 +00:00
Peter Wu 53c7f0a25e CMake,autotools: remove unneeded files, fixes build
sharkd does not perform any capturing, so do not include related
libraries and files. This fixes the CMake build too.

Change-Id: Ie002b09dbf60070e34dacc8ae7dadee6690d4db8
Reviewed-on: https://code.wireshark.org/review/19786
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Tested-by: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-01-25 15:19:03 +00:00
Jakub Zawadzki e2930f3b78 Add sharkd - daemon variant
sharkd listens on UNIX socket and allows external clients
to run commands like: loading file, analysing frames or running TAP(s).

Change-Id: I443b2865e4adfd1c11f4f57d09ff7fce6b1e8766
Reviewed-on: https://code.wireshark.org/review/18208
Petri-Dish: Jakub Zawadzki <darkjames-ws@darkjames.pl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Jakub Zawadzki <darkjames-ws@darkjames.pl>
2017-01-25 07:19:05 +00:00
Peter Wu 37790e90f5 cmake: fix empty data (Global Configuration) directory
Color filters were somehow not loaded. It turns out that the
BUILD_TIME_DATAFILE_DIR macro (for filesystem.c) was empty because
DATAFILE_DIR was defined after adding the wsutil directory. Fix it by
defining the variable before wsutil (but after epan).

Change-Id: I0d002b79499c80a90d8fcc14b06ced26c30b0453
Fixes: v2.3.0rc0-1830-gd5fdbef7f4 ("cmake,wslua,wsutil: load files from run/ instead of source tree")
Reviewed-on: https://code.wireshark.org/review/19600
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2017-01-10 17:09:29 +00:00
Peter Wu 31872655ad CMake,autotools: enable -Werror=implicit by default
The -Wimplicit error covers two warnings, trying to catch these cases:

Setting a global variable without declaring its type (-Wimplicit-int):

    undeclared_type = 1;

More importantly, -Wimplicit-function-declaration catches the case where
a function is not declared (missing header, programming error, etc.).

Turn these warnings into errors, most likely it will be a programming
error that results in a link failure anyway. See also
https://fedoraproject.org/wiki/Changes/Fedora26CFlags

Also fix autotools checks not to trigger -Wimplicit-int and
-Wimplicit-function-declaration (in krb5 check due to missing include).
Tested on Ubuntu 16.04 (autotools & cmake) and Arch Linux (cmake),
configure/cmake output and config.h are identical.

Change-Id: I137284263f3b1223df6e6a893111c3640802631f
Reviewed-on: https://code.wireshark.org/review/19331
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-12-28 22:31:28 +00:00
Dario Lombardo 194433a503 udpdump: remove libwireshark dependancy.
Export pdu routines have been rewritten here on purpose.

Change-Id: If4879de4c98b6f20a75df158cae0cf9a80ffae57
Reviewed-on: https://code.wireshark.org/review/19384
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-25 03:33:01 +00:00
Pascal Quantin 693dcd276e Build TRANSUM plugin
Add plugin to autofoo and CMake build systems and fix errors found
Add plugin to Windows installer (optional component activated by default)

Change-Id: Id1b777bdee04e53076b3291f6fb68d5abad6985d
Reviewed-on: https://code.wireshark.org/review/19228
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-12-13 08:50:27 +00:00
Peter Wu f5e22a1487 codecs: Add support for G.722 and G.726
Integrate the Spandsp library for G.722 and G.726 support. Adds support
for G.722 and all eight variants of G.726.

Note: this also fixes a crash in Qt (buffer overrun, reading too much
data) caused by confusion of the larger output buffer (resample_buff)
with the smaller input buffer (decode_buff). It was not triggered before
because the sample rate was always 8k, but with the addition of the new
codecs, a different sample rate became possible (16k).

Fix also a crash which occurs when the RTP_STREAM_DEBUG macro is enabled
and the VOIP Calls dialog is opened (the begin frame, start_fd, is not
yet known and therfore a NULL dereference could occur).

Passes testing (plays normally without bad RTP timing errors) with
SampleCaptures files: sip-rtp-g722.pcap and sip-rtp-g726.pcap. Tested
with cmake (Qt), autotools (Qt and GTK+) with ASAN enabled.

Bug: 5619
Change-Id: I5661908d193927bba50901079119eeff0c04991f
Reviewed-on: https://code.wireshark.org/review/18939
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-12-06 17:51:47 +00:00
Peter Wu 83a1ab23ab cmake: Fix building with plugins disabled
When Lua is enabled, scripts can still be loaded from the plugin dir
(filesystem.c uses PLUGIN_INSTALL_DIR), so be sure to set it or the
cmake build fails.

Change-Id: I87d2d705434052220f9619438c90905c24b2a3a6
Reviewed-on: https://code.wireshark.org/review/18976
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-05 01:35:26 +00:00
Moshe Kaplan 20c57cb298 Enable exporting objects with tshark
A new "--export-object <protocol>,<destdir>" option is added to tshark.

This required refactoring Export Object behavior in all GUIs to give the
export object handling to the dissector, rather than the ui layer.
Included in the refactoring was fixing some serious memory leaks in Qt
Export Object dialog, crash due to memory scope issues in GTK Export
Object dialog, and addition sorting column feature in Qt dialog (set
up by creating a widget to manage the items that were previously
leaking memory)

Bug: 9319
Ping-Bug: 13174
Change-Id: I515d7662fa1f150f672b1476716f347ec27deb9b
Reviewed-on: https://code.wireshark.org/review/18927
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-12-02 16:07:35 +00:00
Роман Донченко 4ace7ce80d Fix the build when a different version of Qt is in PATH
When we add our Qt to PATH, prepend it so that it will be found first.

Change-Id: I405496d6a08d676b5a2e0d9bd792de7ba9abe7f9
Reviewed-on: https://code.wireshark.org/review/18988
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2016-11-30 11:44:41 +00:00
Peter Wu c274046556 cmake: install icons and .desktop files
Based on the install-data-local target from Makefile.am.

Change-Id: Ia2ff6b90475a30ed219019fd80afd1a498e3133c
Reviewed-on: https://code.wireshark.org/review/18708
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
Tested-by: Balint Reczey <balint@balintreczey.hu>
2016-11-18 20:15:23 +00:00
Gerald Combs 8e5e6ddc5e CMake: Enable ccache for gcc and clang.
Add an option to check for and use ccache. Disable it by default.

Change-Id: Ifc928d22715b7e06e53115455b31dbeaf2ee8332
Reviewed-on: https://code.wireshark.org/review/18715
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-11-09 18:29:11 +00:00
Peter Wu a77e8a3252 cmake: install missing profiles directory
Spotted when comparing an autotools "make install" tree with the cmake
one.

Change-Id: I68eed5f518a72a6476c3e464a6997f0b3855144e
Reviewed-on: https://code.wireshark.org/review/18713
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-11-08 18:56:32 +00:00
Jörg Mayer 54bbff9c65 Revert "Instead of supressing the warning of policy 42, set MACOSX_RPATH.":
---------
CMake Warning (dev):
  Policy CMP0042 is not set: MACOSX_RPATH is enabled by default.  Run "cmake
  --help-policy CMP0042" for policy details.  Use the cmake_policy command to
  set the policy and suppress this warning.

  MACOSX_RPATH is not specified for the following targets:

   epan
   wiretap
   wscodecs
   wsutil

This warning is for project developers.  Use -Wno-dev to suppress it.
-----------

This reverts commit 4728bc201b.

Change-Id: I7ea056d56c0352b54be5bebadc35de6173ef593f
Reviewed-on: https://code.wireshark.org/review/18562
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2016-10-29 07:03:38 +00:00
Joerg Mayer 4728bc201b Instead of supressing the warning of policy 42, set MACOSX_RPATH.
Fixes picking up the system libpcap instead of the one in /usr/local/lib/

Change-Id: I488c8512fc2cde145107062a6e8b7815ad764a3b
Reviewed-on: https://code.wireshark.org/review/18545
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2016-10-29 06:02:37 +00:00
Alexis La Goutte cad7665f8b CMAkelists: fix typo on comment
Change-Id: I572ebbbae9ac91e2d566a39d0dae462bc40bcac8
Reviewed-on: https://code.wireshark.org/review/18522
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-10-28 07:21:18 +00:00
Pascal Quantin 28bbd56591 Add SBC decoding support to Windows
Change-Id: Ibef872dff26c22e2834e958c496c33a5695bb131
Reviewed-on: https://code.wireshark.org/review/18394
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-10-22 17:35:54 +00:00
Martin Kaiser a2d49125a5 cmake, qt4: check if QT4_FOUND
AFAICS, FindQt4.cmake sets QT4_FOUND, not Qt4_FOUND

This fixes compilation on Debian Wheezy (cmake 2.8.9, Qt 4.8.2).

Change-Id: I08b3ac6ae4292b8c8d3f9e8752780459e5329e29
Reviewed-on: https://code.wireshark.org/review/18395
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-10-22 17:17:26 +00:00
Gerald Combs e858829404 CMake: Disable Qt4 && (Windows || macOS).
We haven't built the Windows and macOS installers with Qt4 for quite
some time. In the case of macOS+Qt4 it looks like there's a problem with
the main screen size (bug 13009) and it's a safe bet that there are
other problems. There's not much we can do exept say "don't do that." Do
so at build time rather than after the user has installed Wireshark and
is trying to use it.

Change-Id: I22f47b9705ea044238046676b6336aa5feab3f60
Reviewed-on: https://code.wireshark.org/review/18364
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-10-22 11:21:09 +00:00
Peter Wu c9fa9b51de cmake: add dependency to build manual pages
"add_custom_command" outputs are only available as dependency in the
same directory, so create a new target such it can be used from the main
directory.

This fixes the OS X build with no parallelism (-j1).

Change-Id: I66aa5ae307be38ee715456a05fd55f55e4fa76e9
Reviewed-on: https://code.wireshark.org/review/18299
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-10-20 13:06:17 +00:00
Peter Wu 9c3d81adde Officially require Qt 4.8 or newer
Since v2.3.0rc0-1002-g1cd2255, Qt 4.8 became mandatory, reflect this in
the version requirements. This will not affect a lot of distributions
(RHEL and SLES only had Qt 4.6).

For a more complete list of supported platforms, see
https://wiki.wireshark.org/Development/Support_library_version_tracking

While at it, correct some other minimum versions in documentation.

Change-Id: I11f2dfba72c75429f6838404a81ed3b3dc302d5f
Reviewed-on: https://code.wireshark.org/review/18314
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-10-20 05:03:07 +00:00
Pascal Quantin 303948500f CQL: add LZ4/Snappy decompression support on Windows
Change-Id: I34374cf29357e2ed5062da1a5245b9adbabf732d
Reviewed-on: https://code.wireshark.org/review/18249
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-10-18 04:00:35 +00:00
Benoît Canet 47649d1c7f cql: add lz4 and snappy decompression
We do not use the STARTUP negotiation since a stream
can be captured in its middle but try to decompress
if the flag is present and fallback if it fails.

Change-Id: Iecbf49a45220b04be7808869c9884548eb1e7694
Signed-off-by: Benoît Canet <benoit@scylladb.com>
Reviewed-on: https://code.wireshark.org/review/17952
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-10-17 18:28:45 +00:00
Uli Heilmeier 9a6539990d CMakeLists: Add man files
Current Wireshark.app bundle on OS X doesn't include man pages.

This is the second try after commit 7da23ca1a5bba4af5e1104f4d3d3d44e918552b0
has been reverted. Now cmake gets the information that the man files
are generated.

Bug: 12746
Change-Id: I34dfec65bd57587ee048d7e1e2557fc9ab2b32eb
Reviewed-on: https://code.wireshark.org/review/18170
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-10-14 03:33:34 +00:00
Balint Reczey b1cc056b12 Remove nghttp2 code and use system' nghttp2
Update debian, macos (setup / homebrew) download script
Update testsuite (don't try HPACK when build without nghttp2)

Change-Id: I365e5e17bc4fab4acd81b4c39ea7189a5d1ee112
Reviewed-on: https://code.wireshark.org/review/17347
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-10-13 19:26:10 +00:00
Uli Heilmeier 5fba7f368d Revert "CMakeLists: Add man files"
This reverts commit 55148a2ea4.

Change-Id: If93b97933cae4d8ffd1e4cc9a635def031ab0cc6
Reviewed-on: https://code.wireshark.org/review/18123
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-10-08 19:07:26 +00:00
Gerald Combs 22d8142ce7 Disable ASAN when building lemon.
If ASAN is enabled, use "-fno-sanitize=all" when building lemon. This
keeps us from having to set ASAN_OPTIONS=detect_leaks=0 in the
environment in order to build Wireshark.

Change-Id: I36f6d1a4f913ecabaf188f4c2b59216c8430d81a
Reviewed-on: https://code.wireshark.org/review/18098
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-10-07 17:54:35 +00:00
Uli Heilmeier 55148a2ea4 CMakeLists: Add man files
Current Wireshark.app bundle on OS X doesn't include man pages.

Change-Id: I4123105ae805c3f127dbfd74768b88d4da546c56
Ping-Bug: 12746
Reviewed-on: https://code.wireshark.org/review/17902
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-10-05 12:28:32 +00:00
Peter Wu 534787e402 cmake: make WERROR_COMMON_FLAGS a normal string
Instead of checking for the boolean "FALSE", just set an empty string.
This avoids the need to check for WERROR_COMMON_FLAGS before using it.

The transformation is the same for all files, remove
"if (WERROR_COMMON_FLAGS)" and "endif()", reindent and add quotes (since
we have a string here and not a list).

Modelines have been added where missing.

Change-Id: I0ab05ae507c51fa77336d49a99a226399cc81b92
Reviewed-on: https://code.wireshark.org/review/17997
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Tested-by: Dario Lombardo <lomato@gmail.com>
2016-09-30 20:08:02 +00:00
Gerald Combs b725d6c9ac Add an initial "shellcheck" target.
Look for shellcheck in Autotools and CMake, and if found add a target
that checks some of our shell scripts.

Add a "source=" directive to targets that include test-common.sh so
that shellcheck will correctly process the scripts. Note that this
requires shellcheck 0.4.0 or later.

To do: Fix the issues that shellcheck found and check more scripts.

Change-Id: I441f9f59d8a3f8eec6718119c2370f2560b98f3c
Reviewed-on: https://code.wireshark.org/review/17943
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-09-26 23:17:02 +00:00
Peter Wu 05ae6a7560 Remove -Wdeclaration-after-statement
This is a C99 feature which we can use now.

Change-Id: I84a63d6bf282b79c9f0da0543b3b4f5a0cf0c81a
Reviewed-on: https://code.wireshark.org/review/17733
Reviewed-by: João Valverde <j@v6e.pt>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-09-17 09:11:49 +00:00
Dario Lombardo 47650d357e extcap: add udpdump.
Udpdump is a generic UDP receiver that exports datagram in PCAP format.

Change-Id: I52620a92b12530b6f9b5449c43e692663acdfc14
Reviewed-on: https://code.wireshark.org/review/17195
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-09-16 08:07:30 +00:00
Guy Harris 0495fc3bdd Add some notes about XLC, HP C, and Sun/Oracle C.
Change-Id: I2f65face2aa7354ec350aed308402bb719bd619f
Reviewed-on: https://code.wireshark.org/review/17546
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-09-07 03:53:40 +00:00
Peter Wu 232a879429 Allow a lot more C99 features
Flexible array members are supported by gcc, clang and even MSVC2013.
Note, so far it was only used in the Windows-specific airpcap.h.

Trailing commas in enum declaration are already in use since for
these dissectors (commit ID is the first occurrence):
epan/dissectors/packet-gluster.h v2.1.0rc0-1070-g3b706ba
epan/dissectors/packet-ipv6.c v2.1.2rc0-81-ge07b4aa
epan/dissectors/packet-netlink.h v2.3.0rc0-389-gc0ab12b
epan/dissectors/packet-netlink-netfilter.c v2.3.0rc0-239-g1767e08
epan/dissectors/packet-netlink-route.c v2.3.0rc0-233-g2a80b40
epan/dissectors/packet-quic.c v2.3.0rc0-457-gfa320f8

Inline functions using the "inline" keyword are supported via all glib
versions we support (if it is missing, glib will define a suitable
inline macro).

Other c99 functions listed in the README.developer document were found
to be compatible with GCC 4.4.7, Clang 3.4.2 and MSVC 2013.

Change-Id: If5bab03bfd8577b15a24bedf08c03bdfbf34317a
Reviewed-on: https://code.wireshark.org/review/17421
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-09-06 02:42:27 +00:00
Gerald Combs abd78dc12b CMake: Move version declarations to the top of CMakeLists.txt.
This lets me be more lazy during releases.

Change-Id: Ie59e200f1f46282e9271f459c0bbf31dc74a59a7
Reviewed-on: https://code.wireshark.org/review/17450
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-09-02 00:44:09 +00:00
João Valverde 640382c743 CMake: Allow setting per target compiler warnings
Setting our compiler warning flags in CMAKE_C_FLAGS does not allow
using different flags per target.

Allow for that possibility by setting the internal WS_WARNINGS_{C,CXX}_FLAGS
and using the COMPILE_OPTIONS property to set them.

This change is just setting mechanism and there should be no difference
in generated warnings.

The check_X_compiler_flag cmake test is changed to test each flag individually.
We need a list, not a space separated string, and the aggregate test is not
significant.

Change-Id: I59fc5cd7e130c7a5e001c598e3df3e13f83a6a25
Reviewed-on: https://code.wireshark.org/review/17150
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-08-23 21:33:09 +00:00
João Valverde d21295f9a6 Bump GLib minimum required version to 2.22.0
Change-Id: I0ab85be8090f234f9ca10914063f97f13c894413
Reviewed-on: https://code.wireshark.org/review/16879
Petri-Dish: João Valverde <j@v6e.pt>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-08-04 16:13:41 +00:00
Gerald Combs 3dbc84414e 2.1.2 → 2.3.0.
Change-Id: I133af2d3d05ae77c1030cf35812bb1f969f6a68b
Reviewed-on: https://code.wireshark.org/review/16575
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-07-21 22:55:48 +00:00
Pascal Quantin 42e72d529c More 2.1.1 → 2.1.2 changes
Change-Id: If1a7f1232bbb23b27063d4ef618c2059293ff0c4
Reviewed-on: https://code.wireshark.org/review/16441
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-07-14 22:21:53 +00:00
Gerald Combs 06ba81b4f1 Build 2.1.1, second try.
The buildbots that create packages run `perl make-version.pl
--set-release` at the beginning of each build. This in turn sets the
extra version information for our generated packages to "-g<abbreviated
hash>" for development builds, or "" (an empty string) for release
builds.

Hardcoding the extra version information to "-git" in CMakeLists.txt and
configure.ac means we end up with wireshark-2.1.0-git.tar.bz2,
Wireshark-win64-2.1.0-git.exe, etc. for release builds. Set them back to
empty strings.

Change-Id: Icdfb248d25ad4adbc9abe0bd938e410590e42828
Reviewed-on: https://code.wireshark.org/review/16439
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-07-14 19:34:39 +00:00
João Valverde 10db044757 CMakeLists.txt: Fix gcee3e82
Bug: 12589
Change-Id: I7f9be4027214cb7ae4f7b235cba73c088596a80d
Reviewed-on: https://code.wireshark.org/review/16322
Reviewed-by: João Valverde <j@v6e.pt>
2016-07-07 20:35:58 +00:00
Pascal Quantin bed9d187ba Remove remnants of g_spawn_helper support
Change-Id: I88121a280ff01a889daeda438b308380b6ea0703
Reviewed-on: https://code.wireshark.org/review/16303
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2016-07-05 16:11:13 +00:00
Roland Knall f2786bc8ff extcap: Remove g_spawn_helper support
Move g_spawn to separate file and implement functions to
 use Windows based method of spawning, instead of the glib
 based version

Change-Id: Ibae03d834ec86531eba37dc8768fbf17ddadf57f
Reviewed-on: https://code.wireshark.org/review/16049
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-07-05 11:54:43 +00:00
Gerald Combs 46561910f4 CMake: Update the macOS wrapper script behavior.
CMake on macOS creates a convenience wrapper (run/wireshark) that runs
run/Wireshark.app/Contents/MacOS/Wireshark. Have it run the executable
using "exec" instead of opening the bundle using "open" so that
Wireshark runs in the foreground.

Change-Id: I295ce0681da75678e5e01781e9c8fb58e2236fc9
Reviewed-on: https://code.wireshark.org/review/16196
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-06-29 18:11:59 +00:00
Gerald Combs 619659599a CMake: Qt 5.7 requires C++ 11.
Add -std=c++11 to CMAKE_CXX_FLAGS if we have Qt >= 5.7.0 and we're
compiling with g++ or clang++.

Change-Id: Id4ce5921ce5c475e9eb9cc67f94c3b3a895924a1
Reviewed-on: https://code.wireshark.org/review/16135
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-06-27 04:27:56 +00:00
Gerald Combs 561a063fee Pass "/utf-8" to Visual C++ 2015.
Many projects (Qt[1] and GNOME[2] in particular) either recommend, use,
or at least allow for UTF-8 in source and header files. Pass /utf-8 to
Visual C++ 2015 so that it will behave itself around UTF-8 and be more
like that nice compiler down the street.

[1] https://wiki.qt.io/Strings_and_encodings_in_Qt
[2] https://bugzilla.gnome.org/show_bug.cgi?id=767218

Change-Id: Ibc90d235742134cb42dd796ba529699bcbbe3ad0
Reviewed-on: https://code.wireshark.org/review/15821
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-15 20:51:34 +00:00
Pascal Quantin 6baa1b544c Remove Nmake build system
Change-Id: I3bd474f3cda9667dec66426b5729449953df3e61
Reviewed-on: https://code.wireshark.org/review/15777
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
2016-06-15 19:21:57 +00:00
Peter Wu c19e6c2406 cmake: fix ENABLE_ASAN detection
Do not add -fsanitize=undefined when ASAN is requested, UBSAN is a
different feature (which could be added later as desired). This makes
the -DENABLE_ASAN=1 option match the autotools --enable-asan option.

Fail hard if ASAN support is requested but not supported, this avoids
surprises when something is wrong. Fix ASAN detection by setting the
linker option too.

Note: if you have previously set ENABLE_ASAN=1 with the broken ASAN
detection, you have to clear your CMakeCache.txt file to redo the
detection.

Change-Id: Iba6ca0da0336eccedd0cf31a251baad9d1aff5b4
Reviewed-on: https://code.wireshark.org/review/15908
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-15 06:02:51 +00:00
Anders Broman cbfa81769f Revert "Move inclusion of CmakeListsCustom to the end of the file in order to have all defines in place."
This reverts commit bcbcad1e59.

This change breaks building of custom plugins.

Change-Id: I63e88ceb922ca23ead9784705ad8ba088a504fd1
Reviewed-on: https://code.wireshark.org/review/15893
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-14 15:37:51 +00:00
AndersBroman bcbcad1e59 Move inclusion of CmakeListsCustom to the end of the file in order to have
all defines in place.

Change-Id: I190257e9b833c409921bbca74c8ab531b632c60d
Reviewed-on: https://code.wireshark.org/review/15878
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-13 21:08:53 +00:00
João Valverde cee3e827eb CMake: Make PROJECT_VERSION_EXTENSION code simpler
The intent was to allow all sorts of overrides but, ugly.

I don't think we need $cmake_package_string either, at least with
these changes.

Follow-up to 7c6e859ccf.

(And bdec712166).

Change-Id: I808b6bd3a3c64d2a67165344e8fe23e8314c27db
Reviewed-on: https://code.wireshark.org/review/15835
Reviewed-by: João Valverde <j@v6e.pt>
2016-06-12 19:29:47 +00:00
Gerald Combs bdec712166 2.1.0 → 2.1.1.
Change-Id: Ib8aab341be406d3c6e9139ae670489bd9e3edcc5
Reviewed-on: https://code.wireshark.org/review/15785
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-06-08 21:58:16 +00:00
Gerald Combs 46f9217c25 Build 2.1.0, second try.
Remove the "-git" version extra default in CMakeLists.txt and
configure.ac, otherwise we end up with wireshark-2.1.0-git.tar.bz2,
Wireshark-win64-2.1.0-git.exe, etc.

Change-Id: I89b9beaa87ac475950e24a3111cf09e878a33ff7
Reviewed-on: https://code.wireshark.org/review/15784
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-06-08 20:36:23 +00:00
João Valverde 7a23f422da Make -Wunused-const-variable a C only warning
Change-Id: If93de2c371f36fa0447fb8215337f0c115d74bbb
Reviewed-on: https://code.wireshark.org/review/15524
Reviewed-by: João Valverde <j@v6e.pt>
2016-05-22 04:56:34 +00:00
Michael Mann c34996f970 Create a Wix Installer
This is intended to replace the NSIS installer for Windows.
It does not include installing WinPcap or USBPcap.  From the research I've done, it seems to make more sense to "bundle" them with Wix ("wrapper" installer that would include Wireshark, WinPcap and USBPcap installers together)

TODO:
1. Customize installer with Wireshark graphics
2. Better handling flexibility of installing VC CRT Merge module (need build script to provide appropriate macros).  Something like (or modifying existing) FindMSVC_REDIST.cmake.
3. Use Wireshark UpgradeProductCode for install/uninstall. Previous NSIS installer did not have an upgrade code, so there are some backwards compatibility concerns.
4. Uninstall considerations (removing whole directories - plugins, configuration profiles?).  NSIS needed to do more things "manually" than Wix does by default.  Need to merge as best as possible to handle backwards compatibility.

Many thanks to Brian Pratt for all the Wix help.

Change-Id: Ib50780214fc7707ba2a46fd96ba8797a1763fa0c
Reviewed-on: https://code.wireshark.org/review/14858
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-05-11 13:09:17 +00:00
Joerg Mayer a9070e1a90 When using clang, warn about c99 only syntax (like pedantic without all the rest).
Change-Id: Ife6fcb14ce04e4d505ee4911a102420932fb18de
Reviewed-on: https://code.wireshark.org/review/15334
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2016-05-10 17:45:29 +00:00
Michael Mann 6bd2e29358 SMI_DLL should not be part of directory path for copying MIBs
Change-Id: Ib21ff7175fdaf4833398151378cba93d309dd409
Reviewed-on: https://code.wireshark.org/review/15294
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-05-09 04:09:16 +00:00
Graham Bloice 2e23b506c7 Add checkAPI calls to CMake.
This generates a top level target, checkAPI, that is
excluded from the ALL build target, so must be run separately.

On Windows using a Visual Studio generator, call
msbuild /p:Configuration=RelWithDebInfo checkAPI.vcxproj

Change-Id: I44a57c564dcfc75499463b942436f4b920a82478
Reviewed-on: https://code.wireshark.org/review/14873
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2016-05-02 12:01:24 +00:00
Pascal Quantin ae316e2d88 Compile sshdump and ciscodump for Windows
Use libSSH 0.7.2 compiled with MinGW(32|64) and linked with zlib and gcrypt support

Change-Id: I7c17d1ba3dd1890e2f83c119f5ea851834807e43
Reviewed-on: https://code.wireshark.org/review/12117
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-04-25 07:22:28 +00:00
João Valverde 5d1ee652ed Add CMake version.h dependency
Remove the need for version.h.in and bring CMake up to par with autotools.

Change-Id: I701b56c475f5fdec1f9a028536fff6992ce8eaca
Reviewed-on: https://code.wireshark.org/review/15031
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-04-22 22:10:30 +00:00
João Valverde 3db13a7fc9 Link version code statically again
This allows keeping the code-sharing with the static linking.

This "fixes" a hypothetical ABI mismatch with wsutil and avoids pulling more
external dependencies to wsutil than strictly necessary.

A nice side-effect is that libwsutil no longer depends on version.h.

Follow up to f95976eefc.

Change-Id: I8f0d6a557ab3f7ce6f0e2c269124c89f29d6ad23
Reviewed-on: https://code.wireshark.org/review/15002
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-04-21 18:59:56 +00:00
João Valverde 7c6e859ccf Add "-git" tag to version
Add a static "-git" extra version tag for VCS snapshot builds, to be
replaced when running 'make-version -r'.

Change-Id: If29fca04029ed3129aa2332492dc536091049955
Reviewed-on: https://code.wireshark.org/review/15032
Reviewed-by: João Valverde <j@v6e.pt>
2016-04-21 18:59:40 +00:00
Gerald Combs cf6501eb45 Windows: Remove the need for _CRT_NONSTDC_NO_DEPRECATE.
Replace some function calls with their non-deprecated equivalents so
that we can remove _CRT_NONSTDC_NO_DEPRECATE from CMakeLists.txt and
config.nmake.

Leave _CRT_SECURE_NO_DEPRECATE in place. Removing it failed with 145
warnings and 72 errors.

Note that we could probably improve startup performance by using wmem
in diam_dict.*.

Change-Id: I6e130003de838aebedbdd1aa78c50de8a339ddcb
Reviewed-on: https://code.wireshark.org/review/14883
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-04-13 02:16:20 +00:00
João Valverde ed6eecd79e [GTK] Check for xdg-open at run time
Remove HTML_VIEWER compile-time setting.

If xdg-open doesn't exist use user web browser preference as fallback.

Change-Id: I3b4a4a1a36b0192d75f2c97595f37d0d88a0941e
Reviewed-on: https://code.wireshark.org/review/14805
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Tested-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: João Valverde <j@v6e.pt>
2016-04-09 23:40:51 +00:00
Peter Wu 57b2a84f3d Use a single WS_NORETURN macro
Having to define two macros for marking a function as never returning
seems a bit redundant. Merge the MSVC and GCC-like attributes into a
single WS_NORETURN.

Tested with Clang 3.7.1, GCC 4.4.7 and even GCC 4.1.2 using this small
program (-Wall -Wextra, the first two generate warnings for
uninitialized variables, the last one compiles without warnings):

    #include <stdlib.h>
    __attribute__((noreturn)) void foo() { exit(1); }
    __attribute__((noreturn)) void bar();
    void bar() { exit(1); }
    int main() {
      int j, i;
      if (i) { bar(); return j; }
      foo();
      return j;
    }

Change-Id: I7d19c15e61b8f8fa4936864407199c4109f8cc82
Reviewed-on: https://code.wireshark.org/review/14822
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-04-08 17:34:10 +00:00
João Valverde 71f2b6e1b4 Remove -Warray-bounds, it is enabled by default with -Wall
Change-Id: If2041c66ccdf8a975d660524c793d45aa9f80623
Reviewed-on: https://code.wireshark.org/review/14852
Reviewed-by: João Valverde <j@v6e.pt>
2016-04-07 18:03:50 +00:00
João Valverde 6f98a0fac3 Rename "libz" to "zlib"
Change-Id: I12f92c983d587c2a4751428cdf299635090c9f0b
Reviewed-on: https://code.wireshark.org/review/14748
Reviewed-by: João Valverde <j@v6e.pt>
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-04-04 06:58:41 +00:00
João Valverde e005bc819c Remove synchronous DNS name resolution
Change-Id: Ie5e670b769eb0674950f3679ef511047641c2873
Reviewed-on: https://code.wireshark.org/review/14751
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-04-04 06:49:55 +00:00
Alexis La Goutte 7fbf2591b7 Revert "Trun on -Wused-but-marked-unused but only as warning, never as error. (possibly clang only)"
This reverts commit 9f40a75bbb.

Change-Id: I4361f1101077643d10a86237e256ba28ed180a66
Reviewed-on: https://code.wireshark.org/review/14721
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2016-03-31 07:05:00 +00:00
João Valverde 26f3a9aa84 Use "old-style" moc options to ensure backward compatibility for Qt tools
Change-Id: Ic96df4ba521e0fbaf4ac34f23e3a89304ed5de5c
Reviewed-on: https://code.wireshark.org/review/14662
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-29 14:05:48 +00:00
Joerg Mayer 9f40a75bbb Trun on -Wused-but-marked-unused but only as warning, never as error.
(possibly clang only)

Change-Id: I014b8f069515af6128177dfc5813380db445957c
Reviewed-on: https://code.wireshark.org/review/14686
Petri-Dish: Jörg Mayer <jmayer@loplof.de>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2016-03-28 22:45:56 +00:00
Peter Wu e6c54017a7 Fix out-of-tree "gen-authors" target
Change directory to the source tree before invoking `git shortlog`,
otherwise it fails on build directories outside the source tree.

Alexis suggested to move the git invocation to the perl script, this is
done now and also avoids writing AUTHORS.git in the source tree.

Change-Id: I5905ebf40d8d32a586c88671b52f28c542ca33ba
Reviewed-on: https://code.wireshark.org/review/14660
Reviewed-by: João Valverde <j@v6e.pt>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2016-03-28 22:13:59 +00:00
João Valverde 4440da9cae Remove -W from compiler warnings
Change-Id: I6d1aeab4fd9dce9b7a9804ac9099d318a2b434d2
Reviewed-on: https://code.wireshark.org/review/14622
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-25 00:32:56 +00:00
João Valverde a1ed731413 Add ax_lib_socket_nsl.m4 macro
Add SOCKET_LIBS and NSL_LIBS to global LIBS variables on platforms
where it is required.

Make configure checks for getaddrinfo/gethostname unconditional,
that is handled with #ifdefs if necessary.

Change-Id: Ia874038454fb9cf3bdbf8e6fd829f319e331837e
Reviewed-on: https://code.wireshark.org/review/14560
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-25 00:16:19 +00:00
Guy Harris a4aa8930bb Put pcapio.c into a writecap library, and use it.
Change-Id: Ib89f345c072a38bc01f0513366a4bdae3bf6f08e
Reviewed-on: https://code.wireshark.org/review/14615
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-03-24 20:49:37 +00:00
Dario Lombardo a6921c79ab extcap: add ciscodump.
Ciscodump is a new extcap that allows packet capture
on Cisco routers (IOS 12.4 and later) through SSH.

Change-Id: Ic9c5be01d3bd0112116f7fc9fa10e26c1552b007
Reviewed-on: https://code.wireshark.org/review/13886
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-03-24 12:07:28 +00:00
João Valverde 7a1d3f67ac Remove ADNS support
Relevant mailing list message:

  https://www.wireshark.org/lists/wireshark-dev/201503/msg00007.html

Change-Id: I0cff6d4d64fb52a651bcf6b28c183e43653b1cc2
Reviewed-on: https://code.wireshark.org/review/14519
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-21 19:32:00 +00:00
João Valverde 52dd4fb633 Fix building without extcap enabled
Using cmake -DENABLE_EXTCAP=no or ./configure --without-extcap.

Some documentation fixes too.

Change-Id: Iebf9c843d67e10a32de1a62904de8f88b872ec99
Reviewed-on: https://code.wireshark.org/review/14522
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-21 17:10:21 +00:00
Graham Bloice 92db934c7c Fix CMake target FOLDER properties
Add FOLDER properties to targets to clean up the presentation
in Visual Studio.

Change-Id: I35a175175db055443572c58a069879061fdcf0a3
Reviewed-on: https://code.wireshark.org/review/14528
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2016-03-20 14:03:12 +00:00
João Valverde a44282e151 cmake: Remove extcap from include directories
Change-Id: Ia521aaa6ace14df5a6c02e0dd1c8336df41ac180
Reviewed-on: https://code.wireshark.org/review/14517
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-18 19:30:41 +00:00
Gerald Combs 4aa049019a OS X: Remove GTK+ packaging.
Remove the GTK+-specific bits from packaging/macosx.

Change-Id: I8f7d909f971e60723e421005fdf46de967c69533
Reviewed-on: https://code.wireshark.org/review/14431
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-03-14 16:09:42 +00:00
João Valverde 54a520d4a1 Move /asn1 to /epan/dissectors
Change-Id: I1208fe3c2ba428995526f561e8f792b8d871e9a9
Reviewed-on: https://code.wireshark.org/review/14388
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-13 21:30:24 +00:00
João Valverde 0ca383e529 cmake: Copy docs to build datafile dir for NSIS packaging.
Change-Id: Icc1f6dadc8bb082c4049cafc6a7e6c2d030ec85e
Reviewed-on: https://code.wireshark.org/review/14409
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-11 15:20:46 +00:00
João Valverde b7f6cf979c Add doc/CMakeLists.txt
Change-Id: I387e893dc5b8b38569f7189d078fdc1853ba012f
Reviewed-on: https://code.wireshark.org/review/14269
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
2016-03-10 11:19:09 +00:00
Alexis La Goutte 80dda81a61 AUTHORS: sort by name
Change-Id: I01980d1ab757decb7bb84649dbd41477978104c3
Reviewed-on: https://code.wireshark.org/review/14381
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2016-03-08 18:02:01 +00:00
Alexis La Goutte 4f3a88989e Add conflict check filter
Set ENABLE_CHECK_FILTER to 1 for get list of display filter with conflict...

Ping-Bug:2402
Change-Id: I8d56b1573120d1a29d437aae1088be242e15e9a3
Reviewed-on: https://code.wireshark.org/review/13644
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2016-03-07 07:57:29 +00:00
Gerald Combs 32d60ac2f5 CMake: Avoid pipes and the `cut` command.
Dump the output of `git shortlog` directly to AUTHORS.git instead of
piping it through `cut`. Depending on our toolchain, cmake COMMANDs might
not support pipes. This appears to be the case for MSBuild. Removing the
`cut` command has the added benefit of reducing our dependency on Cygwin.

Pass HEAD to `git shortlog`, otherwise it doesn't return anything when
run under MSBuild.

Change-Id: I23e9436c007d76a700bbbc45c2772c8aba6d5749
Reviewed-on: https://code.wireshark.org/review/14349
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-06 01:12:56 +00:00
Dario Lombardo 637aefd2b3 cmake: fix gen-authors target.
Also add AUTHORS.git to .gitignore.

Change-Id: I63365816fc32b33d064ebbcae0ddb607c2b37f38
Reviewed-on: https://code.wireshark.org/review/14339
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
2016-03-04 15:30:24 +00:00
Dario Lombardo d8f541c89b extcap: move ssh common functions to ssh-base.
Change-Id: Ic06882a4f914b4f89d936d5d942b50552ae4abb3
Reviewed-on: https://code.wireshark.org/review/14264
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-03-04 07:14:09 +00:00
Dario Lombardo 68d4ba212c extcap: add local_interfaces_to_list() to wsutil.
This new function abstracts the creation of a list of the local
interfaces that will be used by future extcaps to generate specific
filters. Sshdump now uses it to create a pcap filter.

Change-Id: I5b75a266f81104b3c9bcb3e51de246b7cc8785ce
Reviewed-on: https://code.wireshark.org/review/14092
Reviewed-by: João Valverde <j@v6e.pt>
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-03-04 05:53:56 +00:00
Michael Mann 8435145b1f Create perl script to append existing AUTHORS file with information from git log.
new AUTHORS file can be created with "gen-authors" build parameter

The "original" AUTHORS file has been fixed up to be kind to parsers (so no one gets excluded) and renamed to AUTHORS.src.  This preserves the features authors worked on.  For authors that didn't list features, they may be converted to just getting information from git.

Change-Id: I9a4c4091e229f7f5e1c46d864527a98c1278e451
Reviewed-on: https://code.wireshark.org/review/14231
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-03 18:28:32 +00:00
João Valverde 6b54fbf3bf CMake: Add more structure to libwireshark build
Smaller epan/CMakeLists.txt is easier to work with and this structure
is well suited to CMake. It should make it easier to manage and configure
each epan module differently if necessary.

Change-Id: Ia649db3b7dcd405aa43dbdba3288699d5e375229
Reviewed-on: https://code.wireshark.org/review/14068
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-01 19:23:39 +00:00
Roland Knall a4e2263ac4 extcap: Move extcap handling to base
Also add the extcap-version parameter to enable parsing of
version and helppage separately

Change-Id: I35ba5aa992940ffbb0cd9ebea8b7c3a1e8629d74
Reviewed-on: https://code.wireshark.org/review/14094
Petri-Dish: Roland Knall <rknall@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-02-29 12:32:03 +00:00
Dario Lombardo 298012359b extcap: move windows functions into extcap-base
Change-Id: Iec7fed027a24992afd673b09c32470af51739ae5
Reviewed-on: https://code.wireshark.org/review/14075
Reviewed-by: Roland Knall <rknall@gmail.com>
2016-02-26 10:02:59 +00:00
Guy Harris b32a5ee98c Don't add the wiretap directory to the list of include directories.
If you include something from the wiretap directory, always precede it
with wiretap/.

Fix some includes of files in the top-level directory to use a path
relative to the current directory, not relative to the wiretap
directory.

This makes it a bit clearer what's being included.

Change-Id: Ib99655a13c6006cf6c3112e9d4db6f47df9aff54
Reviewed-on: https://code.wireshark.org/review/13990
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-02-18 12:55:26 +00:00
Guy Harris 58d00bad1a Build the extcap programs in the extcap directory.
That lets the version of Wireshark built with autotools find the extcap
programs.

Don't install the extcap programs under ${datadir} - that puts it under
a share directory, and share directories are for platform-independent
files, which executable images aren't (they're instruction-set
dependent, hence platform-dependent).

Change-Id: I992eeb984bdbe6b3476777f7114628c83df6080f
Reviewed-on: https://code.wireshark.org/review/13943
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-02-15 08:31:06 +00:00
João Valverde b7a54039ac Use CMake conventional nomenclature for CXX_FLAGS
Change-Id: I2b67eed2bb04412b9d556e616fe3233176fac5bc
Reviewed-on: https://code.wireshark.org/review/13883
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-02-11 14:52:14 +00:00
João Valverde aa37baec70 CMake: Avoid unnecessary link dependency with SBC and fix debian warnings
Fixes dpkg warnings:

  dpkg-shlibdeps: warning: package could avoid a useless dependency if debian/wireshark-qt/usr/bin/wireshark was not linked against libsbc.so.1 (it uses none of the library's symbols)
  dpkg-shlibdeps: warning: package could avoid a useless dependency if debian/wireshark-gtk/usr/bin/wireshark-gtk was not linked against libsbc.so.1 (it uses none of the library's symbols)
  dpkg-shlibdeps: warning: symbol sbc_decode used by debian/libwscodecs0/usr/lib/x86_64-linux-gnu/libwscodecs.so.0.0.0 found in none of the libraries
  dpkg-shlibdeps: warning: symbol sbc_init used by debian/libwscodecs0/usr/lib/x86_64-linux-gnu/libwscodecs.so.0.0.0 found in none of the libraries
  dpkg-shlibdeps: warning: symbol sin used by debian/libwscodecs0/usr/lib/x86_64-linux-gnu/libwscodecs.so.0.0.0 found in none of the libraries
  dpkg-shlibdeps: warning: symbol floorf used by debian/libwscodecs0/usr/lib/x86_64-linux-gnu/libwscodecs.so.0.0.0 found in none of the libraries
  dpkg-shlibdeps: warning: symbol floor used by debian/libwscodecs0/usr/lib/x86_64-linux-gnu/libwscodecs.so.0.0.0 found in none of the libraries
  dpkg-shlibdeps: warning: symbol sbc_finish used by debian/libwscodecs0/usr/lib/x86_64-linux-gnu/libwscodecs.so.0.0.0 found in none of the libraries

Change-Id: I71911513c348edd336cdc82ea358b6a05760b4b9
Reviewed-on: https://code.wireshark.org/review/13784
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
2016-02-06 11:06:35 +00:00
João Valverde eeafb47a12 Fix Qt4 moc option argument and add build parametrization
Change-Id: Ib758f0eabaf96f9c6010201e7e16147fcfa0daa2
Reviewed-on: https://code.wireshark.org/review/13671
Petri-Dish: João Valverde <j@v6e.pt>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Tested-by: Michal Labedzki <michal.labedzki@tieto.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2016-02-03 09:10:20 +00:00
Gerald Combs 5cad2cd09b Add configure-time synchronous DNS warnings.
In CMake and Autotools, warn the user when neither c-ares nor ADNS is
present. Note that we might want to make asynchronous DNS a requirement.

Change-Id: Ia9cce56cc2286cdc72303fc1410f899f9c320d84
Reviewed-on: https://code.wireshark.org/review/13080
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-02-02 00:27:42 +00:00
Mike78 ef752689da Allow/Create an option to use "capture filter" labels defined in wireshark GUI from CLI
Move ui/filters.[ch] to filter_files.[ch] because dumpcap is using functionality.

Bug: 8091
Change-Id: I195c82fc023f97d6f331b8718c45a2d83d30faea
Reviewed-on: https://code.wireshark.org/review/5925
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-01-27 13:40:24 +00:00
Christian Tellefsen adb731c1cd Allow make-version.pl to use git when missing from path
This change allows make-version.pl to run correctly on Windows
without having the git binary dir in PATH. This prevents problems when
installing "Git for Windows" with default settings (git only available
via the bundled shell (bash).

Details:
* Add Git to the list of packages to be looked up by CMake.
* If Git is found by CMake, pass the full path to make-version.pl
* make-version.pl: Test whether git is available, and display a warning if git is missing.

On Unix-type systems this should have no impact.

Tested on Windows Server 2012 R2 and Ubuntu 15.04.

Change-Id: I7f7be2035c262658801586cb24c82b912848e31d
Reviewed-on: https://code.wireshark.org/review/13111
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2016-01-27 09:28:13 +00:00
Guy Harris 54e3b32027 Don't treat Visual Studio specially for linker flags.
Have CHECK_C_LINKER_FLAG pass /WX to the linker if we're using MSVC, to
force the link to fail if the linker doesn't recognize the flag.

Add flags to WIRESHARK_LD_FLAGS even with MSVC; let CHECK_C_LINKER_FLAG
figure out whether the flag should be used.

While we're at it, fix CHECK_C_LINKER_FLAG to save and restore
CMAKE_REQUIRED_LIBRARIES.

Change-Id: I7f73b4cc3a28eb14e46c2e1e9ad69f5303754f01
Reviewed-on: https://code.wireshark.org/review/13558
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-01-27 05:24:50 +00:00
Guy Harris 3cecda0246 Explain why we're still checking for MSVC.
Change-Id: I7d656eb5b38e8f7697b1414b6b3364a85ad132cf
Reviewed-on: https://code.wireshark.org/review/13557
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-01-27 01:13:36 +00:00
Michal Privoznik 8454f2a20e CMake: Produce correct plugindir for pkg-config
So far the plugindir variable in the pkg-config file is set like
this:

  set( plugindir "\${libdir}/${PLUGIN_INSTALL_DIR}" )

where libdir is set to:

  set( libdir "\${exec_prefix}/${CMAKE_INSTALL_LIBDIR}" )

However, PLUGIN_INSTALL_DIR already contains
CMAKE_INSTALL_LIBDIR:

  set(PLUGIN_INSTALL_DIR "${CMAKE_INSTALL_LIBDIR}/\
  ${CPACK_PACKAGE_NAME}/plugins/${CPACK_PACKAGE_VERSION}")

Therefore, if the pkg-config file is generated by cmake, the
resulting plugindir points to:

   plugindir=${libdir}/lib/wireshark/plugins/2.1.0
   libdir=${exec_prefix}/lib

This is obviously wrong as after variable substitution the
resulting path is /usr/lib/lib/wireshark/plugins/...

Change-Id: I448991284d8948434311b1c0828828fd93d0baf8
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-on: https://code.wireshark.org/review/13258
Tested-by: João Valverde <j@v6e.pt>
Reviewed-by: João Valverde <j@v6e.pt>
2016-01-23 15:55:08 +00:00
Gerald Combs 441c6d4e9c CMake: Fix an endif.
Fix

CMake Warning (dev) in CMakeLists.txt:
  A logical block opening on the line

    C:/Development/wireshark-w64/CMakeLists.txt:1649 (if)

  closes on the line

    C:/Development/wireshark-w64/CMakeLists.txt:1668 (endif)

  with mis-matching arguments.
This warning is for project developers.  Use -Wno-dev to suppress it.

Change-Id: I6b6060e4d88b385deb81111234e3229d104772f1
Reviewed-on: https://code.wireshark.org/review/13407
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2016-01-19 00:08:51 +00:00
Michal Labedzki 1cc4ac4619 Add Lua dependings only if LUA is enabled
Avoid build fail if found Lua but it is disabled.

Change-Id: If1cf0d650454d2844a1430135de1385c984e5ba4
Reviewed-on: https://code.wireshark.org/review/13394
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-01-18 16:09:05 +00:00
Michal Privoznik ea16a84ef5 Generate better pkg-config file
Firstly, when building with autogen.sh and configure script, the
wireshark.pc is not generated at all. Then, due to not matching
names some variables are not being replaced as they should be.

Bug: 11069
Change-Id: Iefa7a9b536f3fee7f9ad78803aaacc5bb64a9c8d
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-on: https://code.wireshark.org/review/13005
Reviewed-by: João Valverde <j@v6e.pt>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-01-04 08:15:29 +00:00
Peter Wu 408ea5d2fa cmake: do not fail if help/faq.txt already exists
The glob pattern should not catch the generated faq.txt file. Fix this
by explicitly listing all source .txt files.

Bug: 11896
Change-Id: I3904a0e094b5dba3808dacaaabd4db298a8f14cb
Reviewed-on: https://code.wireshark.org/review/12930
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
2015-12-30 00:44:25 +00:00
Michael Mann 5e4bbcda98 Refactor GUI dependencies out of color_filters.[ch] and move it to epan directory.
This also moved color.h into color_filters.h

Change-Id: Ic19e27aa1b3ec67e764aa7ee8bbef7b1187bb12e
Reviewed-on: https://code.wireshark.org/review/12831
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-12-28 18:33:41 +00:00
Guy Harris fd462af183 Fix a typo in a comment.
Change-Id: I4bde3d058c0602fe2a1f314a77fb62227d530666
Reviewed-on: https://code.wireshark.org/review/12834
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-23 03:49:36 +00:00
Dario Lombardo ac0eb6043b extcap: add randpktdump, a random packet generator.
This new extcap is for testing and educational purpose.
It relies on rankpkt-core functions to generate random packets.

Change-Id: If6890f0673545682995a2079458108edc0913b30
Reviewed-on: https://code.wireshark.org/review/11764
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-12-22 12:24:16 +00:00
Gerald Combs 6dfcbedde9 CMake: Make "install ... DESTINATION" paths relative.
Make sure we use relative destination paths in each install
command. Apparently many CPack generators don't support absolute paths,
particularly on Windows. This fixes the following error when running
`cpack -G WIX` here:

----
CPack: Create package using WIX
CPack: Install projects
CPack: - Install project: Wireshark
CMake Error at C:/Development/wireshark/cmbuild/cmake_install.cmake:206 (message):
  ABSOLUTE path INSTALL DESTINATION forbidden (by caller): C:/Program Files/Wireshark/lib/wireshark/extcap/androiddump.exe

CPack Error: Error when generating package: wireshark
----

Change-Id: Ifdcd40814df8163ea722a65ef55acc1a511b2f75
Reviewed-on: https://code.wireshark.org/review/12657
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
2015-12-18 17:05:12 +00:00
Guy Harris 54413c8594 Note why we do -Wno-variadic-macros.
Change-Id: Id57a6985eb37d9bf5246cf0f57cc24bb0ca153b9
Reviewed-on: https://code.wireshark.org/review/12639
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-14 22:27:01 +00:00
João Valverde 2aab706c5a Remove -Wwrite-strings compiler flag
The "-Wwrite-strings" flag produces nuisance warnings. These warnings are
not useful, they're impossible to fix in a sane way and therefore are being
handled with casts of static strings to (char *).

This just moves the warning to [-Wcast-qual] and a compiler pragma is
in turn required (and used) to squelch that warning.

Remove the Wwrite-strings warning. Let that responsibility fall on the
programmer (as is done by casting).

Change-Id: I5a44dfd9decd6d80797a521a3373593074962fb5
Reviewed-on: https://code.wireshark.org/review/12162
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-12-12 16:21:19 +00:00
Guy Harris d7006cebbb Revert "Build Flex-generated files with "warnings are errors"."
This reverts commit b56f53884b.

Sadly, we *do* get warnings at this point with older versions of Flex,
such as the one on the 32-bit OS X buildbot.

Change-Id: I9aec1a16e9f2e1bbcfaac3dffdabdd89af5815e3
Reviewed-on: https://code.wireshark.org/review/12443
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-05 17:13:28 +00:00
Guy Harris b56f53884b Build Flex-generated files with "warnings are errors".
We shouldn't be getting warnings at this point.

Change-Id: I363a48546cb8d916425f42962ae1697d52ed9a29
Reviewed-on: https://code.wireshark.org/review/12436
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-12-05 12:08:52 +00:00
Gerald Combs 42333aa353 CMake+PortableApps: Include the VC runtime (second try).
Move the code that finds the Visual C++ redistributable DLLs to its
own module. Run it before we create our NSIS and PortableApps targets.
Add a PortableApps target that copies the redistributable

This reverts commit 403fa9fbe0cdba3f443ec4674cda40092525ffe4.

Bug: 11800
Change-Id: I081d8fd3f5f37dd590659ca8f2bd309642a9a9df
Reviewed-on: https://code.wireshark.org/review/12431
Reviewed-by: Gerald Combs <gerald@wireshark.org>
(cherry picked from commit 5b580834aeeee8477039bc099c49c21aeeb3b71f)
Reviewed-on: https://code.wireshark.org/review/12432
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
2015-12-04 22:32:32 +00:00
Guy Harris be04716601 More libcodecs -> libwscodecs.
Change-Id: I861c625a4bf36ec8bddebec483f43cf6b3cd7c09
Reviewed-on: https://code.wireshark.org/review/12421
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-04 01:47:54 +00:00
Pascal Quantin 651e0884b7 Change codecs from static to dynamic library
This allows to properly register codecs plugins.
See https://www.wireshark.org/lists/wireshark-dev/201511/msg00202.html for details.

Change-Id: Ibc13a19936abb7a2e81b86582a75fa424351565b
Reviewed-on: https://code.wireshark.org/review/12385
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-03 23:54:49 +00:00
Ryan Doyle be2e0996b1 CMake: Fix breakage with CMake 3
This fix was accidentally reverted in d6da952. Tested with CMake
2.8.12.2 and 3.3.2.

Change-Id: I05312eb9ec18be88be6155edb1ced67ea2ee2bba
Reviewed-on: https://code.wireshark.org/review/12301
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-11-30 08:43:07 +00:00
Peter Wu 98a50d8513 cmake: print the current CMAKE_C_FLAGS/CMAKE_CXX_FLAGS
It is misleading to print RelWithDebInfo flags if I am using Debug.

Change-Id: I575d5c950cbe9d59852799c28fd88426f20cdaab
Reviewed-on: https://code.wireshark.org/review/12133
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-11-26 05:48:42 +00:00
Peter Wu 12b2e3d4e2 cmake: fix dependencies for copy_data_files
Ensure that files from INSTALL_FILES depend on html_docs, not the parent
target copy_data_files (that would not help at all). Ensure that lua
scripts are generated before copying them (another moved dependency).
Explicitly track the help files that have to be textified for Windows
(this finalizes the addition of proper dependencies to copy_data_files
targets).

Since there is no compelling reason for the extra
copy_data_files_depends target now, remove it and move copy_data_files a
bit further in the file such that the dependencies can be set.

While at it, remove the unnecessary make_directory, the copy_data_files
target will create it automatically when copying a file into it.

Should fix the problem reported at https://code.wireshark.org/review/12028

Change-Id: I81e56c93ac0fc85e7385605b9c780a80b3d43c85
Reviewed-on: https://code.wireshark.org/review/12130
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-11-25 11:01:10 +00:00
AndersBroman 46f3fe48a3 [Custom plugins] CUSTOM_PLUGIN_IN_FILES is no longer required.
Change-Id: I329a26ece145d70221d47c728e11dca54416a5cf
Reviewed-on: https://code.wireshark.org/review/12092
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-11-24 12:01:33 +00:00
Pascal Quantin 8748a047bf Fix NSIS installer generation broken in gffb5b3d
Change-Id: Ife7595f1bdeba02d53ec558cd4f26288b26687e7
Reviewed-on: https://code.wireshark.org/review/12091
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2015-11-24 09:24:53 +00:00
Peter Wu ffb5b3d727 cmake: add dependency information for copy_data_files
Original problem: run/radius/ (and other files) would continuously be
copied over because the "copy_directory" command is always invoked,
resulting in a newer timestamp (observable via rsync output).

Fix 1: convert from "copy_directory" to copying individual files
(matched via a glob pattern).

Fix 2: add DEPENDS information to the commands, ensuring that the
copy commands are only invoked when the file is actually newer.
(copy_if_different does not respect timestamp, so use plain copy.)

Other visible changes:
 - radius/Custom.make (automake thingey) is not copied anymore because
   an explicit list is used with glob patterns.
 - Removed comment about "default.tt" (gone since
   v1.99.0-rc1-1684-g07b003a, Makefile.nmake is still untouched though).

Due to fix 1, the number of processes increase by about 300. Due to fix
2 however, less processes are executed for repetitive runs. This is
visible in the following build time comparison:

    patch/generator cmake  build1  build2   clean
    before/make     24.86  152.73    3.46    1.04
    after/make      24.78  153.08    3.40    1.03
    before/ninja    22.99  141.68    0.64    0.24
    after/ninja     22.89  141.66    0.10    0.25

cmake is "cmake -DCMAKE_BUILD_TYPE=None -GNinja" (-G"Unix Makefiles");
build1 is invocation of "make -j10"/"ninja" on v2.1.0rc0-668-g94b9907;
build2 is the second invocation with this patch;
clean is "make clean" or "ninja clean".

Numbers are in seconds over 3 runs. This patch has no significant
performance impact for the first build, but the second run has improved
because the more efficient Ninja generator executes less processes.

Change-Id: I7b62556393520044aaaad17dafb82ac137ae73bb
Reviewed-on: https://code.wireshark.org/review/12028
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-11-24 06:13:56 +00:00
Alexis La Goutte 073cfb33ec CMakeLists (root): fix indent (use tabs)
Change-Id: I14089fbdafa00280ff7b3148c2e0a880b925958e
Reviewed-on: https://code.wireshark.org/review/11872
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-11-23 12:25:10 +00:00
Guy Harris d69cec7cff Quote the path for the Windows setup script.
The path may contain a space (it does on my Windows 7 VM), so quote it
in the PowerShell command.

Change-Id: Ib130991b8c29cb327832f2fe51cb37828526448b
Reviewed-on: https://code.wireshark.org/review/12041
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-11-22 19:16:25 +00:00
Graham Bloice f1efeb1eba Fix Windows hardening check
The hardening check runs on all binaries and quite a few third party binaries
are not hardened, thus leading to a warning on the buildslave.
The change reduces the noise by not counting the binaries that are known to be
"soft".  They are still printed in the output though, for reference.

Also fixed the search directory passed to the script.

Change-Id: I1619066c687c9ba934ab38fccbbf2011108328e4
Reviewed-on: https://code.wireshark.org/review/12016
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Graham Bloice <graham.bloice@trihedral.com>
2015-11-21 18:20:55 +00:00
Dario Lombardo d6da95231e extcap: add sshdump.
sshdump is an extcap module that allows dumping from a remote host using an ssh connection.
It goes with the existing extcap plugin interface.

Change-Id: I8987614fdd817b8173a50130812bc643a4833bca
Reviewed-on: https://code.wireshark.org/review/11402
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-11-19 15:29:18 +00:00
Gerald Combs e3eb9f3208 CMake: Add Qt5Svg to PACKAGELIST.
...otherwise we won't copy it to ${CMAKE_BINARY_DIR}/run/Wireshark.app on
OS X, which means our flag icons won't be displayed.

Bug: 11697
Change-Id: I26cd6a2dd13be35f9a80fd93adc8248848df5978
Reviewed-on: https://code.wireshark.org/review/11923
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-11-17 22:45:44 +00:00
Peter Wu 442314e8b2 Revert "Override optimization and other flags for make based generators."
Some compiler flags may not be passed twice (such as -mllvm
-msan-keep-going), so avoid duplicating CMAKE_C(XX)_FLAGS.

When -DCMAKE_BUILD_TYPE=<type> is set, you can override the default
optimization and debug flags with -DCMAKE_C_FLAGS_<type>=....

This reverts commit 15a238a28d.

Change-Id: I4e1cf11c49eaf00ad4a2c430454a127b4be20d9e
Reviewed-on: https://code.wireshark.org/review/11597
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2015-11-16 08:36:01 +00:00
Guy Harris d66d379ac8 Try retroactively applying the Qt folks' fix for QTBUG-47942.
The current version of the fix only adds -fPIC under certain
circumstances; we check whether it was added and, if it was, and those
circumstances are *not* in effect, we remove it.

Bug: 11643
Change-Id: I75d0ff9b4781d7d4cd884a29bbce7d392939315c
Reviewed-on: https://code.wireshark.org/review/11849
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-11-15 22:04:26 +00:00
Pascal Quantin b20d5bbc0b CMake: set WinPcap version in top CMakeLists.txt file like for NMake
This allows displaying the WinPcap version in about dialog

Change-Id: Ic3f4256d81db68314a158fc55682dfd9dbf799a0
Reviewed-on: https://code.wireshark.org/review/11726
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-11-11 17:47:45 +00:00
Dario Lombardo f1ff6d62c4 randpkt: split into a core and an app.
This will allow other apps to use the random packet generation
features.

Change-Id: I7e9af58cbe39da4908242b5fbb292f473e03b4f2
Reviewed-on: https://code.wireshark.org/review/11579
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-11-11 13:22:05 +00:00
Evan Huus 4f01f3d806 Move -fno-delete-null-pointer-checks to optional
It is no longer supported on El Capitan's clang, which was causing my
cmake/osx/qt build to fail with:

    clang: error: optimization flag '-fno-delete-null-pointer-checks' is not
    supported

Change-Id: Idfac336758cdea9a34446d8281cd237ad3ee6823
Reviewed-on: https://code.wireshark.org/review/11571
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Evan Huus <eapache@gmail.com>
2015-11-06 04:40:42 +00:00
Ryan Doyle 2014eb0ad3 CMake: Fix compatibility with CMake 3
The version of CMake I use (3.2.2) failed to parse the
CMakeLists.txt

Change-Id: I146c5a5ba8cd6fa6236b53039a31cc085bf5b460
Reviewed-on: https://code.wireshark.org/review/11392
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-29 20:59:50 +00:00
Gerald Combs 670475413a CMake: Use CMAKE_CL_64.
CMake sets CMAKE_CL_64 if we're using a 64-bit version of Visual Studio.
Use it.

Change-Id: I04595a0e703e39e428d853a506472f3881672a35
Reviewed-on: https://code.wireshark.org/review/11376
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-29 00:52:07 +00:00
Peter Wu fe1ab42f16 Require GnuTLS 2.12.0, add cmake version detection
Since v2.1.0rc0-17-g877fd03 and v2.0.0rc0-23-g263ff53 ("ssl-utils:
load RSA keys based on their modulus+exponent"), GnuTLS 2.12.0 is
needed.

Add a version check to cmake as well, tested on CentOS6 (with
pkg-config check disabled to verify the code path). Note that RHEL6
has GnuTLS 2.8.5 and thus SSL decryption with a RSA private key is no
longer supported on that version.

Change-Id: I99fdfe6790107f48629dd435794fe8880263063d
Reviewed-on: https://code.wireshark.org/review/11044
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2015-10-25 14:05:07 +00:00
Gerald Combs 1cecd985ab Pass --verbose to windeployqt.
Change-Id: I0adc2eb294c7165b9a327a70b2437916b228f044
Reviewed-on: https://code.wireshark.org/review/11219
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-22 21:11:32 +00:00
Peter Wu 1eba9d926b Avoid adding -pie on older cmake versions
Fixes building on Ubuntu 12.04 x86_64 which has cmake 2.8.7.

Bug: 11617
Change-Id: I253e9fda698d4b963d50516e483d8243231f056b
Reviewed-on: https://code.wireshark.org/review/11193
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Tested-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-10-22 06:16:24 +00:00
Peter Wu 82ec0bb0fc Require libgcrypt 1.4.2, add cmake version detection
libgcrypt 1.4.2 is required since since v1.11.0-rc1-2787-g23f9100
("Really add support for AEAD ciphers (GCM)") due to the use of
gcry_cipher_setctr. Bump the version in configure.ac too.

Add version check for gcrypt to cmake. Tested with CentOS 6 (cmake
2.8.12.2, libgcrypt 1.4.5).

Change-Id: I93c3ed902a764d9d14675779e866230d073c96d5
Reviewed-on: https://code.wireshark.org/review/11043
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-10-20 03:28:55 +00:00
Guy Harris 08a20705b4 Do -fPIC only if it's necessary.
Or, at least, undo the unconditional addition of -fPIC to
Qt5Widgets_EXECUTABLE_COMPILE_FLAGS, and add it back only if we need it
to compile a small test program that includes <QtCore>.

-fPIC still shows up for other reasons; perhaps we need to undo other
unconditional operations "helpfully" done by Qt5CoreConfigExtras.cmake.

Change-Id: I76c1b01b3dce7398e4115552bc4ff87bc775e027
Reviewed-on: https://code.wireshark.org/review/11079
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-19 21:17:52 +00:00
Joerg Mayer 94fee9e78f Move the static handling to a place where it is effective during package
discovery.
  More work needed to get static really working.

v2:
  - Rebase
  - Remove accidentally added macos-setup.sh changes

Change-Id: Ic3a68d2ab7064afffbf5dcfc90925699e8729780
Reviewed-on: https://code.wireshark.org/review/11082
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2015-10-17 10:40:44 +00:00
Gerald Combs b05803db4b CMake: Add /WX
Add "/WX" to the Visual C++ compiler flags if DISABLE_WERROR is off,
similar to config.nmake.

We haven't compiled C++ code with -Wshorten-64-to-32 for quite 
some time so there's no need to add -Wno-shorten-64-to-32 in
ui/qt/CMakeLists.txt.

Additionally, squelch

----
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\INCLUDE\algorithm(3050) : warning C4267: 'argument' : conversion from 'size_t' to 'int', possible loss of data (.\rpc_service_response_time_dialog.cpp)
        C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\INCLUDE\algorithm(3065) : see reference to function template instantiation 'void std::_Median<_RanIt,bool(__cdecl *)(const QString &,const QString &)>(_RanIt,_RanIt,_RanIt,_Pr)' being compiled
        with
        [
            _RanIt=QList<QString>::iterator
,            _Pr=bool (__cdecl *)(const QString &,const QString &)
        ]
        C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\INCLUDE\algorithm(3127) : see reference to function template instantiation 'std::pair<_RanIt,_RanIt> std::_Unguarded_partition<_RanIt,bool(__cdecl *)(const QString &,const QString &)>(_RanIt,_RanIt,_Pr)' being compiled
        with
        [
            _RanIt=QList<QString>::iterator
,            _Pr=bool (__cdecl *)(const QString &,const QString &)
        ]
        C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\INCLUDE\algorithm(3157) : see reference to function template instantiation 'void std::_Sort<_Iter,int,bool(__cdecl *)(const QString &,const QString &)>(_RanIt,_RanIt,_Diff,_Pr)' being compiled
        with
        [
            _Iter=QList<QString>::iterator
,            _RanIt=QList<QString>::iterator
,            _Diff=int
,            _Pr=bool (__cdecl *)(const QString &,const QString &)
        ]
        .\rpc_service_response_time_dialog.cpp(130) : see reference to function template instantiation 'void std::sort<QList<QString>::iterator,bool(__cdecl *)(const QString &,const QString &)>(_RanIt,_RanIt,_Pr)' being compiled
        with
        [
            _RanIt=QList<QString>::iterator
,            _Pr=bool (__cdecl *)(const QString &,const QString &)
        ]
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\INCLUDE\algorithm(3051) : warning C4267: 'argument' : conversion from 'size_t' to 'int', possible loss of data (.\rpc_service_response_time_dialog.cpp)
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\INCLUDE\algorithm(3052) : warning C4267: 'argument' : conversion from 'size_t' to 'int', possible loss of data (.\rpc_service_response_time_dialog.cpp)
C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\INCLUDE\algorithm(3053) : warning C4267: 'argument' : conversion from 'size_t' to 'int', possible loss of data (.\rpc_service_response_time_dialog.cpp)
----

in both rpc_service_response_time_dialog.cpp and wireshark_application.cpp
so that we'll compile successfully.

Change-Id: I457bcede99dcb1f3c1001f1f559c4901bb000357
Reviewed-on: https://code.wireshark.org/review/10533
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-16 21:32:22 +00:00
Gerald Combs 7682ae4887 Keep CMake from finding Cygwin's Python.
Try to find Python and set PYTHON_EXECUTABLE on Windows via the registry
prior to calling FindPythonInterp. This works around a bug in CMake that
prefers Cygwin's Python, which is a symlink, which by default is a text
file that contains a Cygwin-specific cookie, which is therefore useless
outside of Cygwin.

This is avoids the need to pass -DPYTHON_EXECUTABLE=... to CMake.

Change-Id: Ife37221b61d920682c20357b6d139a93067a5ad1
Reviewed-on: https://code.wireshark.org/review/11071
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-16 20:40:28 +00:00
Guy Harris b84b0315d3 Revert "Remove -fPIC with more than just MSVC."
This reverts commit 222de975c4.

I realized how to do it with a compile test.

Change-Id: I9468c50777e387c572f60411ca39ea86ba6ce520
Reviewed-on: https://code.wireshark.org/review/11078
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-16 02:31:27 +00:00
Guy Harris 1a94667cc3 Revert "+ OR OR OR OR OR"
This reverts commit 6bdfa95a1e.

Next I'll revert my change, as I realized how I *can* do it with a compile test, instead.

Change-Id: I75335ef4522af23340fdc9e5d68634cb5a5835d8
Reviewed-on: https://code.wireshark.org/review/11077
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-16 02:30:52 +00:00
Joerg Mayer 6bdfa95a1e + OR OR OR OR OR
Change-Id: I2e6480a519bd01a924a7145bc1e4e899e3fa1c1c
Reviewed-on: https://code.wireshark.org/review/11073
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2015-10-15 22:39:14 +00:00
Guy Harris 222de975c4 Remove -fPIC with more than just MSVC.
There are other compilers that won't like it or even that may not like
it.

Change-Id: I0d50e4217994bc930914c0fbcf1c5d2fc18a0e3a
Reviewed-on: https://code.wireshark.org/review/11072
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-15 22:04:11 +00:00
Gerald Combs 6ea71d9ad2 CMake: Don't feed -fPIC to Visual C++, second try.
Qt5CoreConfigExtras.cmake in Qt 5.5.0 sets -fPIC unconditionally.

Change-Id: Idf88b0f34b7cec40530702350b417ce1924db9f1
Reviewed-on: https://code.wireshark.org/review/11050
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-15 18:26:31 +00:00
Peter Wu 95804d94e8 cmake: avoid adding -fPIE to libraries (fixes gcc 4.7)
On Debian Wheezy, the cmake build would fail with:

    /usr/bin/ld: CMakeFiles/wsutil.dir/privileges.c.o: relocation
    R_X86_64_PC32 against symbol `started_with_special_privs' can not be
    used when making a shared object; recompile with -fPIC

Issue was introduced with v1.99.10rc0-222-g3fb1d68 ("cmake: Enable PIE
when it is available by default").

Bug: 11587
Change-Id: I62eec8d1db020128eeeb77b38e3316abf71e6e6a
Reviewed-on: https://code.wireshark.org/review/10916
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2015-10-14 22:49:47 +00:00
Peter Wu e059e45886 cmake: always enable -Qunused-arguments for clang
"argument unused during compilation" warnings suggest that some options
do not make sense (such as passing the -gsplit-dwarf option to the
linking command while it is only valid during compilation).

For now we do not care about these warnings, the option is accepted by
clang and whether it used in a particular step or not is uninteresting.

Change-Id: I3b6efa0dccd33c7f351c5938a29adef64ac1706d
Reviewed-on: https://code.wireshark.org/review/10893
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2015-10-14 16:53:21 +00:00
Guy Harris 9a702e41b0 If we have QtMultimedia with Qt4, add its libraries to the Qt libraries.
Change-Id: I41208287b87fba59d188e0db3bee36ee17cf3b18
Reviewed-on: https://code.wireshark.org/review/11006
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-14 09:10:56 +00:00
Guy Harris 4b73a29093 Add the directory for QtMultimedia to the list of include directories.
Change-Id: I670b42fcb3b8068ac9ac2809ae4445879444f554
Reviewed-on: https://code.wireshark.org/review/11000
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-14 07:50:17 +00:00
Guy Harris 66526f60c4 Set QT_MULTIMEDIA_LIB if we're using Qt 4 and have QtMultimedia.
Change-Id: Iee13fe86c0d8cacc71ab1cae25f4c735c5fe7b1d
Reviewed-on: https://code.wireshark.org/review/10993
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-14 04:07:58 +00:00
Peter Wu 01f82ee84c cmake: fix kerberos library lookup, support Heimdal
A build with the gold linker broke with:

    run/libwireshark.so.0.0.0: error: undefined reference to 'krb5_c_decrypt'

Fix this my restructuring the FindKERBEROS module to use the libraries
found by pkg-config.

While at it, check for MIT and Heimdal instead of assuming MIT. Remove
HAVE_KEYTYPE_ARCFOUR_56 as this macro is not used.

Change-Id: Iab23d79bc3f25e9c0fd7203b6f050f875fb4a2b5
Reviewed-on: https://code.wireshark.org/review/10907
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2015-10-13 07:36:30 +00:00
Guy Harris 177cf492dc Back out the verbose Makefile stuff.
I give up.  I don't know whether this all means our build mechanism is
too fragile, our code is to fragile, autotools are too fragile, the
compilers we're using are too fragile, Qt is too fragile, or C++ is too
fragile, but if the build breaks that easily, maybe we should just give
up on Leopard.

Change-Id: If700d928da95d09ed5173b976261e4ddd236d654
Reviewed-on: https://code.wireshark.org/review/10946
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-11 23:44:07 +00:00
Guy Harris 3d9f0db88a Temporarily make cmake builds verbose, for debugging purposes.
Try to figure out why CMake builds work on the 32-bit OS X buildbot but
autotools builds don't; either the compiler commands are different in
ways that break the autotools build, or the config.h files are different
in ways that break the autotools build, or magic pixies affect the
builds in different ways that only break the autotools build.

Change-Id: Id24bad04ff8ef755e4966e28fd445c2ab05c6913
Reviewed-on: https://code.wireshark.org/review/10931
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-11 04:59:07 +00:00
Gerald Combs 047c47e9a6 Initialize 2.1.
Change-Id: I515c53bb56cf82d1911b58f2cb2103afd0e597a5
Reviewed-on: https://code.wireshark.org/review/10810
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-05 20:11:12 +00:00
Peter Wu 6d7b29592a Allow use of variadic macros
Remove variadic macros restriction (c99, c++11 feature) from
README.developer. GCC, Clang, MSVC 2005 all support it.

Enable -Wno-variadic-macros in configure.ac and CMakeLists.txt when
-Wpedantic is enabled (which would enable -Wvariadic-macros).

For all files matching 'define\s*\w+[0-9]\(', replace "FOO[0-9]" by
"FOO" and adjust the macro definition accordingly. The nbap dissector
was regenerated after adjusting its template and .cnf file. The
generated code is the same since all files disabled the debug macros.

Discussed at:
https://www.wireshark.org/lists/wireshark-dev/201209/msg00142.html
https://www.wireshark.org/lists/wireshark-dev/201510/msg00012.html

Change-Id: I3b2e22487db817cbbaac774a592669a4f44314b2
Reviewed-on: https://code.wireshark.org/review/10781
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-10-05 07:57:14 +00:00
Gerald Combs 835cfa50cb Revert "CMake: Don't feed -fPIC to Visual C++."
This doesn't appear to fix the issue unfortunately.

This reverts commit fd5eafa50a.

Change-Id: Ida25881fca0a667c7d47692465b8f1fc9d335697
Reviewed-on: https://code.wireshark.org/review/10753
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-02 20:50:20 +00:00
Gerald Combs 3687d39304 Qt: Initial RTP playback.
Note the "initial". This is woefully incomplete.  See the "to do" lists
below and in the code.

This differs a bit from the GTK+ version in that you specify one or more
streams to be decoded.

Instead of showing waveforms in individual widgets, add them all to a
single QCustomPlot. This conserves screen real estate and lets us more
easily take advantage of the QCP API. It also looks better IMHO.

Change a bunch of checks for QtMultimediaWidgets to QtMultimedia. We
probably won't use the widgets until we make 5.0 our minimum Qt
version and plain old QtMultimedia lets us support Qt 4 more easily
(in theory at least).

Add resampling code from libspeex. I initially used this to resample
each packet to match the preferred rate of our output device, but this
resulted in poorer audio quality than expected. Leave it in and use to
create visual samples for QCP and to match rates any time the rate
changes. The latter is currently untested.

Add some debugging macros.

Note that both the RTP player and RTP analysis dialogs decode audio data
using different code.

Note that voip_calls_packet and voip_calls_init_tap appear to be dead
code.

To do:

- Add silence frames where needed.
- Implement the jitter buffer.
- Implement the playback timing controls.
- Tapping / scanning streams might be too slow.

Change-Id: I20dd3b66d3df53c9b1f3501262dc01458849f6b4
Bug: 9007
Reviewed-on: https://code.wireshark.org/review/10458
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-02 18:26:05 +00:00
Gerald Combs fd5eafa50a CMake: Don't feed -fPIC to Visual C++.
Change-Id: If6dd0619052b7735d7c5eb84aadc191545df7bee
Reviewed-on: https://code.wireshark.org/review/10735
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-02 15:52:24 +00:00
Gerald Combs 8976b78392 CMake: Fix the dmg_package target.
We don't have Wireshark.pkgproj so don't try to copy it.

Change-Id: I649fce27e53cbd45ffc50e4095252a665c49165d
Reviewed-on: https://code.wireshark.org/review/10739
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-02 01:25:30 +00:00
Gerald Combs cc9de69b49 Set the minimum Qt version to 4.7.
We've been using QElapsedTimer for a while now with no complaints. It
was introduced in Qt 4.7, which was first released in September 2010.

Change-Id: I21ca768c6a7bab8a08626957583d81fd771c64b4
Reviewed-on: https://code.wireshark.org/review/10732
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-01 22:28:51 +00:00
Gerald Combs cf3d279e04 CMake: OS X packaging updates.
Add a dmg_package_prep target as an alias to app_bundle. Rename the
osx-dmg target to dmg_package. This matches the Windows packaging
target names.

In osx-app.sh, make sure we rpathify the bundle plugin directory.

Change-Id: If41195c9d405ad6bff865625500a8227b77e8092
Reviewed-on: https://code.wireshark.org/review/10734
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-01 21:04:26 +00:00
Gerald Combs 7199fc7cab OS X: Integrate CMake and osx-dmg.sh
Change-Id: Ide608f5e73ecd40c67a6b1c0e16f11233cd49c9d
Reviewed-on: https://code.wireshark.org/review/10694
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-10-01 16:26:25 +00:00
Gerald Combs ff1dbba6ec CMake: Add a hardening-check target.
On Windows, add a hardening-check target which checks for DYNAMICBASE
and NXCOMPAT using the PowerShell script Get-HardenFlags.ps1.
For a Visual Studio solution, run the check by calling:

    msbuild /m /p:Configuration=RelWithDebInfo hardening-check.vcxproj

using the config as appropriate for your build.

Otherwise if we find the Debian/Fedora hardening-check script add a
target which runs it for each of our executables.

Change-Id: I62263e81d155c66e8c8edc751ffab535bf9f3b96
Reviewed-on: https://code.wireshark.org/review/10641
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-09-25 20:04:42 +00:00
Balint Reczey 3fb1d6853d cmake: Enable PIE when it is available by default
Change-Id: I88930b8a9de596f93677052b2046c1b85cc34c6b
Reviewed-on: https://code.wireshark.org/review/10635
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
2015-09-25 14:12:41 +00:00
Jeff Morriss 5eee0b9e44 Don't use any -fsanitize options unless we're using ASAN.
This lets cmake users configure without installing libusan.

A better or more final fix awaits a decision in bug 11009.

Change-Id: Iea6c4e2ce31817c17931a448f0c72da2a31a2e6d
Ping-Bug: 11009
Reviewed-on: https://code.wireshark.org/review/10454
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-09-10 11:59:56 +00:00
Bill Meier 7abd84216a Update comment about use of "/Zo" with MSVC2015
Change-Id: Ifb20e62a5e0719e1df2f7f6aba7a3935c7212c5b
Reviewed-on: https://code.wireshark.org/review/10364
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2015-09-02 19:08:52 +00:00
Gerald Combs c8bdb95d21 1.99.9 → 1.99.10.
Change-Id: I924be5b0e3c73a0bb8ae1361fa518ec10139e13d
Reviewed-on: https://code.wireshark.org/review/10363
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-09-02 18:29:10 +00:00
Joerg Mayer 57b2b77022 cmake: rework version.h handling to treat it like config.h
It wasn't working on my system: I kept seeing the old git revision
in '...shark -v' even after deleting version.h

Change-Id: I75f41a7afcee4b9384f33a56014e4af6b527fec5
Reviewed-on: https://code.wireshark.org/review/10265
Petri-Dish: Jörg Mayer <jmayer@loplof.de>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2015-08-26 07:37:02 +00:00
Anders 738cf424d6 Make building with MSVC2015 work
TODO:

- LUA is commented out probably needs to be built with MSVC 2015.
- GeoIP is commented out, causes packet-ip* to not build.
- Qt not built, needs Qt with MSVC 2015

Change-Id: I1658077931b89b9a22ee32e5ed7de38e07fb6a55
Reviewed-on: https://code.wireshark.org/review/8683
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-08-13 12:03:53 +00:00
Gerald Combs 4d673b24cd Convert Camel tap stats to new "generic stat API".
Migrate the Camel stats similar to the recent BOOTP and H.225
migrations.

Change-Id: If82617068ff4b8fa186899f66dc34a08585f66cb
Reviewed-on: https://code.wireshark.org/review/9865
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-08-04 19:12:00 +00:00
Gerald Combs 3e6b527114 Remove the CLI H.225 counter.
Stats were moved to the dissector in g03802cc.

Change-Id: I1aaf43789695ba3aae54cfaf201263cd0aed74ea
Reviewed-on: https://code.wireshark.org/review/9867
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-08-04 18:55:50 +00:00
Gerald Combs efefdbbd76 1.99.8 → 1.99.9.
Change-Id: I014399c332136a10b1c560d4c68be5b8bab97552
Reviewed-on: https://code.wireshark.org/review/9780
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-07-24 19:06:50 +00:00
Guy Harris 2e215db532 Revert "On OS X, add the Qt -Wl,-rpath hack in CMake, as we do with autotools."
This reverts commit 4a39706272.

At least in one quick check, CMake 2.8.12.2 added that already with Qt 5.5.0.

Change-Id: Iabf0e4aa0aa34b380f981f7d039fb3d95847041e
Reviewed-on: https://code.wireshark.org/review/9654
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-15 23:46:58 +00:00
Guy Harris 4a39706272 On OS X, add the Qt -Wl,-rpath hack in CMake, as we do with autotools.
Change-Id: I281e1bf790b7eefbbd43a3406622262cfe8b36df
Reviewed-on: https://code.wireshark.org/review/9651
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-15 23:05:26 +00:00
Guy Harris cab4450935 The toolkit is called "Qt", not "QT".
Change-Id: If6c0c66bc429a041b3454f1f2355d4659cb17bbf
Reviewed-on: https://code.wireshark.org/review/9630
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-13 23:22:06 +00:00
Guy Harris c6aa2b5b2c Don't add rpaths with CMake, either; osx-app.sh will do so.
Change-Id: Ie8f39e5e89ed8dc21c66ee7f1235c406c3028304
Reviewed-on: https://code.wireshark.org/review/9613
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-07-13 02:55:01 +00:00
Graham Bloice c00e4697e2 Fix Windows CMake generated installer to include snmp mibs
Wireshark.nsi requires SMI_DIR to point to the base of the SMI directory
but FindSMI.cmake doesn't set it.  Set it in the main CMakeLists.txt

Change-Id: Id667341273d6abb0d2d64ef91cc62d1ce3f42a83
Reviewed-on: https://code.wireshark.org/review/9499
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-07-05 16:36:53 +00:00
Michael Mann 7fdc534cf9 Convert BOOTP/DHCP tap stats to new "generic stat API".
Change-Id: I0edc3909516452e6497a050b4617f9aafcea2688
Reviewed-on: https://code.wireshark.org/review/9112
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-07-03 23:08:51 +00:00
Michael Mann a8ff1e2778 Create very basic "generic" stat tap API to create a "GUI" independent table.
A few sample tap/dissectors (ANSI/A, ANSI MAP) are also included to test the API.  The "GUI output" is a bit raw and could use some "prettying up", but all the basic hooks are there.

Telephony "stat grouping" needs to be better alphabetized to properly populate menu (on GTK, probably Qt)

Change-Id: I98514171f69c4ab3a304dccb26c71d629703c9ab
Reviewed-on: https://code.wireshark.org/review/9110
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-07-03 23:08:28 +00:00
Michael Mann 6fe3f2c693 Use RTD functionality for H.225
This got missed in the initial refactoring.

Change-Id: I98dcc0816e065efab9b497f753c8d2d388349ff3
Reviewed-on: https://code.wireshark.org/review/9044
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-06-23 13:08:57 +00:00
Michael Mann 8f390d4975 Refactor RTD stats.
Very similar to the refactoring of SRT stats, it provides more commonality of the stats for all GUI interfaces.  Currently implemented for TShark and GTK.  Affected dissectors: MEGACO, MGCP, Radius

Change-Id: Icb73a7e603dc3502b39bf696227fcaae37d4ed21
Reviewed-on: https://code.wireshark.org/review/8998
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-22 15:13:39 +00:00
Michael Mann 6de6f7f0f8 Further refactor SRT stats.
Create "common" SRT tap data collection intended for all GUIs.   Refactor/merge functionality of existing dissectors that have SRT support (AFP, DCERPC, Diameter, FC, GTP, LDAP, NCP, RPC, SCIS, SMB, and SMB2) for both TShark and GTK.

SMB and DCERPC "tap packet filtering" were different between TShark and GTK, so I went with GTK filter logic.
CAMEL "tap packet filtering" was different between TShark and GTK, so GTK filtering logic was pushed to the dissector and the TShark tap was left alone.

Change-Id: I7d6eaad0673fe628ef337f9165d7ed94f4a5e1cc
Reviewed-on: https://code.wireshark.org/review/8894
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-06-21 03:35:13 +00:00
Gerald Combs f00e6fbefe 1.99.7 → 1.99.8
Change-Id: I3423fd2959b1031480f15504ce38336ce3475b17
Reviewed-on: https://code.wireshark.org/review/8979
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-06-18 20:04:03 +00:00
Graham Bloice 678c5d5da6 Fix the CMake windows installer to pickup the locally built zlib1.dll
Change-Id: I8880a760d9817dd038694e96b4a3d9b8d2db3c2c
Reviewed-on: https://code.wireshark.org/review/8931
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-06-15 20:30:31 +00:00
Graham Bloice aeb6419145 Separate Windows CMake compiler definitions and flags
Change-Id: I70af6d43f45e2110ee7707ff5747b5e990ba7238
Reviewed-on: https://code.wireshark.org/review/8926
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-06-15 14:34:41 +00:00
Graham Bloice a57398dacb Fix some CMake compiler tests for Win64
Change-Id: I03244b48e6593d1fe5f4d139fa5d171debeb9fd7
Reviewed-on: https://code.wireshark.org/review/8909
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-06-12 20:36:37 +00:00
Graham Bloice 2adeb9969f Fix OSX CMake warnings
Set the CMake policy for CMP0042 to old

Change-Id: I2b71e1d8d9b9b90ede11df1a7874a2360c3032c5
Reviewed-on: https://code.wireshark.org/review/8740
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-03 08:00:10 +00:00
Graham Bloice 7780159c03 Fix zlib cmake
Add support for the locally modified version of zlib to suppress
a CMake warning and disable building of the zlib examples.

Change-Id: I9ae08b49d149951e8626d506f69f1757a1ec7e23
Reviewed-on: https://code.wireshark.org/review/8706
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-05-31 18:15:06 +00:00
Gerald Combs 1955dd2dec 1.99.6 → 1.99.7.
Change-Id: I8c431f162d199c8507ba57d84e496dce5f5a0933
Reviewed-on: https://code.wireshark.org/review/8677
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-05-28 20:29:06 +00:00
Graham Bloice d64d87f44e Fix CMake warnings
Rename a local CMake variable to prevent CMP0054 warnings in
CheckTypeSize and CheckStructHasMember modules.

Change-Id: Ida0df954c81333ad37455db90e0d72ca9df8c6f1
Reviewed-on: https://code.wireshark.org/review/8522
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-05-19 09:32:56 +00:00
Gerald Combs cc02069407 CMake: Try to fix version.h dependencies.
Make the gitversion target depend on version.h instead of running
make-version.pl separately. Make wsutil and qtui depend on gitversion.

Change-Id: I32f25347c12c7f86b2439ed4bf517cc8f5fb106f
Reviewed-on: https://code.wireshark.org/review/8299
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-05-05 18:40:46 +00:00
Michael Mann 91515a0081 Add tshark -z "ncp,srt"
Change-Id: Iab2559c2bac5550987c108c6e917506fcec525e9
Reviewed-on: https://code.wireshark.org/review/8221
Reviewed-by: Michael Mann <mmann78@netscape.net>
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-01 06:04:12 +00:00
Gerald Combs fac11078c3 CMake: Always set PROCESSOR_ARCHITECTURE on Windows.
An undefined or invalid PROCESSOR_ARCHITECTURE will produce an invalid
wireshark.exe.manifest. Make sure it's always set.

Change-Id: I1b33f7bd5e964f05344919d1f11d88c14104c0ce
Reviewed-on: https://code.wireshark.org/review/8253
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-30 20:28:31 +00:00
Graham Bloice e00312360e CMake for Windows improvements
Allow the wireshark libs directory to be defined by WIRESHARK_LIB_DIR.
Ensure either WIRESHARK_LIB_DIR or WIRESHARK_BASE_DIR is defined.
Ensure the compiler is a supported version (VS2010, 12 or 13).

Change-Id: I0abd371c5773c08ca255abe308d1a59e2e290a02
Reviewed-on: https://code.wireshark.org/review/8247
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-30 15:18:16 +00:00
Graham Bloice 0d37980a0b CMake Windows fixes
Set the minimum version for Windows to 3.1.3
Set the policy for CMP0054 to squelch a few warnings.

Change-Id: I7647a0e5dce83db2cd87d7b8048c808e10863c7e
Reviewed-on: https://code.wireshark.org/review/8241
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-29 22:51:33 +00:00
Michael Mann 0b368ea23f Add service_response_time_table for TShark srt stats.
This is a "refactoring part 1" of the srt stats.  This first step is using the service_response_time_table for all (possible) TShark srt stats.  Next step will be combining the GTK and TShark service_response_time_table, so there is more code reuse and the "shared structure names" between GTK and TShark service_response_time_table won't seem as bad.

Maybe it can even go one step farther and handle a dynamic number of columns so this refactoring can apply to all srt stats.

Change-Id: Ief28e7e55f7dbbf4f2d9bb6f1a1592b87b866137
Reviewed-on: https://code.wireshark.org/review/8210
Reviewed-by: Michael Mann <mmann78@netscape.net>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-04-28 07:37:14 +00:00
Michael Mann 8c996a2736 Add tshark -z "smb2,srt"
Change-Id: I66247132f00c83f35cf78cb63ea00a5ce923fddb
Reviewed-on: https://code.wireshark.org/review/8211
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-04-28 04:22:36 +00:00
Michael Mann 0b97f0dcf3 Add tshark -z "ldap,srt"
Bug: 9363
Change-Id: Ic64716ef0156607ca40773cef8e76fc4a0825b3c
Reviewed-on: https://code.wireshark.org/review/8196
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-04-27 23:18:50 +00:00
Graham Bloice 7d6a1e7da2 CMake fix windows setup
Standardise the args to win-setup.ps1

Change-Id: Ibd9d7bb338edb1cef444abc37a7b103eec38fb09
Reviewed-on: https://code.wireshark.org/review/8173
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-23 12:49:22 +00:00
michal.orynicz 448e122ea5 [Androiddump] Fix CMake install path for androiddump
Changed path from "share" to one based on plugns path
For example /usr/local/lib/wireshark/extcap

Change-Id: I8f4a9f274b1cec897ed45de9e05679ac3f230301
Reviewed-on: https://code.wireshark.org/review/8161
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
Tested-by: Balint Reczey <balint@balintreczey.hu>
2015-04-21 12:49:48 +00:00
Graham Bloice 4e9ff477d9 CMake minor updates
Fix up generation messages for Windows build
Remove some superfluous Lua messages

Change-Id: I405e7edfcb043fc842fe4f0cca8d23d5755527f9
Reviewed-on: https://code.wireshark.org/review/8138
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-20 16:46:38 +00:00
Gerald Combs 3d7b728173 Make androiddump loadable on OS X.
Make sure the target location for extcap executables and extcap_dir
match on OS X.

Set the extcap directory to Contents/MacOS/extcap. The Mac Developer
Library documentation doesn't explicitly define "Resources", but
examples include data files and not executables. It does state that
executables shouldn't go into PlugIns.

Make sure we rpathify androiddump.

Change-Id: If36c762e2a1991c26e5c01a870deaf191bcf9f94
Reviewed-on: https://code.wireshark.org/review/8093
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-17 18:08:36 +00:00
Graham Bloice e280df605f Fix CMake warnings
Newer versions of CMake generate warnings about the use of
@variable@ references, replace @CPACK_PACKAGE_NAME@ with
${CPACK_PACKAGE_NAME}

Set the policy for CMP0026 to be old to squelch warnings about the
use of target LOCATION

Change-Id: I424083260c51875dde80f98a23d6528c31ff0aec
Reviewed-on: https://code.wireshark.org/review/7977
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-17 16:09:22 +00:00
Michal Labedzki 1948d026f6 androiddump: Fix build on onther than Win platforms
androiddump should be put in extcat directory.

Change-Id: I360eef2d5a68178c73181949b0fe3346585f5190
Reviewed-on: https://code.wireshark.org/review/8083
Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-04-17 16:03:48 +00:00
Gerald Combs 76d355de26 CMake: Set WIN32 for GUI executables.
Pass WIN32 to add_executable where needed. Require CMake 2.8.11
on Windows.

Change-Id: I6a119bbb0f16f9e21f2e7378bae7ed52b8abb2dc
Reviewed-on: https://code.wireshark.org/review/8091
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-17 09:10:22 +00:00
Balint Reczey 2d79f56df1 Fix wireshark.pc when CMAKE_INSTALL_LIBDIR is absolute
Change-Id: I9667660329c0888f35e1ac332537eda995509a85
Reviewed-on: https://code.wireshark.org/review/8010
Reviewed-by: Balint Reczey <balint@balintreczey.hu>
2015-04-16 10:21:48 +00:00
Gerald Combs b845785a73 CMake: Try not to clobber our gspawn exes.
Try not to overwrite gspawn*.exe between signing them and packaging
them. (Second try.)

Change-Id: I717f5fca6dc6afbc146927d06e6f74ae6a0a87c8
Reviewed-on: https://code.wireshark.org/review/8082
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-15 23:24:59 +00:00
Gerald Combs 973b2884c6 Revert "CMake: Try not to clobber our gspawn exes."
This accidentally reverted code from g40ce324. Will try again shortly.

This reverts commit 8d9fdda991.

Change-Id: I0bf7f351b926f1ce4b0c9e19fe0367add1dfee1e
Reviewed-on: https://code.wireshark.org/review/8081
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-15 23:22:34 +00:00
Gerald Combs 8d9fdda991 CMake: Try not to clobber our gspawn exes.
Try not to overwrite gspawn*.exe between signing them and packaging them.

Change-Id: I9f224b64537c3b0dd6f7f8b94a8837bd427ad2ca
Reviewed-on: https://code.wireshark.org/review/8080
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-15 22:19:47 +00:00
Gerald Combs 40ce324f4d Set the extcap working directory on Windows.
On Windows, prepend the main program directory to %Path% when spawning
extcap processes. This lets us place androiddump in extcap while allowing
it to locate its DLLs.

Change-Id: I406c47ce71323266d5f14fb596931398464e452d
Reviewed-on: https://code.wireshark.org/review/8057
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-15 20:26:13 +00:00
Gerald Combs 495740f801 CMake: Initial PortableApps targets.
Add portableapps_app_dir and portableapps_package targets.

Change-Id: Ifea3d952eef0e267de6364999d45807236d99102
Reviewed-on: https://code.wireshark.org/review/8025
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-14 19:11:50 +00:00
Gerald Combs 1404605513 Start moving win-setup to PowerShell.
Add win-setup.ps1, which duplicates the following tasks performed by
config.nmake + Makefile.nmake + win-setup.sh:

- Create the windows library directory.
- Download files.
- Download and unpack zip files.
- Check and set current-tag.txt

Don't verify applications or libraries. CMakeLists.txt does that.

Update the Developer's Guide.

Have POWERSHELL_COMMAND use dot sourcing instead of "-File", which
appears to be a synonym for "-IgnoreTheExitStatusReturnedByThisScript".

This removes our dependencies on unzip and wget and reduces our dependency
on bash.

Change-Id: Ia9def24acbe183d81b9d477fa42e655e4a3a6614
Reviewed-on: https://code.wireshark.org/review/7990
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-14 19:09:30 +00:00
Gerald Combs 035d741289 Fix zlib DLL copy.
Switch to "if exist ... xcopy".

Change-Id: I255fd3e719645b247024583590b748104c5e15b9
Reviewed-on: https://code.wireshark.org/review/8056
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-13 22:23:48 +00:00
Gerald Combs f333e7ed67 Add the OpenSUSE zlib1.dll when needed.
The Visual Studio solution files created by CMake list "Debug" as the
first configuration, which means that we end up with zlibd1.dll by
default. Many of the OpenSUSE DLLs depend on zlib1.dll. Add the OBS
version in that case.

Change-Id: Ia98490f1a192802d1482e0749bbd2b550e916bc5
Reviewed-on: https://code.wireshark.org/review/8051
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-13 17:49:19 +00:00
Michal Labedzki 56470cc801 Add missing androiddump stuff
Add missing androiddump stuff like:
- release notes
- documentation
- Windows nmake support
- running androiddump as a windows application instead of console on Windows
- addition of androiddump to the Windows installer

Change-Id: I3bc6cc70e4dc96c0cd776f3d965dd2aa0309995d
Reviewed-on: https://code.wireshark.org/review/7981
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-04-12 16:34:46 +00:00
Gerald Combs 38d3e063d3 CMake: Add a build environment == generator check.
If we're building on Windows and %Platform% is "x64" or undefined,
check it against our generator's target platform.

Update the "${CMAKE_GENERATOR} MATCHES" regexes to match what CMake
uses internally.

Change-Id: I33996344978855cbdf7c1ee9e55b7340efea5b5c
Reviewed-on: https://code.wireshark.org/review/7994
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-10 09:33:56 +00:00
Graham Bloice 08c223a53a Cleanup CMake VS solution
Move the zlib artefacts into Libs\zlib "folder"

Change-Id: Iddf0121fad3885553d908a51e9e07a7f676403fe
Reviewed-on: https://code.wireshark.org/review/7993
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-09 09:57:36 +00:00
Graham Bloice 5b0d5ca4a5 Fix CMake build for Windows
The change to zlib 1.28 requires the variable BUILD_SHARED_LIBS
to be set and true to build the correct zlib dll on Windows.

Change-Id: I0f46b832726834a4e99d7d7d0637112da9c0c531
Reviewed-on: https://code.wireshark.org/review/7982
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-08 16:26:32 +00:00
Michal Labedzki b99cf21c25 extcap: Add support for Android - androiddump
androiddump is extcap program that can be used with Android devices
(need Android SDK in system PATH). Supported is Logcat/Logger logs and
Bluetooth interfaces for all Android to this day (Lollipop).

Please note that it will work also for FirefoxOS.

Interfaces:
1. Logcat Main (binary or text)
2. Logcat System (binary or text)
3. Logcat Events (binary or text)
4. Logcat Radio (binary or text)
5. Logcat Crash (text; Lollipop)
6. Bluetooth Hcidump (<Kitkat)
7. Bluetooth Bluedroid External Parser (Kitkat)
8. Bluetooth BtsnoopNet (Lollipop)

Change-Id: I26e4cd1a37a6af805f8b932399b4aa44ee7b5a80
Reviewed-on: https://code.wireshark.org/review/7475
Petri-Dish: Michal Labedzki <michal.labedzki@tieto.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michal Labedzki <michal.labedzki@tieto.com>
Tested-by: Michal Labedzki <michal.labedzki@tieto.com>
2015-04-08 09:57:24 +00:00
Graham Bloice 69a435bb08 Add zlib compilation to CMake on Windows
Modify CMake to compile zlib, removing need for an nmake compilation
of zlib before running CMake.

Change-Id: I63cead55b14d6a2e22b1b6a8536eaf9260e21231
Reviewed-on: https://code.wireshark.org/review/7864
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-04-07 20:51:26 +00:00
Gerald Combs 7787c1b464 Fixup our anonsvn URLs.
Change-Id: Id18d392bf7ff948fc78b684d8222c5c3725d302a
Reviewed-on: https://code.wireshark.org/review/7886
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-04-02 19:21:41 +00:00
Graham Bloice 01947acc5a CMake updates for Windows build
Removed the redundant setpath batch file and associated macro
and updated docs.

Change-Id: I5ddab6bad2d14ed3443194d7269f1890e4aa608e
Reviewed-on: https://code.wireshark.org/review/7826
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-03-26 16:58:53 +00:00
Graham Bloice 680dfc1e2f CMake cleanup for VS solution
Add FOLDER properties to targets to tidy up the VS solution

Change-Id: Ia42e0e89fb490cd3dcd33b7c5f59eb0a27b74c7a
Reviewed-on: https://code.wireshark.org/review/7822
Petri-Dish: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
2015-03-26 10:35:30 +00:00
Peter Wu 68698db8cc Always use html2text.py for FAQ, improve output
A recent commit broke compilation with Python 3. The original author of
html2text.py is deceased and the fork has increased the number of files
for this "simple" helper.

The html2text.py script in this patch was rewritten and its output
matches with lynx (except for a few newlines around lists). This means
that indentation has been added for headings, paragraphs and lists.
Also, since it was written from scratch, a new license could be chosen
that matches Wireshark.

Since now the in-tree html2text.py script provides nicer output, remove
detection of the alternative programs (elinks, links). lynx/w3m is
somehow still necessary for asciidoc though.

(I also looked into reusing html2text.py for the release notes to
replace asciidoc, but the --format=html output produces different output
(HTML adds a ToC and section numbers). For now still require lynx for
release notes)

Tested with Python 2.6.6, 2.7.9, 3.2.6 and 3.4.3 under LC_ALL=C and
LC_ALL=en_US.UTF-8 on Linux. Tested reading from stdin and file, writing
to file, pipe and tty. Tested with cmake (Ninja) and autotools on Arch
Linux x86_64. Test:

    # For each $PATH per python version, execute (with varying LC_ALL)
    help/faq.py -b | tools/html2text.py /dev/stdin | md5sum
    help/faq.py -b | tools/html2text.py | md5sum
    help/faq.py -b | tools/html2text.py
    help/faq.py -b | tools/html2text.py >/dev/null

Change-Id: I6409450a3e6c8b010ca082251f9db7358b0cc2fd
Reviewed-on: https://code.wireshark.org/review/7779
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-03-25 07:08:52 +00:00
Gerald Combs 019c3af0b1 1.99.5 → 1.99.6.
Change-Id: Iff642606bdb9858dc54b90abe02bf1572f44fc25
Reviewed-on: https://code.wireshark.org/review/7766
Reviewed-by: Gerald Combs <gerald@wireshark.org>
2015-03-20 00:53:49 +00:00