报错:
截屏2020-11-24 08.42.47.png解决:
- 删除
App.framework
和Flutter.framework
和其他,最后留这些
截屏2020-11-24 11.16.18.png
2.打开Runner.xcodeproj,并删除删除App.framework
和 Flutter.framework
-
查看Build Phases > Link Binary With Libraries 和 Build Phases > Embed Frameworks
截屏2020-11-24 11.34.27.png -
在Build Phases > Thin Binary中添加以下命令
/bin/sh "$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh" embed /bin/sh "$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh" thin
- 在Build Settings > Other Linker Flags里添加 $(inherited) -framework Flutter
$(inherited) -framework Flutter
截屏2020-11-24 11.35.27.png
5.在flutter终端重新执行以下命令,重新构建iOS本地项目
flutter clean
flutter build ios --release
参考:
https://flutter.dev/docs/development/ios-project-migration
网友评论