Merge pull request #77 from dlorenc/master

Fix make clean.
pull/79/head
dlorenc 2016-05-14 10:43:29 -07:00
commit a9f97ec2dc
1 changed files with 8 additions and 2 deletions

View File

@ -15,7 +15,13 @@
GOOS ?= $(shell go env GOOS)
GOARCH ?= $(shell go env GOARCH)
BUILD_DIR ?= ./out
GOPATH ?= $(shell pwd)/.gopath
ifeq ($(IN_DOCKER),1)
GOPATH := /go
else
GOPATH := $(shell pwd)/.gopath
endif
REPOPATH ?= k8s.io/minikube
export GO15VENDOREXPERIMENT=1
@ -34,7 +40,7 @@ out/localkube: .gopath
ifeq ($(GOOS),linux)
CGO_ENABLED=1 go build -ldflags="-s" -o $(BUILD_DIR)/localkube ./cmd/localkube
else
docker run -w /go/src/k8s.io/minikube -e GOPATH=/go -v $(shell pwd):/go/src/k8s.io/minikube golang:1.6 make out/localkube
docker run -w /go/src/k8s.io/minikube -e IN_DOCKER=1 -v $(shell pwd):/go/src/k8s.io/minikube golang:1.6 make out/localkube
endif
out/minikube-$(GOOS)-$(GOARCH): .gopath pkg/minikube/cluster/localkubecontents.go