Skip to content

Commit

Permalink
Upgrade flutter_rust_bridge to 2.2.0 version (#167)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexlapa authored Aug 13, 2024
1 parent ec91f53 commit 6e194ea
Show file tree
Hide file tree
Showing 37 changed files with 17,352 additions and 10,932 deletions.
124 changes: 97 additions & 27 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 6 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -299,15 +299,12 @@ ifeq ($(shell brew list | grep -Fx llvm),)
brew install llvm
endif
endif
flutter_rust_bridge_codegen --rust-input=crates/native/src/api.rs \
--dart-output=lib/src/api/bridge.g.dart \
--skip-add-mod-to-lib \
--no-build-runner \
--dart-enums-style \
--inline-rust
sed -i$(if $(call eq,$(CURRENT_OS),macos), '',) \
's/^pub use io::\*;$$/pub use self::io::*;/' \
crates/native/src/bridge_generated.rs
flutter_rust_bridge_codegen generate \
--rust-input=crate::api \
--rust-root=crates/native \
--no-add-mod-to-lib \
--dart-output=lib/src/api/bridge \
--no-web
flutter pub run build_runner build --delete-conflicting-outputs


Expand Down
3 changes: 1 addition & 2 deletions analysis_options.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ analyzer:
errors:
invalid_use_of_visible_for_testing_member: error
exclude:
- '**/*.g.dart'
- '**/*.freezed.dart'
- 'lib/src/api/bridge/**' # autogenerated by `flutter_rust_bridge`

linter:
# List of all available lints can be found here:
Expand Down
5 changes: 3 additions & 2 deletions crates/native/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ anyhow = "1.0"
cxx = "1.0"
dashmap = "6.0"
derive_more = { version = "1.0", features = ["as_ref", "display", "from", "into"] }
flutter_rust_bridge = { version = "=1.82.4", default-features = false }
flutter_rust_bridge_macros = { version = "=1.82.4", default-features = false }
flutter_rust_bridge = { version = "=2.2.0", features = ["rust-async", "anyhow", "thread-pool", "dart-opaque"], default-features = false }
flutter_rust_bridge_macros = { version = "=2.2.0", default-features = false }
lazy_static = "1.5"
libwebrtc-sys = { path = "../libwebrtc-sys" }
log = "0.4"
Expand All @@ -28,6 +28,7 @@ pulse = { version = "2.28", package = "libpulse-binding" }

[target.'cfg(target_os = "windows")'.dependencies]
windows = { version = "0.58", features = ["implement", "Win32_Foundation", "Win32_Graphics_Gdi", "Win32_Media_Audio", "Win32_System_Com", "Win32_UI_Shell_PropertiesSystem", "Win32_UI_WindowsAndMessaging"] }
windows-core = "0.58" # for `#[windows::core]` macro expansion

[build-dependencies]
anyhow = "1.0"
Expand Down
Loading

0 comments on commit 6e194ea

Please sign in to comment.