build: fix tools/build tests

Signed-off-by: Gyuho Lee <gyuhox@gmail.com>
release-3.4
Gyuho Lee 2018-04-09 11:54:12 -07:00
parent 2d13894a16
commit f6cb732fff
1 changed files with 9 additions and 8 deletions

17
build
View File

@ -67,13 +67,14 @@ etcd_build() {
tools_build() { tools_build() {
out="bin" out="bin"
if [[ -n "${BINDIR}" ]]; then out="${BINDIR}"; fi if [[ -n "${BINDIR}" ]]; then out="${BINDIR}"; fi
tools_path="benchmark tools_path="tools/benchmark
etcd-dump-db tools/etcd-dump-db
etcd-dump-logs tools/etcd-dump-logs
functional-tester/cmd/etcd-agent tools/local-tester/bridge
functional-tester/cmd/etcd-tester functional/cmd/etcd-agent
functional-tester/cmd/etcd-runner functional/cmd/etcd-proxy
local-tester/bridge" functional/cmd/etcd-runner
functional/cmd/etcd-tester"
for tool in ${tools_path} for tool in ${tools_path}
do do
echo "Building" "'${tool}'"... echo "Building" "'${tool}'"...
@ -81,7 +82,7 @@ tools_build() {
CGO_ENABLED=0 go build ${GO_BUILD_FLAGS} \ CGO_ENABLED=0 go build ${GO_BUILD_FLAGS} \
-installsuffix cgo \ -installsuffix cgo \
-ldflags "${GO_LDFLAGS}" \ -ldflags "${GO_LDFLAGS}" \
-o "${out}/${tool}" "${REPO_PATH}/tools/${tool}" || return -o "${out}/${tool}" "${REPO_PATH}/${tool}" || return
done done
} }