refactoring build system