Remove temporary stuff that is not needed in image building.