adding functions to build script.