win 678 B

1234567891011121314151617181920
  1. #!/usr/bin/env bash
  2. set -e
  3. # explicit list of os/arch combos that support being a daemon
  4. declare -A daemonSupporting
  5. daemonSupporting=(
  6. [linux/amd64]=1
  7. [windows/amd64]=1
  8. )
  9. platform="windows/amd64"
  10. export DEST="$DEST/$platform" # bundles/VERSION/cross/GOOS/GOARCH/docker-VERSION
  11. mkdir -p "$DEST"
  12. ABS_DEST="$(cd "$DEST" && pwd -P)"
  13. export GOOS=${platform%/*}
  14. export GOARCH=${platform##*/}
  15. if [ -z "${daemonSupporting[$platform]}" ]; then
  16. export LDFLAGS_STATIC_DOCKER="" # we just need a simple client for these platforms
  17. export BUILDFLAGS=( "${ORIG_BUILDFLAGS[@]/ daemon/}" ) # remove the "daemon" build tag from platforms that aren't supported
  18. fi
  19. source "${MAKEDIR}/binary"