How can I build a static plugin?

Hi, I am developing a bro plugin which can retrieve packets
from a dpdk vswitch. Since DPDK builds static libs, the
plugin should better become a static lib.

The tutorials in the bro website give only examples about
building a dynamic lib. However, I do find some cmake files
about how to build a static lib.

Is there any tutorial on this?


You can't build the plugin itself as a static library, as then Bro
couldn't load it dynamically at runtime. You should however be able to
link DPDK statically into your (dynamic) plugin, if that's what you
need? If so, I would think that CMake actually does the right there
already if all it finds for a dependency is a static library.