Improvements to the compilation step