Flutter:-无法使用Flutter run iOS命令构建iOS应用程序,**构建失败**

toiithl6  于 2023-02-20  发布在  Flutter
关注(0)|答案(3)|浏览(230)

Flutter:Log Details =〉Xcode build done.无法建立iOS应用程序,当我运行Flutter run iOS时,有人能帮我解决iOS相关的错误吗?

Xcode build done.                                           21.9s
    Failed to build iOS app
    Error output from Xcode build:
    ↳
        ** BUILD FAILED **
    Xcode's output:
    ↳
        === BUILD TARGET Runner OF PROJECT Runner WITH CONFIGURATION Debug ===
        ld: warning: Could not find auto-linked library 'swiftFoundation'
        ld: warning: Could not find auto-linked library 'swiftMetal'
        ld: warning: Could not find auto-linked library 'swiftDarwin'
        ld: warning: Could not find auto-linked library 'swiftUIKit'
        ld: warning: Could not find auto-linked library 'swiftCoreFoundation'
        ld: warning: Could not find auto-linked library 'swiftQuartzCore'
        ld: warning: Could not find auto-linked library 'swiftCore'
        ld: warning: Could not find auto-linked library 'swiftCoreGraphics'
        ld: warning: Could not find auto-linked library 'swiftObjectiveC'
        ld: warning: Could not find auto-linked library 'swiftDispatch'
        ld: warning: Could not find auto-linked library 'swiftCoreMedia'
        ld: warning: Could not find auto-linked library 'swiftSwiftOnoneSupport'
        ld: warning: Could not find auto-linked library 'swiftCoreImage'
        ld: warning: Could not find auto-linked library 'swiftCoreAudio'
        Undefined symbols for architecture x86_64:
    • Flutter 医生-v**

[] Flutter(通道稳定,v1.9.1 + hotfix.6,在Mac OS X 10.14.6 18G87上,语言环境en-IN)·Flutter版本1.9.1 + hotfix.6位于/Users/btlmac/www/flutter·框架修订版68587a0916(10周前),2019年9月13日19:46:58 - 0700·引擎修订版b863200c37·Dart版本2.5.0
[] Android工具链-为Android设备开发(Android SDK版本28.0.3)·Android SDK位于/Users/btlmac/Library/Android/sdk·Android NDK位置未配置(可选;·Android平台Android-29,构建工具28.0.3·ANDROID_HOME =/Users/btlmac/Library/Android/sdk·Java二进制文件位于:/应用程序/Android www.example.com·Java版本OpenJDK运行时环境(内部版本1.8.0_152-版本-1024 -b01)·接受所有Android许可证。Studio.app/Contents/jre/jdk/Contents/Home/bin/java · Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01) · All Android licenses accepted.
[] Xcode-为iOS和macOS开发(Xcode 10.2.1)·Xcode位于/应用程序/www.example.com·Xcode 10.2.1,构建版本10E1001·CocoaPods版本1.8.4Xcode.app/Contents/Developer · Xcode 10.2.1, Build version 10E1001 · CocoaPods version 1.8.4
[] Android工作室(版本3.1)·Android工作室在/应用程序/Android www.example.com·Flutter插件版本29.0.1· dart 插件版本173.4700·Java版本OpenJDK运行时环境(构建1.8.0_152-release-1024-b01)Studio.app/Contents · Flutter plugin version 29.0.1 · Dart plugin version 173.4700 · Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1024-b01)
[] VS代码(版本1.40.1)·VS代码位于/应用程序/Visual Studio www.example.com·Flutter扩展版本3.6.0Code.app/Contents · Flutter extension version 3.6.0
[]连接设备(2可用)·联想X3a40·5453f602·安卓-arm64·安卓6.0.1(API 23)·iPhone X·A70C38B1-AE7B-4EF5-B570 - 8872C81C147B·ios·com·苹果·核心模拟器·模拟运行时·iOS-12 - 2(模拟器)
未发现问题!

envsm3lx

envsm3lx1#

运行flutter clean通常可以解决生成问题。该命令会清除项目的生成缓存,尝试再次运行应用应重新生成项目并可能清除任何错误。
如果您仍然有问题,提供一个minimal repro也会很有帮助,这样人们就可以复制给定的问题。

ljo96ir5

ljo96ir52#

尝试设置您的Runner〉Info〉Configurations,如下所示Flutter Run with Hot Reload on Real iOS Devices guide🙂

bvjveswy

bvjveswy3#

您可以打开Xcode来查看问题的原因。转到您的项目文件夹,打开ios文件夹,运行Runner.xcworkspace文件,然后从Xcode运行它。如果您有任何无法修复的问题,请询问它。
flutter clean命令是您可以测试的另一个解决方案。在flutter clean之后,请确保您将再次下载并应用SDK。

相关问题