fixed some compile errors, not all