- update the
FlutterAccessorySetup.swiftfile - update the
AccessorySetupBindings.hif required - run the generator for FFI:
fvm flutter pub run ffigen --config ffigen.yaml
- check the outputs of generator
- update
flutter_accessorysetup.dartif required - set lowest supported flutter version, for now it is
3.24.5
fvm install 3.24.5
fvm use 3.24.5
- run the app. By default it will use
cocoapodsto build the pub
cd example
fvm flutter devices
fvm flutter -d DEVICE_ID_FROM_DEVICES_OUTPUT
cd -
- check that library's binary contains functions from
AccessorySetupBindings.mDart code will call that functions as native ones, and will fail if there is nothing to call.
cd example/build/ios/Debug-iphonesimulator/flutter_accessorysetup/flutter_accessorysetup.framework
nm flutter_accessorysetup
- verify that app works as expected
-
verify that swift package builds correctly:
- open
Package.swiftwith Xcode and uncomment// type: .dynamic, - build it with Xcode
- find the dynamic lib binary inside the folder:
.../DerivedData/flutter_accessorysetup-cxdfwrtgxkutoqhlafpyoelbredk/Build/Products/Debug-iphoneos/PackageFrameworks/flutter-accessorysetup.framework - check that library's binary contains functions from
AccessorySetupBindings.m - comment
// type: .dynamic,back
- open
-
ensure that plugin works with the swift package integration:
- use the latest master:
fvm install master fvm use master- run the app with package integration:
cd example fvm flutter config --enable-swift-package-manager fvm flutter devices fvm flutter -d DEVICE_ID_FROM_DEVICES_OUTPUT cd -- check that
Package.swiftof the example project contains the plugin package:
cat ./example/ios/Flutter/ephemeral/Packages/FlutterGeneratedPluginSwiftPackage/Package.swiftthe dependencies section should contains something similar to:
dependencies: [ .package(name: "flutter_accessorysetup", path: ".../flutter-accessorysetup/ios/flutter_accessorysetup"), .package(name: "integration_test", path: .../ios/integration_test") ],- verify that app works as expected
- revert the flutter version
fvm use 3.24.5 fvm flutter -d DEVICE_ID_FROM_DEVICES_OUTPUT cd -