A foo_plugin that incorporates src/foo/foo.cc (containing JANA2-related enty point)
A foo_library that contains all other *.cc files In order to have a complete set of symbols we ask linker to kindly link foo_library to foo_plugin. Unfortunately, it can ignore our request if it deems that the foo_library symbols are not referenced anywhere. This commit modifies the linking process to incorporate --no-as-needed option. The fancy feature from the
https://gitlab.kitware.com/cmake/cmake/-/commit/42965799b4747ab1e0afa6546be13444f68c1987 makes it so that other libraries (e.g. external ones like podio) can still be linked lazily.
At this point we can remove WITH_STATIC_LIBRARY per-plugin configuration.
This is brought by an issue that plagued pid_lut builds inside the container: https://eicweb.phy.anl.gov/EIC/benchmarks/physics_benchmarks/-/jobs/3070278#L1611
Our build process produces two shared objects:
At this point we can remove WITH_STATIC_LIBRARY per-plugin configuration.