-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
33 lines (29 loc) · 1019 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
help:
@echo "Make Options:"
@echo " all - Generate all : compile all proto-buffers into Pbs"
@echo " init - Install required modules : install protoc-gen-go & protoc-gen-go-grpc"
@echo " build - Generate all : compile all protobuffers Pbs"
@echo " clean - Clean up compile directory"
all:
make init
make build
init:
go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
build:
@protoc -I=. -I=./googleapis \
--go_out ./ --go_opt paths=import \
--go-grpc_out ./ --go-grpc_opt paths=import \
proto/**/**/**/*.proto
gateway:
@protoc -I=. -I=./googleapis \
--grpc-gateway_out ./ \
proto/vatz/**/**/*.proto
compile:
sudo protoc -I=. -I=./googleapis \
--go_out ./ --go_opt paths=import \
--go-grpc_out ./ --go-grpc_opt paths=import \
proto/**/**/**/*.proto
clean:
$(call banner, "Clean up compile directory")
rm -rf manager plugin