mirror of
https://github.com/anyproto/anytype-heart.git
synced 2025-06-09 17:44:59 +09:00
commit
eeee585e8b
7 changed files with 27 additions and 16 deletions
1
.github/workflows/build.yml
vendored
1
.github/workflows/build.yml
vendored
|
@ -258,6 +258,7 @@ jobs:
|
|||
- name: setup go
|
||||
run: |
|
||||
make setup-go
|
||||
make setup-gomobile
|
||||
- name: Cross-compile library for linux amd64/arm64
|
||||
run: |
|
||||
echo $FLAGS
|
||||
|
|
27
Makefile
27
Makefile
|
@ -27,9 +27,7 @@ setup: setup-go
|
|||
setup-go:
|
||||
@echo 'Setting up go modules...'
|
||||
@go mod download
|
||||
go install github.com/ahmetb/govvv@latest
|
||||
go install golang.org/x/mobile/cmd/gomobile@latest
|
||||
go install golang.org/x/mobile/cmd/gobind@latest
|
||||
@go install github.com/ahmetb/govvv@v0.2.0
|
||||
|
||||
fmt:
|
||||
@echo 'Formatting with prettier...'
|
||||
|
@ -93,7 +91,7 @@ build-js-addon:
|
|||
@npm install -C ./clientlibrary/jsaddon
|
||||
@rm clientlibrary/jsaddon/lib.a clientlibrary/jsaddon/lib.h clientlibrary/jsaddon/bridge.h
|
||||
|
||||
build-ios: setup-go
|
||||
build-ios: setup-go setup-gomobile
|
||||
gomobile init
|
||||
@echo 'Clear xcframework'
|
||||
@rm -rf ./dist/ios/Lib.xcframework
|
||||
|
@ -107,7 +105,7 @@ build-ios: setup-go
|
|||
@cp pkg/lib/bundle/internal*.json dist/ios/json/
|
||||
@go mod tidy
|
||||
|
||||
build-android: setup-go
|
||||
build-android: setup-go setup-gomobile
|
||||
gomobile init
|
||||
@echo 'Building library for Android...'
|
||||
@$(eval FLAGS := $$(shell govvv -flags | sed 's/main/github.com\/anyproto\/anytype-heart\/util\/vcs/g'))
|
||||
|
@ -123,21 +121,24 @@ endif
|
|||
@mkdir -p dist/android/ && mv lib.aar dist/android/
|
||||
@go mod tidy
|
||||
|
||||
setup-gomobile:
|
||||
go build -o deps golang.org/x/mobile/cmd/gomobile
|
||||
go build -o deps golang.org/x/mobile/cmd/gobind
|
||||
|
||||
setup-protoc-go:
|
||||
@echo 'Setting up protobuf compiler...'
|
||||
go build -o deps/ github.com/gogo/protobuf/protoc-gen-gogofaster
|
||||
go build -o deps/ github.com/gogo/protobuf/protoc-gen-gogofast
|
||||
go build -o deps/ github.com/pseudomuto/protoc-gen-doc/cmd/protoc-gen-doc
|
||||
#go build -o deps/ github.com/gogo/protobuf/protoc-gen-gogo/gomobile
|
||||
go build -o deps github.com/gogo/protobuf/protoc-gen-gogofaster
|
||||
go build -o deps github.com/gogo/protobuf/protoc-gen-gogofast
|
||||
go build -o deps github.com/pseudomuto/protoc-gen-doc/cmd/protoc-gen-doc
|
||||
|
||||
|
||||
setup-protoc-jsweb:
|
||||
@echo 'Installing grpc-web plugin...'
|
||||
@rm -rf grpc-web
|
||||
@git clone http://github.com/grpc/grpc-web
|
||||
@rm -rf deps/grpc-web
|
||||
@git clone http://github.com/grpc/grpc-web deps/grpc-web
|
||||
git apply ./clientlibrary/jsaddon/grpcweb_mac.patch
|
||||
@[ -d "/opt/homebrew" ] && PREFIX="/opt/homebrew" $(MAKE) -C grpc-web install-plugin || $(MAKE) -C grpc-web install-plugin
|
||||
@rm -rf grpc-web
|
||||
@[ -d "/opt/homebrew" ] && PREFIX="/opt/homebrew" $(MAKE) -C deps/grpc-web install-plugin || $(MAKE) -C deps/grpc-web install-plugin
|
||||
@rm -rf deps/grpc-web
|
||||
|
||||
setup-protoc: setup-protoc-go setup-protoc-jsweb
|
||||
|
||||
|
|
|
@ -3,9 +3,9 @@ IDEA additional info:
|
|||
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
|
||||
<+>UTF-8
|
||||
===================================================================
|
||||
diff --git a/grpc-web/javascript/net/grpc/web/generator/Makefile b/grpc-web/javascript/net/grpc/web/generator/Makefile
|
||||
--- a/grpc-web/javascript/net/grpc/web/generator/Makefile
|
||||
+++ b/grpc-web/javascript/net/grpc/web/generator/Makefile
|
||||
diff --git a/deps/grpc-web/javascript/net/grpc/web/generator/Makefile b/deps/grpc-web/javascript/net/grpc/web/generator/Makefile
|
||||
--- a/deps/grpc-web/javascript/net/grpc/web/generator/Makefile
|
||||
+++ b/deps/grpc-web/javascript/net/grpc/web/generator/Makefile
|
||||
@@ -13,9 +13,9 @@
|
||||
# limitations under the License.
|
||||
|
||||
|
|
1
deps/.gitignore
vendored
1
deps/.gitignore
vendored
|
@ -1,2 +1,3 @@
|
|||
*
|
||||
!.gitignore
|
||||
!deps.go
|
6
deps/deps.go
vendored
Normal file
6
deps/deps.go
vendored
Normal file
|
@ -0,0 +1,6 @@
|
|||
package deps
|
||||
|
||||
import (
|
||||
// _ "github.com/ahmetb/govvv" // import govvv so it can be installed with make setup-go
|
||||
_ "golang.org/x/mobile/bind" // import gomobile so it will be installed with make setup-gomobile
|
||||
)
|
1
go.mod
1
go.mod
|
@ -89,6 +89,7 @@ require (
|
|||
go.uber.org/zap v1.24.0
|
||||
golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1
|
||||
golang.org/x/image v0.6.0
|
||||
golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028
|
||||
golang.org/x/net v0.10.0
|
||||
golang.org/x/oauth2 v0.8.0
|
||||
golang.org/x/text v0.9.0
|
||||
|
|
1
go.sum
1
go.sum
|
@ -1029,6 +1029,7 @@ golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvx
|
|||
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
|
||||
golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc=
|
||||
golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028 h1:4+4C/Iv2U4fMZBiMCc98MG1In4gJY5YRhtpDNeDeHWs=
|
||||
golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o=
|
||||
golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc=
|
||||
golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY=
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue