From 16c189b7b27f543953d4a2eb10357036e47063ed Mon Sep 17 00:00:00 2001 From: Eric Chiang Date: Fri, 6 May 2016 13:31:09 -0700 Subject: [PATCH] *: fix build script to work outside of GOPATH Closes #439 --- env | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/env b/env index c806a73c..773cb07a 100644 --- a/env +++ b/env @@ -21,6 +21,17 @@ for V in "${KNOWN_INSECURE[@]}"; do fi done +PROJ="dex" +ORG_PATH="github.com/coreos" +REPO_PATH="${ORG_PATH}/${PROJ}" + +if [ ! -h gopath/src/${REPO_PATH} ]; then + mkdir -p gopath/src/${ORG_PATH} + ln -s ${PWD} gopath/src/${REPO_PATH} || exit 255 +fi + +export GOPATH=${PWD}/gopath +export GOBIN=${PWD}/bin export GO15VENDOREXPERIMENT=1 export VERSION=$(./git-version) LD_FLAGS="-X main.version=${VERSION}"