Fix compiler warnings, clean #includes