log: Improve logging
This commit fixes/improves the following:
- Fix running inside valgrind
- Show gdb logs on crash - if running with verbosity enabled
- Fix breakpoints with G_DEBUG set.
This has been used as such in https://gitlab.gnome.org/World/Chatty/