Some fixes for rpm