尝试在Xcode中构建Flutter应用程序时收到以下错误消息:
ld: framework not found Flutter
clang: error: linker command failed with exit code 1 (use -v to see invocation)
当阅读发生类似错误的帖子时,建议的修复方法是将Flutter.framework
文件添加到项目中,但是本指南中概述的步骤涉及删除此文件:
https://flutter.dev/docs/development/ios-project-migration
当我将App.framework
和Flutter.framework
文件重新添加到我的应用程序中并尝试在VS Code中使用flutter build ios
时,我收到一条错误消息,告诉我要迁移项目并提供指向指南的链接以上。因此,似乎这两种解决方案都不起作用。
这是flutter doctor --v
的输出:
[✓] Flutter (Channel stable, v1.17.5, on Mac OS X 10.15.5 19F101, locale en-GB)
• Flutter version 1.17.5 at /Users/gregorysheen/Dev/flutter
• Framework revision 8af6b2f038 (10 days ago), 2020-06-30 12:53:55 -0700
• Engine revision ee76268252
• Dart version 2.8.4
[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
• Android SDK at /Users/gregorysheen/Library/Android/sdk
• Platform android-29, build-tools 29.0.2
• Java binary at: /Applications/Android
Studio.app/Contents/jre/jdk/Contents/Home/bin/java
• Java version OpenJDK Runtime Environment (build
1.8.0_202-release-1483-b49-5587405)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 11.5)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 11.5, Build version 11E608c
• CocoaPods version 1.9.3
[✓] Android Studio (version 3.5)
• Android Studio at /Applications/Android Studio.app/Contents
• Flutter plugin version 42.1.1
• Dart plugin version 191.8593
• Java version OpenJDK Runtime Environment (build
1.8.0_202-release-1483-b49-5587405)
[✓] VS Code (version 1.46.1)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.12.1
[!] Connected device
! No devices available