ENH: Move log from each individual library/tool compilation file to main compilation file

This allows to save everything that is printed on the screen and not only a few commands that were logged.