aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
AgeCommit message (Collapse)AuthorFilesLines
2019-06-17CMakeList: We require minimum c++11Anders Broman1-0/+5
Change-Id: I685901dac2e950678362b3b8759c22dceec39176 Reviewed-on: https://code.wireshark.org/review/33636 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-06-13sharkd: link with libm because of SpeexJaap Keuter1-0/+1
When builing without the Speex library the build inserts its own files to handle the codec conversion. These however require sharkd to be linked against libm, for the sine function. Change-Id: I80b3fd67a346849480976c00280537b786780627 Reviewed-on: https://code.wireshark.org/review/33582 Reviewed-by: Vasil Velichkov <vvvelichkov@gmail.com> Petri-Dish: Jaap Keuter <jaap.keuter@xs4all.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-06-11Kill libwscodecs plugin library, just use pluginsJoão Valverde1-4/+0
Change-Id: I085d04840acb53b0b7681787429a2b4e10547cd5 Reviewed-on: https://code.wireshark.org/review/33068 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-06-11Move codec plugins to /pluginsJoão Valverde1-0/+17
Change-Id: I56d61e2ef737e4326080d75a2302c73a4075e8a1 Reviewed-on: https://code.wireshark.org/review/33067 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-06-05ship the dfilter_macros file.Dario Lombardo1-0/+1
By providing such a file, we give the users a basic toolbox of macros. At the moment 3 macros have been added, for private mac addresses, as well al IP v4 and v6. Change-Id: Icc33efce437adef00e268172c184c8b52167df23 Reviewed-on: https://code.wireshark.org/review/33449 Petri-Dish: Dario Lombardo <lomato@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-05-24CMake+macOS: Use symlinks for our CLI utilities.Gerald Combs1-7/+13
On macOS, <build directory>/run/wireshark is a wrapper script that execs run/Wireshark.app/Contents/MacOS/Wireshark so that Launch Services will activate our application properly. We don't need to worry about this for our other executables. Make them symlinks so that we can run things like `lldb run/tshark` with impunity. Change-Id: I4e656d778040ece722f873b1a7f6e6e60d21e2a6 Reviewed-on: https://code.wireshark.org/review/33071 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-05-16Enable -Wpointer-sign if we're enabling additional compiler warnings.Guy Harris1-1/+14
Or, rather, *disable* it only if we're *not* enabling additional compiler warnings. Change-Id: I95c23385a365e0e24f932ea5c680b287b5f717e0 Reviewed-on: https://code.wireshark.org/review/33237 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <guy@alum.mit.edu>
2019-05-03CMake: Add libpcap imported library targetJoão Valverde1-2/+1
Change-Id: I5326b87784817fb353329e2d686fe0515c32f6cb Reviewed-on: https://code.wireshark.org/review/33038 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl> Reviewed-by: João Valverde <j@v6e.pt>
2019-05-02CMake: Check for and use system SpeexDSP libraryJoão Valverde1-0/+23
Change-Id: I8443379d23a2946dd21c12e5e0bd5464ab73ca25 Reviewed-on: https://code.wireshark.org/review/31857 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2019-05-01Windows: Modernize our WSAStartup usage.Gerald Combs1-4/+6
Make sure we link each application that calls WSAStartup with ws2_32.lib. Pass version 2.2 to WSAStartup. Wikipedia says it was introduced in 1996, so we should be OK. Ping-Bug: 15711 Change-Id: I431839e930e7c646669af7373789640b5180ec28 Reviewed-on: https://code.wireshark.org/review/33033 Petri-Dish: Gerald Combs <gerald@wireshark.org> Reviewed-by: Tomasz Moń <desowin@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-04-23CMake: add USE_STATIC optionFabrice Fontaine1-1/+5
USE_STATIC will: - always link statically with external libraries (such as glib2) - will not set rpath to avoid the following error: CMake Error at cmake_install.cmake:50 (file): file RPATH_CHANGE could not write new RPATH: /usr/lib to the file: /home/fabrice/br-test-pkg/br-arm-full-static/target/usr/bin/tshark No valid ELF RPATH or RUNPATH entry exists in the file; Change-Id: I242dc1a091cc211ee891568a2dee5080c9974fba Ping-Bug: 15713 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> Reviewed-on: https://code.wireshark.org/review/32945 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-04-22Add brotli decompression support for HTTP and HTTP2 dissectors.Dániel Bakai1-0/+11
Change-Id: I9c09f55673187f6fee723fcd72798fb6b9958b03 Reviewed-on: https://code.wireshark.org/review/32745 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-04-20CMake: fix Windows build when all binaries are disabledPeter Wu1-14/+16
CLEAN_C_FILES is empty if all BUILD_xxx options are disabled. Bug: 15662 Change-Id: I133b4d00336eb17f7eaeb0d6517ed83c30180373 Reviewed-on: https://code.wireshark.org/review/32895 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-04-20CMake: silence -Wunsafe-loop-optimizations for GCC 7Peter Wu1-5/+10
Clang does not implement this option, so do not bother checking it there. GCC 6 is fine, GCC 7 is broken and GCC 8 is fixed again. Change-Id: I3bc9ff4e934e05b1b3ce7d4c4a41bf40d6e38655 Reviewed-on: https://code.wireshark.org/review/32904 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <guy@alum.mit.edu> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-04-19CMake: bail out if minimum GLib version is not satisfiedPeter Wu1-2/+1
Require glibconfig.h to be found and extract the version from this file, this has been present since the original GLib commit and is still present in the meson build system introduced with 2.53.4. Bug: 15706 Change-Id: I2e938a339d48d6815ed7cc46462735b93418377f Reviewed-on: https://code.wireshark.org/review/32894 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-04-09Windows: Use an lz4 DLL built with vcpkg.Gerald Combs1-0/+1
Update the Windows build environment to use lz4 packages built from a VS 2017 command prompt with set LZ4_VERSION=1.8.3 vcpkg remove lz4:x86-windows lz4:x64-windows vcpkg install lz4:x86-windows lz4:x64-windows vcpkg export lz4:x86-windows --output=lz4-%LZ4_VERSION%-win32ws --zip vcpkg export lz4:x64-windows --output=lz4-%LZ4_VERSION%-win64ws --zip The packages also include a PDB, so copy it to the build directory and add it to the PDB .zip. Change-Id: Icea512405d2085e5b271fa4a3ba8c0fe318b8cb5 Reviewed-on: https://code.wireshark.org/review/32785 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-04-03CMake: Require pod2man and pod2html.Gerald Combs1-1/+1
Require the POD package. Some platforms ship POD translators as a separate package instead of shipping them with Perl. Bug: 15513 Change-Id: Ie277f9296d06063581512bc4c2df1d3158117f2c Reviewed-on: https://code.wireshark.org/review/32685 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-03-18NSIS: Fix our extra installer location.Gerald Combs1-0/+2
We know the native Windows library path early on in the configure process. Use it to set the location of the Npcap and USBPcap installers instead of trying to derive it from the GLib DLL path. Change-Id: I02d48e115b374fb6080a7fe8017cba789254d5f1 Reviewed-on: https://code.wireshark.org/review/32475 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-03-18Windows: Start using a `vcpkg export` bundle.Gerald Combs1-31/+14
Create a library bundle using `vcpkg export ... --zip` as described at https://vcpkg.readthedocs.io/en/latest/users/integration/#export-command. The bundle includes the following packages: gettext 0.19-8 glib 2.52.3-13 libffi 3.1-4 libiconv 1.15-5 liblzma 5.2.4 libxml2 2.9.9-4 pcre 8.41-1 zlib 1.2.11-5 It also includes a CMake toolchain file which we might want to make use of in the future. This means we no longer compile Zlib locally. Update the CMake environment accordingly and remove zlib from win-setup.ps1. It includes PDBs, so add them to the PDB .zip. Change-Id: I0a94904a86d836e990019dab62af506573be1f35 Reviewed-on: https://code.wireshark.org/review/31377 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-02-16Re-implement "Map" feature for EndpointsPeter Wu1-0/+1
This feature was removed in v2.5.1rc0-427-gf529ab5d0a, anticipating that MaxMind would remove support for it in 2019. They have however changed their mind and maintained latitude and longitude information. They recommend displaying an accuracy radius, but the reported values are 50, 100, 200 and 1000km. When implemented literally, a marker in Ireland would cover the whole island plus mainland, so I have instead opted to use a fixed radius of 1km at deeper zoom levels. The old ipmap.html file was outdated and had broken tiles, I rewrote a new one from scratch using the light-weight Leaflet library combined with tiles from OpenStreetMap. This is more mobile-friendly and secure (https, SRI). To improve handling of nearby or overlapping nodes, clustering is used (individual nodes can still be inspected). Browser compatibility results: IE8 is unusable, IE9 partially works (tooltips sometimes disappear and the cluster radius control is gone), IE11 works. Of course Firefox 65 and Chromium 72 have no issues. The map popup description in the generated GeoJSON structure is now split in several properties, allowing presentation to be handled by the HTML page instead of the C code. Bug: 14693 Change-Id: If2ec9c518f7723ac0ab27b6272463356875a0ff2 Reviewed-on: https://code.wireshark.org/review/31952 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-02-14Convert the FAQ to Asciidoctor and remove old help files.Gerald Combs1-55/+3
Convert our self-generating FAQ to Asciidoctor via the following steps: - `help/faq.py > /tmp/faq.html`. - `pandoc -t asciidoc -o docbook/faq.adoc /tmp/faq.html`. - Manually clean up the markup using a text editor. Question and answer content was left intact. Removing or updating obsolete content will have to be done in a separate change. The Asciidoctor project uses the .adoc extension, so start using it here as well. The contents of the "help" directory appear to have been used for offline support in help_url.c, but that functionality was removed in 2008 in 242e3b78bc. Its content is covered in the User's Guide and man pages so remove it. Change-Id: I9060eefe97cfc137f8b414077c30f814379b576a Reviewed-on: https://code.wireshark.org/review/32014 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-02-14CMake: Move the PLUGIN_PATH_ID definition.Gerald Combs1-17/+18
Define PLUGIN_PATH_ID where we use it. ENABLE_APPLICATION_BUNDLE is defined later on, so test for APPLE instead. Change-Id: I16c3ac3dc0e483fbf89cb1a2cacb2afb416d656f Reviewed-on: https://code.wireshark.org/review/32016 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-02-13macOS: Fix our plugin path.Gerald Combs1-19/+21
In CMake we only used PROJECT_RELEASE_VERSION to construct our plugin path, so rename it to PLUGIN_PATH_ID. Use a dash to separate version numbers on macOS in order to allow code signing and a period elsewhere. In the C code we only used VERSION_RELEASE to construct our plugin path, so rename it to PLUGIN_PATH_ID. Change-Id: I02abc591d7857269e8d47b414b61df4b28a25f2d Reviewed-on: https://code.wireshark.org/review/32013 Petri-Dish: Gerald Combs <gerald@wireshark.org> Reviewed-by: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-02-13CMake: disable relocatable builds when dumpcap is being builtPeter Wu1-1/+11
dumpcap with capabilities/setuid currently does not start due to missing libwsutil when installed to a non-standard prefix such as /usr/local. Bug: 15490 Change-Id: If7427ba9625d3702ab8aac2deeaf37b6d3fda2a0 Reviewed-on: https://code.wireshark.org/review/31995 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-02-13Indicate what changes to make if we remove the version component.Guy Harris1-4/+10
Change-Id: I32fff5c34cfdb15a8102d2657e3380cf66928f66 Reviewed-on: https://code.wireshark.org/review/32002 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2019-02-13Fix directory containing compiled plugins in macOS.Guy Harris1-6/+11
They weren't getting put in the version-number subdirectory, so the plugin loader wasn't finding them. If that causes problems with codesign, then we need to either 1) figure out how to make it work with codesign or 2) for macOS, not put plugins in a version-number subdirectory ***AND*** change the plugin loading process not to look for compiled in a version-number subdirectory. Change-Id: I58d344b728d05369d35edef4e4e530f10034e930 Reviewed-on: https://code.wireshark.org/review/32000 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2019-02-12MacOS: Bundle and packaging updatesGerald Combs1-2/+5
Update the code signing portions of the packaging scripts to match newer versions of macOS. Change-Id: I5e03611d8db61416955e797edcadfcff1404cc38 Reviewed-on: https://code.wireshark.org/review/31996 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-02-11CMake: clear cache variables when a library has changedPeter Wu1-0/+45
On Windows, whenever win-setup.ps1 installs new libraries, the old paths become invalid. As a workaround the user can remove CMakeCache.txt completely or manually delete entries. Removing the whole file might lose custom options and clearing individual entries is tedious. Let's handle this automatically. Some HAVE_xxx variables from check_function_exists calls in PCAP and ZLIB, and one from check_symbol_exists in KERBEROS are not cleared. Those special cases would require too much work, the user should manually clear their cache in this case if needed. Fixes my local build since CARES, KERBEROS and LibXml2 were updated. Special care was necessary for LibXml2 as it will not set cache variable LIBXML2_LIBRARY when LIBXML2_LIBRARIES is already set. Change-Id: Ic793bdb67161504aadadf221bd7740a0ca31db63 Link: https://www.wireshark.org/lists/wireshark-dev/201902/msg00028.html Reviewed-on: https://code.wireshark.org/review/31960 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-02-10RPM: respect options for disabling Qt, SpanDSP and BCG729Peter Wu1-2/+2
"%bcond_without" enables a feature by default. Be sure to explicitly disable features to match the requested configuration. Change-Id: I90687f35bcd953670e147be9e70af03aaeaef5dc Ping-Bug: 14606 Reviewed-on: https://code.wireshark.org/review/31933 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-02-07CMake: Make sure we deploy Qt PDBs on Windows.Gerald Combs1-0/+5
Pass "--pdb" to windeployqt 5.6 and later. Add a note about installing the "Qt Debug Information Files" component to the Developer's Guide. Change-Id: I81329bc9f9131050b1076fe275445b6325c24794 Reviewed-on: https://code.wireshark.org/review/31921 Reviewed-by: Gerald Combs <gerald@wireshark.org> Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-02-05CMake: Fix build without LibXml2Uli Heilmeier1-0/+8
This is still needed when LibXml2 is missing, otherwise the build fails with: CMake Error: The following variables are used in this project, but they are set to NOTFOUND. Fixes: v2.9.1rc0-625-gd17e218918 ("CMake: Update FindLibXml2.cmake") Change-Id: I06fc2c18aa82dd553d5a10604c1a874c9a2e88a8 Reviewed-on: https://code.wireshark.org/review/31896 Reviewed-by: João Valverde <j@v6e.pt> Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-02-052.9 → 3.1.Gerald Combs1-3/+3
Change-Id: Iea6b55037bfb62d2e9b333148cbdc55fcd53dfa2 Reviewed-on: https://code.wireshark.org/review/31888 Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-02-04CMake: Update FindLibXml2.cmakeJoão Valverde1-6/+0
Change-Id: I55f77910be642535cba128900c2af40fa6824f04 Reviewed-on: https://code.wireshark.org/review/31874 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2019-02-03CMake: Install documentation to docdirJoão Valverde1-0/+1
Change-Id: I6860f2ba8c09daff3a72e44f0c41a1b19fb79218 Reviewed-on: https://code.wireshark.org/review/31852 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2019-02-02CMake: Fix DOCDIR on UnixJoão Valverde1-17/+19
User guides are installed to doc/Wireshark. Use doc/wireshark instead. Remove leftover variable CPACK_PACKAGE_NAME. Change-Id: I9a1d6bdc7d8f0b48c61e43679285d5ba83904a63 Reviewed-on: https://code.wireshark.org/review/31851 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2019-01-31CMake: describe purpose of MaxMindDBPeter Wu1-0/+5
Change-Id: I7a3ec64d772ee5fc0d3b040702dfc0de8da93250 Reviewed-on: https://code.wireshark.org/review/31836 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-31CMake: describe the purpose of NLPeter Wu1-0/+5
Change-Id: I9bfb2400445399088ff67eab39178e38daf85499 Reviewed-on: https://code.wireshark.org/review/31835 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-31CMake: rewrite FindSystemd.cmake filePeter Wu1-0/+5
Clarify that this is only needed for the sdjournal extcap interface and report the found version in the CMake output. Change-Id: I40bc540631bda32d0b92e4fcd59d8c1726606d86 Reviewed-on: https://code.wireshark.org/review/31834 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-29CMake: Minor standard output improvementsJoão Valverde1-11/+14
Change-Id: I7677220ec49d7b04f61e2a7287dac3a744f1c6c6 Reviewed-on: https://code.wireshark.org/review/31786 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2019-01-22CMake: Set a direct rpath for librariesJoão Valverde1-2/+14
Instead of using "$ORIGIN/../lib" just use "$ORIGIN". Also be explicit in configuring the relative RPATH. We don't want to assume a default relative path, in case more targets are addded, out of caution. Change-Id: I3b7f5e8de7be8bb30aca3b433212113d876c4163 Reviewed-on: https://code.wireshark.org/review/31647 Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-21CMake: strip directory prefixes from __FILE__ macrosPeter Wu1-0/+23
Depending on the build location, the full source and/or build directory is currently visible in error messages (for example, DISSECTOR_ASSERT). Remove these to help with reproducible builds and have shorter messages. A similar option (-fdebug-prefix-map) is also needed, but it affects external debugging tools and is therefore better left to distributors (Debian and Arch Linux do this for example). Bug: 15163 Change-Id: Icd8559bef2035f295aefbfc57ba6a342bfe76a41 Reviewed-on: https://code.wireshark.org/review/31645 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-21CMake: Remove unnecessary check for CMAKE_INSTALL_RPATHJoão Valverde1-1/+1
CMAKE_INSTALL_RPATH is set inside the if() block and not before. Change-Id: Id8a863ca9bf5fed367de3fa7681a9a269d3f4f07 Reviewed-on: https://code.wireshark.org/review/31646 Reviewed-by: João Valverde <j@v6e.pt> Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-20CMake: Fix LIBXML2 handlingUli Heilmeier1-0/+1
Since commit a3991874eb3d470a4adfcdef7903ab8d6dd8f881 cmake fails when LIBXML2 is not found. LIBXML2_INCLUDE_DIR is used but not set. This commit sets LIBXML2_INCLUDE_DIR. Change-Id: Ieb8b4accb5360d397b961fbd311ae349aac2c658 Reviewed-on: https://code.wireshark.org/review/31638 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt>
2019-01-20CMake: do not set RPATH when installing to a system directoryPeter Wu1-22/+21
When built with -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_LIBDIR=lib (as is done by many Linux distributions), do not set an unnecessary RPATH. This was the case before v2.9.0rc0-2727-g697623411c. Relocatable builds will still be possible with the default options as /usr/local/lib is typically not considered a system library path. Change-Id: Ic6ff1760183c20d3f9f9fb787604e888e116534e Reviewed-on: https://code.wireshark.org/review/31602 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: João Valverde <j@v6e.pt> Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-20CMake: Replace PACKAGELIST magicJoão Valverde1-257/+99
This is more explicit and easier to read with slightly better locality while using less code. Also less awkward when the package doesn't fit the narrow package list expectations. The ws_find_package() macro doesn't include all the status messages. The choice was to rely on standard find_package() and feature_summary() output and be less verbose. Avoid polluting the CLI build interface. Per target include paths and macro definitions are preferred. Because this patch intentionally removes the global CMAKE_*_FLAGS and include_directories() usage in favor of target properties, some untested build configurations may inadvertently break because of missing ${PACKAGE}_INCLUDE_DIRS or ${PACKAGE}_DEFINITIONS. This required a manual review of dependencies that might have been incomplete. ${PACKAGE_VAR}_LINK_FLAGS seems to be unused. Changing the CMake Qt code to use more modern CMake component syntax is left as future work. Change-Id: I3ed75252189a6e05a23ed6e619088f519cd7ed78 Reviewed-on: https://code.wireshark.org/review/31496 Petri-Dish: João Valverde <j@v6e.pt> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-18CMake: set CMAKE_BUILD_RPATH_USE_ORIGINPeter Wu1-0/+5
Tested with cmake v3.13.3-952-gf4c17c041, the resulting binaries indeed contain $ORIGIN and are invariant of the build directory. Change-Id: I5dad9493a6d54a0b03a3494fce69cc69a25b2f84 Ping-Bug: 15163 Reviewed-on: https://code.wireshark.org/review/31586 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-17CMake: silence CMP0083 warning from future CMake 3.14Peter Wu1-8/+13
The current development version of CMake started emitting warnings due to the use of CMAKE_POSITION_INDEPENDENT_CODE without setting CMP0083. Change-Id: Id6747c00fea7a1d28e5ba900ba4578fe89f40f83 Reviewed-on: https://code.wireshark.org/review/31579 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>
2019-01-14Windows: Use a c-ares DLL built with vcpkg.Gerald Combs1-1/+12
Update the Windows build environment to use c-ares packages built from a VS 2017 command prompt with set CARES_VERSION=1.15.0 vcpkg install c-ares:x86-windows c-ares:x64-windows vcpkg export c-ares:x86-windows --output=c-ares-%CARES_VERSION%-win32ws --zip vcpkg export c-ares:x64-windows --output=c-ares-%CARES_VERSION%-win64ws --zip The packages also include a PDB, so copy it to the build directory and add it to the PDB .zip. Change-Id: I1887ca89d897bea184144315219b366096519961 Reviewed-on: https://code.wireshark.org/review/31376 Petri-Dish: Gerald Combs <gerald@wireshark.org> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-01-14tarball+RPM: Fetch our version from CMake.Gerald Combs1-29/+8
Move git-export-release.sh to packaging/source. Have the source and RPM packaging derive version information from CMake's VERSION variable. This brings them in line with the rest of our packaging and avoids having to read chicken entrails^W^Wgit output. Make sure we always generate wireshark.spec. Bug: 15359 Change-Id: I188efda489c94449a10a612abebf9c2872c305cb Reviewed-on: https://code.wireshark.org/review/31504 Petri-Dish: Gerald Combs <gerald@wireshark.org> Reviewed-by: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Gerald Combs <gerald@wireshark.org>
2019-01-14dfilter: add string() function.Dario Lombardo1-0/+1
This function can convert non-string fields into strings. This allows the user to apply string functions (like contains and matches) to non-string fields. Examples: string(frame.number) matches "[13579]$" => for odd frames string(eth.dst) matches "aa\.bb\.cc\.dd\.ee\..." => to match a group of stations string(snmp.name) matches "^1.2.3.4" => for all OIDs under a specific node Change-Id: I18173f50ba5314ecdcd1e4b66c7e8ba5b44257ee Reviewed-on: https://code.wireshark.org/review/31427 Petri-Dish: Peter Wu <peter@lekensteyn.nl> Tested-by: Petri Dish Buildbot Reviewed-by: Peter Wu <peter@lekensteyn.nl>