X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=Makefile;h=017cb29eda7aef2c5ebf7b140f4f147a5f529963;hb=b91f9fa7fe99aa9b0eed5a847baa67f1c678208a;hp=ee8e5e2d282cfd92031fef036776aed43e45348f;hpb=cfe84507a37a65efcb22e7abe3247b4c7704d0a8;p=src%2Fxds%2Fxds-gdb.git diff --git a/Makefile b/Makefile index ee8e5e2..017cb29 100644 --- a/Makefile +++ b/Makefile @@ -22,6 +22,7 @@ endif HOST_GOOS=$(shell go env GOOS) HOST_GOARCH=$(shell go env GOARCH) ARCH=$(HOST_GOOS)-$(HOST_GOARCH) +REPOPATH=github.com/iotbzh/xds-gdb EXT= ifeq ($(HOST_GOOS), windows) @@ -51,14 +52,14 @@ else BUILD_MODE="Release mode" endif -REPOPATH=github.com/iotbzh/xds-gdb -TARGET := xds-gdb -build: $(TARGET) +.PHONY: all +all: build -xds-gdb: vendor - @echo "### Build $@ (version $(VERSION), subversion $(SUB_VERSION)) - $(BUILD_MODE)"; - @cd $(ROOT_SRCDIR); $(BUILD_ENV_FLAGS) go build $(VERBOSE_$(V)) -i -o $(BINDIR)/$@$(EXT) -ldflags "$(GORELEASE) -X main.AppVersion=$(VERSION) -X main.AppSubVersion=$(SUB_VERSION)" . +.PHONY: build +build: vendor + @echo "### Build xds-gdb (version $(VERSION), subversion $(SUB_VERSION)) - $(BUILD_MODE)"; + @cd $(ROOT_SRCDIR); $(BUILD_ENV_FLAGS) go build $(VERBOSE_$(V)) -i -o $(BINDIR)/xds-gdb$(EXT) -ldflags "$(GORELEASE) -X main.AppVersion=$(VERSION) -X main.AppSubVersion=$(SUB_VERSION)" . test: tools/glide go test --race $(shell ./tools/glide novendor) @@ -94,6 +95,7 @@ package-all: @echo " WARNING: build on Windows not supported for now." @echo "# Build darwin amd64..." GOOS=darwin GOARCH=amd64 RELEASE=1 make -f $(ROOT_SRCDIR)/Makefile package + make -f $(ROOT_SRCDIR)/Makefile clean vendor: tools/glide glide.yaml ./tools/glide install --strip-vendor @@ -110,7 +112,7 @@ tools/glide: help: @echo "Main supported rules:" - @echo " build (default)" + @echo " all (default)" @echo " release" @echo " clean" @echo " package"