removing unused code
cleanup and segregating out build process