diff --git a/Makefile b/Makefile index 902e1bec1b..25eda0a19d 100644 --- a/Makefile +++ b/Makefile @@ -89,7 +89,13 @@ BUILD_TIME = $(shell date --utc) GIT_COMMIT = $(shell git rev-parse --short HEAD) GO_VERSION = $(shell go version) -milvus: build-cpp +print-build-info: + @echo "Build Tag: $(BUILD_TAGS)" + @echo "Build Time: $(BUILD_TIME)" + @echo "Git Commit: $(GIT_COMMIT)" + @echo "Go Version: $(GO_VERSION)" + +milvus: build-cpp print-build-info @echo "Building Milvus ..." @mkdir -p $(INSTALL_PATH) && go env -w CGO_ENABLED="1" && GO111MODULE=on $(GO) build \ -ldflags="-X 'main.BuildTags=$(BUILD_TAGS)' -X 'main.BuildTime=$(BUILD_TIME)' -X 'main.GitCommit=$(GIT_COMMIT)' -X 'main.GoVersion=$(GO_VERSION)'" \ @@ -163,7 +169,7 @@ clean: @rm -rf lib/ @rm -rf $(GOPATH)/bin/milvus -milvus-tools: +milvus-tools: print-build-info @echo "Building tools ..." @mkdir -p $(INSTALL_PATH)/tools && go env -w CGO_ENABLED="1" && GO111MODULE=on $(GO) build \ -ldflags="-X 'main.BuildTags=$(BUILD_TAGS)' -X 'main.BuildTime=$(BUILD_TIME)' -X 'main.GitCommit=$(GIT_COMMIT)' -X 'main.GoVersion=$(GO_VERSION)'" \