Changed the way log files are handled. Now both macro and log is written into a single logfile.