fixes for some compile problems