Removed unused compiler flag to disable logging.
Cleaned, normalized and removed uncommented code to make it more in line with the style guide.
Changes and code cleaning so we can be built with gcc -Wall (enable all warnings).