forked from milvus-io/milvus-proto
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
22 lines (18 loc) · 775 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
GO ?= go
PWD := $(shell pwd)
GOPATH := $(shell $(GO) env GOPATH)
PROTOC := $(shell which protoc)
PROTOC_VER := $(shell protoc --version)
INSTALL_PATH := $(PWD)/bin
all: generate-proto
build:
@(env bash $(PWD)/scripts/core_build.sh)
generate-proto: export protoc:=${PWD}/cmake-build/protobuf/protobuf-build/protoc
generate-proto: build
@echo "Generate proto files"
@echo "Installing protoc-gen-go to ./bin" && GOBIN=$(INSTALL_PATH) go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.33.0
@echo "Installing protoc-gen-go-grpc to ./bin" && GOBIN=$(INSTALL_PATH) go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.3.0
@(env bash $(PWD)/scripts/proto_gen_go.sh $(INSTALL_PATH))
clean:
@echo "Cleaning up all the generated files"
@rm -rf cmake-build