2 This is an example of how to build a Wireshark plugin out-of-tree. This
3 is an alternative, more recent way to build Wireshark binary plugins,
4 than the one in 'README.plugins', that describes in detail how to
5 include a new plugin into the project source tree (here called in-tree
6 build). Building a plugin out-of-tree doesn't require rebuilding the whole
7 Wireshark source tree every time.
9 You always need to rebuild plugins for each major.minor Wireshark version.
10 Binary compatibility is never guaranteed between those releases and Wireshark
11 will explicitly check for which version the plugin was built and refuse
14 Note that the out-of-tree method builds the plugin using CMake's Config-file
15 mechanism[1] for configuration. In other words the plugin build system uses
16 the Wireshark headers that were installed on the system using "make install"
17 or equivalent (as configured from WiresharkConfig.cmake). This is not the same
20 You should of course adapt this trivial example to your own needs.
22 To build/install the plugin:
24 $ mkdir build && cd build
29 If your WiresharkConfig.cmake file is not in one of the standard cmake search
30 paths you will have to tell cmake where to find it. You can do so using
31 CMAKE_PREFIX_PATH, for example:
33 $ cmake -DCMAKE_PREFIX_PATH="/opt/wireshark" ..
35 [1]https://cmake.org/cmake/help/latest/manual/cmake-packages.7.html#config-file-packages