Minor fixes on build process