Fix compilation errors with new gcc