Fix compile problems