未验证 提交 9051d64f 编写于 作者: D dragondriver 提交者: GitHub

Print build env infomation (#13300)

Signed-off-by: Ndragondriver <jiquan.long@zilliz.com>
上级 ee7e4006
......@@ -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)'" \
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册