Add some fixes for building in tip or with golang 1.6

This commit is contained in:
James Shubin
2016-02-22 01:30:12 -05:00
parent ed61444d82
commit f3d1369764
2 changed files with 6 additions and 2 deletions

View File

@@ -26,7 +26,11 @@ fi
# build etcd
git clone --recursive https://github.com/coreos/etcd/ && cd etcd
git checkout v2.2.4 # TODO: update to newer versions as needed
goversion=$(go version)
# if 'go version' contains string 'devel', then use git master of etcd...
if [ "${goversion#*devel}" == "$goversion" ]; then
git checkout v2.2.4 # TODO: update to newer versions as needed
fi
[ -x build ] && ./build
mkdir -p ~/bin/
cp bin/etcd ~/bin/