From eebb6f14660f5d95a7ec572846722659b6192d6e Mon Sep 17 00:00:00 2001 From: Matt Butcher Date: Mon, 12 Nov 2018 21:37:52 -0700 Subject: [PATCH] feat: add 'make install' target (#401) --- Makefile | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 8503dca0..37c1d4f4 100644 --- a/Makefile +++ b/Makefile @@ -1,9 +1,10 @@ -PROJECT := duffle -ORG := deis -BINDIR := $(CURDIR)/bin -GOFLAGS := -LDFLAGS := -w -s -TESTFLAGS := +PROJECT := duffle +ORG := deis +BINDIR := $(CURDIR)/bin +GOFLAGS := +LDFLAGS := -w -s +TESTFLAGS := +INSTALL_DIR := /usr/local/bin ifeq ($(OS),Windows_NT) TARGET = $(PROJECT).exe @@ -26,6 +27,10 @@ default: build build: go build $(GOFLAGS) -o $(BINDIR)/$(TARGET) -ldflags '$(LDFLAGS)' github.com/$(ORG)/$(PROJECT)/cmd/... +.PHONY: install +install: + install $(BINDIR)/$(TARGET) $(INSTALL_DIR) + CX_OSES = linux windows darwin CX_ARCHS = amd64