scripts: able to set XC_ARCH/OS manually
This commit is contained in:
parent
dabbcd45a8
commit
49ac4acdd2
|
@ -15,6 +15,12 @@ cd $DIR
|
|||
GIT_COMMIT=$(git rev-parse HEAD)
|
||||
GIT_DIRTY=$(test -n "`git status --porcelain`" && echo "+CHANGES" || true)
|
||||
|
||||
# If its dev mode, only build for ourself
|
||||
if [ "${TF_DEV}x" != "x" ]; then
|
||||
XC_OS=${XC_OS:-$(go env GOOS)}
|
||||
XC_ARCH=${XC_ARCH:-$(go env GOARCH)}
|
||||
fi
|
||||
|
||||
# Determine the arch/os combos we're building for
|
||||
XC_ARCH=${XC_ARCH:-"386 amd64 arm"}
|
||||
XC_OS=${XC_OS:-linux darwin windows freebsd openbsd}
|
||||
|
@ -29,12 +35,6 @@ rm -f bin/*
|
|||
rm -rf pkg/*
|
||||
mkdir -p bin/
|
||||
|
||||
# If its dev mode, only build for ourself
|
||||
if [ "${TF_DEV}x" != "x" ]; then
|
||||
XC_OS=$(go env GOOS)
|
||||
XC_ARCH=$(go env GOARCH)
|
||||
fi
|
||||
|
||||
# Build!
|
||||
echo "==> Building..."
|
||||
gox \
|
||||
|
|
Loading…
Reference in New Issue