Merge pull request #643 from zhgwenming/build

Use 'go install' instead of 'go build' to generate all commands at the same time.
This commit is contained in:
brendandburns
2014-07-28 11:44:05 -07:00
6 changed files with 10 additions and 7 deletions

View File

@@ -31,7 +31,4 @@ if [ $# -gt 0 ]; then
BINARIES="$@"
fi
for b in ${BINARIES}; do
echo "+++ Building ${b}"
go build "${KUBE_GO_PACKAGE}/${b}"
done
go install $(for b in $BINARIES; do echo "${KUBE_GO_PACKAGE}"/${b}; done)

View File

@@ -61,4 +61,7 @@ KUBE_GO_PACKAGE_DIR="${GOPATH}/src/${KUBE_GO_PACKAGE}"
rm "${KUBE_GO_PACKAGE_DIR}" >/dev/null 2>&1 || true
ln -s "${KUBE_REPO_ROOT}" "${KUBE_GO_PACKAGE_DIR}"
)
# unset GOBIN in case it already exsit in the current session
unset GOBIN
export GOPATH="${KUBE_TARGET}:${KUBE_REPO_ROOT}/third_party"

View File

@@ -38,6 +38,6 @@ ETCD_PID=$!
sleep 5
$(dirname $0)/../output/go/integration
$(dirname $0)/../output/go/bin/integration
kill $ETCD_PID

View File

@@ -50,7 +50,7 @@ API_PORT=${API_PORT:-8080}
API_HOST=${API_HOST:-127.0.0.1}
KUBELET_PORT=${KUBELET_PORT:-10250}
GO_OUT=$(dirname $0)/../output/go
GO_OUT=$(dirname $0)/../output/go/bin
APISERVER_LOG=/tmp/apiserver.log
${GO_OUT}/apiserver \