upgrade flutter to 2.10.1
This commit is contained in:
parent
52d125235a
commit
108a72d688
35
README.md
35
README.md
|
@ -76,8 +76,7 @@ VPN->代理->分流, 这三个功能如果同时设置, 您会在您手机的VPN
|
|||
### 开发环境准备
|
||||
|
||||
- [golang](https://golang.org/) (1.16以上版本)
|
||||
- [flutter](https://flutter.dev/) (stable-2.10.0)
|
||||
- flutter不同版本api差异较大,建议使用临近的beta版本
|
||||
- [flutter](https://flutter.dev/) (stable-2.10.1)
|
||||
|
||||
### 环境配置
|
||||
|
||||
|
@ -94,8 +93,17 @@ VPN->代理->分流, 这三个功能如果同时设置, 您会在您手机的VPN
|
|||
# 或
|
||||
go install github.com/go-flutter-desktop/hover@latest
|
||||
```
|
||||
- 若您希望使用stable版本的flutter, 请使用github.com/niuhuan/hover
|
||||
- 安装gcc
|
||||
&- 若您希望使用stable版本的flutter, 请使用 niuhuan/hover (官方hover不支持stable)<br />
|
||||
```shell
|
||||
go install github.com/niuhuan/hover@latest
|
||||
```
|
||||
&- niuhuan/hover支持使用代理下载flutter引擎
|
||||
```shell
|
||||
export GHPROXY=true
|
||||
hover build
|
||||
```
|
||||
|
||||
- 安装gcc (桌面端使用CGO调用flutter引擎)
|
||||
```shell
|
||||
# Windows需要安装MSYS(mingw-w64-x86_64-gcc), 并将gcc路径设置到PATH环境变量内
|
||||
# MacOS需要安装XCode
|
||||
|
@ -143,14 +151,23 @@ VPN->代理->分流, 这三个功能如果同时设置, 您会在您手机的VPN
|
|||
```shell
|
||||
go install golang.org/x/mobile/cmd/gomobile@latest
|
||||
```
|
||||
- 执行编译命令 (bind-android.sh/bind-ios.sh根据平台选择, $system替换为apk/ipa等)
|
||||
- 先编译golang库, 再打包flutter
|
||||
```shell
|
||||
|
||||
# android
|
||||
cd go/mobile
|
||||
go get golang.org/x/mobile/cmd/gobind
|
||||
sh bind-ios.sh
|
||||
sh bind-android.sh
|
||||
cd ../../
|
||||
flutter build $system
|
||||
gomobile bind -target=android -o lib/Mobile.aar ./
|
||||
cd ../..
|
||||
flutter build apk
|
||||
|
||||
# ios
|
||||
cd go/mobile
|
||||
go get golang.org/x/mobile/cmd/gobind
|
||||
gomobile bind -target=ios -o lib/Mobile.xcframework ./
|
||||
cd ../..
|
||||
flutter build ipa
|
||||
|
||||
```
|
||||
|
||||
## 请您遵守使用规则
|
||||
|
|
|
@ -326,14 +326,14 @@ packages:
|
|||
name: url_launcher_android
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "6.0.14"
|
||||
version: "6.0.15"
|
||||
url_launcher_ios:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: url_launcher_ios
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "6.0.14"
|
||||
version: "6.0.15"
|
||||
url_launcher_linux:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -361,7 +361,7 @@ packages:
|
|||
name: url_launcher_web
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.0.7"
|
||||
version: "2.0.8"
|
||||
url_launcher_windows:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -385,4 +385,4 @@ packages:
|
|||
version: "5.3.1"
|
||||
sdks:
|
||||
dart: ">=2.15.1 <3.0.0"
|
||||
flutter: ">=2.5.0"
|
||||
flutter: ">=2.10.0"
|
||||
|
|
Loading…
Reference in New Issue