Wireshark-dev: Re: [Wireshark-dev] Where to put my wiretap plugin?
From: Jaap Keuter <jaap.keuter@xxxxxxxxx>
Date: Fri, 19 Jan 2018 09:02:22 +0100
On 19-01-18 04:46, João Valverde wrote:
> If the plugin is loaded I don't see how the build system could have any
> influence either.

Hi João,

That was what puzzled met too...
I started to dig down further and found that indeed the plugin was loaded
(obviously) and they are called to register their registration function, as
provided by the generated plugin.c.

#1 is the plugin.c file generated in the autotools build, and
#2 is the plugin.c file generated in the cmake build
Looking at #1 versus #2 shows that #1 has an empty plugin_register() function,
while #2 has the correct wtap_register_plugin() call.

plugin.c generation is controlled by the build system, so that is the cause of
the difference between the two. Generation of #1 comes from a generic
Makefile.am.inc, which is geared to generating 'plugin' (being dissector
plugin!), while the CMakeLists.txt file calls for generating a 'plugin_wtap'.

So, the generation of #1 for the other kinds of plugin (!dissector) has to be
reconsidered.

Thanks,
Jaap