From 61828f16e7b59beb96ca11d39b08bc474595c3d4 Mon Sep 17 00:00:00 2001 From: Weiyu Xue Date: Thu, 24 Oct 2019 17:58:21 -0700 Subject: [PATCH] fix protoc relative path issue -- especially for proto depend import; ref issue: https://github.com/golang/protobuf/issues/748; --- Makefile | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 14664b4..58f94ea 100644 --- a/Makefile +++ b/Makefile @@ -6,9 +6,8 @@ PROTO_FILES=./protos/node/node.proto \ ./protos/escrow/escrow.proto \ ./protos/ledger/ledger.proto \ # ./protos/status/status.proto \ -# ./protos/guard/guard.proto \ - +PB_OUT_PATH=$$GOPATH/src install: brew install protobuf @@ -21,5 +20,5 @@ lintf: build: lintf for proto in $(PROTO_FILES); \ do \ - eval protoc -I. --go_out=plugins=grpc:. $$proto ; \ + eval protoc -I. --go_out=plugins=grpc:$(PB_OUT_PATH) $$proto ; \ done