diff options
-rw-r--r-- | build.gradle | 8 | ||||
-rw-r--r-- | tunnel/build.gradle | 16 | ||||
-rw-r--r-- | tunnel/tools/libwg-go/Makefile | 11 |
3 files changed, 23 insertions, 12 deletions
diff --git a/build.gradle b/build.gradle index f7a864e5..9333da35 100644 --- a/build.gradle +++ b/build.gradle @@ -12,16 +12,14 @@ buildscript { datastoreVersion = '1.0.0' desugarVersion = '1.1.5' fragmentVersion = '1.4.1' - grpcVersion = '1.42.1' - gradleVersion = '4.0.1' + grpcVersion = '1.46.0' jsr305Version = '3.0.2' junitVersion = '4.13.2' lifecycleRuntimeKtxVersion = '2.4.1' materialComponentsVersion = '1.6.0' preferenceVersion = '1.2.0' - protobufGradleVersion = '0.8.17' - protobufLiteVersion = '3.0.0' - protocVersion = '3.19.1' + protobufGradleVersion = '0.8.18' + protocVersion = '3.20.1' zxingEmbeddedVersion = '4.3.0' groupName = 'com.wireguard.android' diff --git a/tunnel/build.gradle b/tunnel/build.gradle index 8cffa1e6..bb7d5111 100644 --- a/tunnel/build.gradle +++ b/tunnel/build.gradle @@ -87,4 +87,20 @@ protobuf { } } +afterEvaluate({ project -> + // All custom configurations created by the protobuf plugin, + // are only available at this point. + def protoc = configurations.getByName('protobufToolsLocator_protoc') + + task copyProtoc(type: Copy) { + // Used by tunnel/tools/libwg-go/Makefile run in tools/CMakeLists.txt + from protoc + into "${gradle.gradleUserHomeDir}/caches/protoc-${protocVersion}" + rename 'protoc-.*', 'protoc' + fileMode 0775 + } + + preBuild.dependsOn copyProtoc +}) + apply from: "publish.gradle" diff --git a/tunnel/tools/libwg-go/Makefile b/tunnel/tools/libwg-go/Makefile index e27f2e06..23ce61d9 100644 --- a/tunnel/tools/libwg-go/Makefile +++ b/tunnel/tools/libwg-go/Makefile @@ -28,12 +28,9 @@ GO_HASH_darwin-amd64 := 1f5f539ce0baa8b65f196ee219abf73a7d9cf558ba9128cc0fe4833d GO_HASH_darwin-arm64 := 6c7df9a2405f09aa9bab55c93c9c4ce41d3e58127d626bc1825ba5d0a0045d5c GO_HASH_linux-amd64 := e54bec97a1a5d230fc2f9ad0880fcbabb5888f30ed9666eca4a91c5a32e86cbc -PROTOC_VERSION := 3.19.1 -PROTOC_PLATFORM := $(shell uname -s | tr '[:upper:]' '[:lower:]')-$(shell uname -m) -PROTOC_HASH_linux-x86_64 := d231c807be82ffc29b02525c8c2691772eb945bc -PROTOC_HASH := $(PROTOC_HASH_$(PROTOC_PLATFORM)) +PROTOC_VERSION := 3.20.1 PROTOC_GEN_GO := $(GOPATH)/bin/protoc-gen-go -PROTOC := $(GRADLE_USER_HOME)/caches/modules-2/files-2.1/com.google.protobuf/protoc/$(PROTOC_VERSION)/$(PROTOC_HASH)/protoc-$(PROTOC_VERSION)-$(PROTOC_PLATFORM).exe +PROTOC := $(GRADLE_USER_HOME)/caches/protoc-$(PROTOC_VERSION)/protoc PROTODIR = $(CURDIR)/../../src/main/proto PROTO_INCLUDEDIR = $(CURDIR)/../../build/extracted-include-protos/debug PBDIR = $(GOPATH)/pkg/mod @@ -60,8 +57,8 @@ $(PROTOC_GEN_GO): export GOARCH := $(PROTOC_GEN_GO): export GOOS := $(PROTOC_GEN_GO): export PATH := $(BUILDDIR)/go-$(GO_VERSION)/bin/:$(PATH) $(PROTOC_GEN_GO): $(BUILDDIR)/go-$(GO_VERSION)/.prepared Makefile - go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.26 - go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.1 + go install google.golang.org/protobuf/cmd/protoc-gen-go@v1.28 + go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.2 gen/%.pb.go: export PATH := $(GOPATH)/bin:$(PATH) gen/%.pb.go: $(PROTODIR)/%.proto $(BUILDDIR)/go-$(GO_VERSION)/.prepared $(PROTOC_GEN_GO) |