Fixing some compilation issues