From 09b8bee8658ab8565279bf87b3522dfc489916a9 Mon Sep 17 00:00:00 2001 From: "Johan T. Halseth" Date: Tue, 4 Aug 2020 14:43:08 +0200 Subject: [PATCH] mobile: remember walletunlocker.proto --- mobile/gen_bindings.sh | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/mobile/gen_bindings.sh b/mobile/gen_bindings.sh index 2e54beaa..c325ff3f 100755 --- a/mobile/gen_bindings.sh +++ b/mobile/gen_bindings.sh @@ -39,14 +39,21 @@ listeners="lightning=lightningLis walletunlocker=walletUnlockerLis" # one proto file is being parsed, it should only be done once. mem_rpc=1 +PROTOS="rpc.proto walletunlocker.proto" + opts="package_name=$pkg,target_package=$target_pkg,listeners=$listeners,mem_rpc=$mem_rpc" -protoc -I/usr/local/include -I. \ - -I$GOPATH/src/github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis \ - --plugin=protoc-gen-custom=$falafel\ - --custom_out=./build \ - --custom_opt="$opts" \ - --proto_path=../lnrpc \ - rpc.proto + +for file in $PROTOS; do + echo "Generating mobile protos from ${file}" + + protoc -I/usr/local/include -I. \ + -I$GOPATH/src/github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis \ + --plugin=protoc-gen-custom=$falafel\ + --custom_out=./build \ + --custom_opt="$opts" \ + --proto_path=../lnrpc \ + "${file}" +done # If prefix=1 is specified, prefix the generated methods with subserver name. # This must be enabled to support subservers with name conflicts.