cmake: Enable BUILD_SHARED_LIBS=ON and factor out liboct_parser
Description
Right now CMake just builds a bunch of gigantic static libraries. With this MR the Octopus libraries will be shared between the different executable. This is in particular important when running with many MPI ranks on a single node where each executable will load all the symbols into its own address space, massively duplicating the number of symbols and bloating the memory footprint of Octopus. With shared libraries all the executables on the same node can use the same symbols that only have to be loaded in the global address space once.
Fixes #643 (closed)
Checklist
-
I have checked that my code follows the Octopus coding standards -
I have added tests for all the new features added in this request.
Edited by Henri Menke