Update minikube-iso makefile target

The makefile was slightly broken for minikube-iso.  Since it && all the
commands to check if buildroot, the git clone failed if the buildroot
folder already existed and broke the target.  I put this logic in a
conditional.
pull/800/head
Matt Rickard 2016-11-03 14:22:44 -07:00
parent 36ac0619cc
commit c684ce53ae
1 changed files with 7 additions and 8 deletions

View File

@ -19,6 +19,7 @@ VERSION_BUILD ?= 2
VERSION ?= v$(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_BUILD) VERSION ?= v$(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_BUILD)
DEB_VERSION ?= $(VERSION_MAJOR).$(VERSION_MINOR)-$(VERSION_BUILD) DEB_VERSION ?= $(VERSION_MAJOR).$(VERSION_MINOR)-$(VERSION_BUILD)
INSTALL_SIZE ?= $(shell du out/minikube-windows-amd64.exe | cut -f1) INSTALL_SIZE ?= $(shell du out/minikube-windows-amd64.exe | cut -f1)
BUILDROOT_BRANCH ?= 2016.08
GOOS ?= $(shell go env GOOS) GOOS ?= $(shell go env GOOS)
GOARCH ?= $(shell go env GOARCH) GOARCH ?= $(shell go env GOARCH)
@ -78,14 +79,12 @@ iso:
cd deploy/iso/boot2docker && ./build.sh cd deploy/iso/boot2docker && ./build.sh
minikube-iso: minikube-iso:
[ ! -e $(BUILD_DIR)/buildroot ] && \ if [ ! -d $(BUILD_DIR)/buildroot ]; then \
mkdir -p $(BUILD_DIR) && \ mkdir -p $(BUILD_DIR); \
git clone https://github.com/buildroot/buildroot $(BUILD_DIR)/buildroot && \ git clone --branch=$(BUILDROOT_BRANCH) https://github.com/buildroot/buildroot $(BUILD_DIR)/buildroot; \
cd $(BUILD_DIR)/buildroot && \ fi;
git checkout 2016.08 && \ $(MAKE) BR2_EXTERNAL=../../deploy/iso/minikube-iso minikube_defconfig -C $(BUILD_DIR)/buildroot
make BR2_EXTERNAL=../../deploy/iso/minikube-iso minikube_defconfig && \ $(MAKE) -C $(BUILD_DIR)/buildroot
cd ../..
cd $(BUILD_DIR)/buildroot && make
.PHONY: integration .PHONY: integration
integration: out/minikube integration: out/minikube