Cleanup 1

This cleanup consists of three commits:
1. separate the logging to make the include easier
2. fix of some compiler warnings
3. move the tmp folder for linux based systems to /tmp 
If we always use this path, we could get problems with multiple simulations running on the same machine. We may have to create a subfolder with the pid of the simulation.