debug-switch for dynamically linked library with solverName -debug-switch nameOfLibrary=1
Functionality to add/problem to solve
It is not possible to activate debug flags for dynamically linked libraries (e.g. 'homemade' boundary conditions) in the usual way with 'solverName -debug-switch nameOfLibrary=1'. The dynamically linked library must be added as DebugSwitches in controlDict of the case for the debug flag to be activated. I am sure if this is a desired feature, but I suggest that OpenFOAM could be updated with the functionality to also enable debug-switches for dynamically linked libraries in the same way as with usual debug flags.
Target audience
Anyone who is developing libraries that are outside of the official release of OpenFOAM and would like to use debug flags.
Proposal
Enable all the solvers to pick up debug flags from libraries that are compiled outside of the official OpenFOAM release.
What does success look like, and how can we measure that?
Success is when the user can use 'solverName -debug-switch -nameOfDynamicallyLinkedLibrary=1', and the solver can pick up the debug flag.