Adding SPDLOG dependency (closes #19)
See #19 (closed) for the intention.
This MR added spdlog as a new dependency to VF. spdlog is fetched via the cmake configuration from github https://github.com/gabime/spdlog. A spdlog wrapper library was added, which is called "logger". The logging itself can be realised via some macros, which are placed here: src/logger/Logger.h
Up to now the logging is realised in 3 different log sinks:
- colored console output
- a daily log file
- a log file from the last run of VirtualFluids The default file path is relativ to executed command logs/ The file path can be changed via vf::logging::changeLogPath(). Further documentation can be found here src/logger/Logger.h
Although the logging can be done by the new macros, the logging messages should be written in the spdlog syntax. For that the documentation can be found here: https://github.com/gabime/spdlog/wiki/1.-QuickStart e.g. (notice the {} placeholder syntax) : #include <logger/Logger.h> VF_LOG_INFO("Magic number: {}", 42)
So far the logger is used exemplary here:
- apps/gpu/Drivencavity
- apps/cpu/LaminarTubeFlow