Add build environment

Add build script and generate a version file.