Skip to content

Commit b06f98a

Browse files
author
Vaughn Dice
committed
fix(make): determine host OS for supplying to (container-ized) go build
1 parent 16fda1f commit b06f98a

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

client/Makefile

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,16 @@ export GO15VENDOREXPERIMENT=1
33
# the filepath to this repository, relative to $GOPATH/src
44
repo_path = github.com/deis/workflow/client
55

6+
HOST_OS := $(shell uname)
7+
ifeq ($(HOST_OS),Darwin)
8+
GOOS=darwin
9+
else
10+
GOOS=linux
11+
endif
12+
613
DEV_ENV_IMAGE := quay.io/deis/go-dev:0.9.0
714
DEV_ENV_WORK_DIR := /go/src/${repo_path}
8-
DEV_ENV_PREFIX := docker run --rm -e GO15VENDOREXPERIMENT=1 -e CGO_ENABLED=0 -v ${CURDIR}:${DEV_ENV_WORK_DIR} -w ${DEV_ENV_WORK_DIR}
15+
DEV_ENV_PREFIX := docker run --rm -e GO15VENDOREXPERIMENT=1 -e CGO_ENABLED=0 -e GOOS=${GOOS} -v ${CURDIR}:${DEV_ENV_WORK_DIR} -w ${DEV_ENV_WORK_DIR}
916
DEV_ENV_CMD := ${DEV_ENV_PREFIX} ${DEV_ENV_IMAGE}
1017
DIST_DIR := _dist
1118

0 commit comments

Comments
 (0)