-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
44 lines (30 loc) · 1.36 KB
/
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
34
35
36
37
38
39
40
41
42
43
44
SRC_ROOT=$(GOPATH)/src
IDL_PATH=$(SRC_ROOT)/github.com/findy-network/findy-agent-api/idl/v1
OUT_PATH ?= .grpc-out
DART_OUT_PATH ?= ./lib/src/generated
protoc_all: init protoc protoc_dart_all
protoc: protoc_protocol protoc_agency protoc_agent protoc_authn
protoc_protocol:
protoc --proto_path=$(IDL_PATH) --go_out=$(OUT_PATH) --go-grpc_out=$(OUT_PATH) protocol.proto
protoc_agency:
protoc --proto_path=$(IDL_PATH) --go_out=$(OUT_PATH) --go-grpc_out=$(OUT_PATH) agency.proto
protoc_agent:
protoc --proto_path=$(IDL_PATH) --go_out=$(OUT_PATH) --go-grpc_out=$(OUT_PATH) agent.proto
protoc_authn:
protoc --proto_path=$(IDL_PATH) --go_out=$(OUT_PATH) --go-grpc_out=$(OUT_PATH) authn.proto
protoc_dart_protocol:
protoc --proto_path=$(IDL_PATH) --dart_out=grpc:$(DART_OUT_PATH) -I$(IDL_PATH) protocol.proto
protoc_dart_agency:
protoc --proto_path=$(IDL_PATH) --dart_out=grpc:$(DART_OUT_PATH) -I$(IDL_PATH) agency.proto
protoc_dart_agent:
protoc --proto_path=$(IDL_PATH) --dart_out=grpc:$(DART_OUT_PATH) -I$(IDL_PATH) agent.proto
protoc_dart_authn:
protoc --proto_path=$(IDL_PATH) --dart_out=grpc:$(DART_OUT_PATH) -I$(IDL_PATH) authn.proto
protoc_dart_all: protoc_dart_protocol protoc_dart_agency protoc_dart_agent protoc_dart_authn
clean:
@rm -r $(OUT_PATH)/*
@rm -r $(DART_OUT_PATH)/*
init:
@echo "initialize build dirs:"
@mkdir -pv $(OUT_PATH)
@mkdir -pv $(DART_OUT_PATH)