Refactoring package builds