Merge pull request #4911 from guggero/docker-rpc-compile

lnrpc+mobile: use docker to compile/format protos
This commit is contained in:
Johan T. Halseth authored and GitHub committed 2021-02-01 13:42:42 +01:00
commit 315f97ffd5
9 files changed
+123 -233

No files matched your search

+3 -10
View File
@@ -6,7 +6,6 @@ BTCD_PKG := github.com/btcsuite/btcd
GOVERALLS_PKG := github.com/mattn/goveralls
LINT_PKG := github.com/golangci/golangci-lint/cmd/golangci-lint
GOACC_PKG := github.com/ory/go-acc
FALAFEL_PKG := github.com/lightninglabs/falafel
GOIMPORTS_PKG := golang.org/x/tools/cmd/goimports
GOFUZZ_BUILD_PKG := github.com/dvyukov/go-fuzz/go-fuzz-build
GOFUZZ_PKG := github.com/dvyukov/go-fuzz/go-fuzz
@@ -37,7 +36,6 @@ BTCD_COMMIT := $(shell cat go.mod | \
LINT_COMMIT := v1.18.0
GOACC_COMMIT := ddc355013f90fea78d83d3a6c71f1d37ac07ecd5
FALAFEL_COMMIT := v0.7.1
GOFUZZ_COMMIT := 21309f307f61
DEPGET := cd /tmp && GO111MODULE=on go get -v
@@ -113,10 +111,6 @@ btcd:
@$(call print, "Installing btcd.")
$(DEPGET) $(BTCD_PKG)@$(BTCD_COMMIT)
falafel:
@$(call print, "Installing falafel.")
$(DEPGET) $(FALAFEL_PKG)@$(FALAFEL_COMMIT)
goimports:
@$(call print, "Installing goimports.")
$(DEPGET) $(GOIMPORTS_PKG)
@@ -264,7 +258,7 @@ list:
rpc:
@$(call print, "Compiling protos.")
cd ./lnrpc; ./gen_protos.sh
cd ./lnrpc; ./gen_protos_docker.sh
rpc-format:
@$(call print, "Formatting protos.")
@@ -279,9 +273,9 @@ sample-conf-check:
@$(call print, "Making sure every flag has an example in the sample-lnd.conf file")
for flag in $$(GO_FLAGS_COMPLETION=1 go run -tags="$(RELEASE_TAGS)" $(PKG)/cmd/lnd -- | grep -v help | cut -c3-); do if ! grep -q $$flag sample-lnd.conf; then echo "Command line flag --$$flag not added to sample-lnd.conf"; exit 1; fi; done
mobile-rpc: falafel goimports
mobile-rpc:
@$(call print, "Creating mobile RPC from protos.")
cd ./mobile; ./gen_bindings.sh $(FALAFEL_COMMIT)
cd ./lnrpc; COMPILE_MOBILE=1 ./gen_protos_docker.sh
vendor:
@$(call print, "Re-creating vendor directory.")
@@ -318,7 +312,6 @@ clean:
unit \
unit-cover \
unit-race \
falafel \
goveralls \
travis-race \
travis-cover \