gpt4 book ai didi

ios - 类 AMSupportURLConnectionDelegate 在两者中都实现

转载 作者:行者123 更新时间:2023-12-03 11:15:51 25 4
gpt4 key购买 nike

我正在尝试在 M1 mac 上构建一个 flutter 应用程序并收到以下错误。

$ flutter build ios --release
Building XXX for device (ios-release)...
Automatically signing iOS for device deployment using specified development team in Xcode project: XXX
Running pod install... 13.2s
Running Xcode build...
Xcode build done. 6.7s
Failed to build iOS app
Error output from Xcode build:

objc[65074]: Class AMSupportURLConnectionDelegate is implemented in both ?? (0x1f66de518) and ?? (0x1160d82b8). One
of the two will be used. Which one is undefined.
objc[65074]: Class AMSupportURLSession is implemented in both ?? (0x1f66de568) and ?? (0x1160d8308). One of the two
will be used. Which one is undefined.
** BUILD FAILED **


Xcode's output:

note: Using new build system
note: Building targets in parallel
note: Planning build
note: Constructing build description
error: The linked framework 'Pods_Runner.framework' is missing one or more architectures required by this target:
armv7. (in target 'Runner' from project 'Runner')

Encountered error while building for device.
这是我的 flutter doctor -v
flutter doctor -v
[✓] Flutter (Channel stable, 1.22.4, on macOS 11.0 20A2411 darwin-arm, locale en-AU)
• Flutter version 1.22.4 at /Users/mlee/development/flutter
• Framework revision 1aafb3a8b9 (3 weeks ago), 2020-11-13 09:59:28 -0800
• Engine revision 2c956a31c0
• Dart version 2.10.4


[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
• Android SDK at /Users/mlee/Library/Android/sdk
• Platform android-30, build-tools 30.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_242-release-1644-b3-6915495)
• All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 12.2)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Xcode 12.2, Build version 12B45b
• CocoaPods version 1.10.0

[!] Android Studio (version 4.1)
• Android Studio at /Applications/Android Studio.app/Contents
✗ Flutter plugin not installed; this adds Flutter specific functionality.
✗ Dart plugin not installed; this adds Dart specific functionality.
• Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b3-6915495)

[✓] VS Code (version 1.51.1)
• VS Code at /Applications/Visual Studio Code.app/Contents
• Flutter extension version 3.16.0

[✓] Connected device (2 available)


! Doctor found issues in 1 category.

最佳答案

首先尝试一个简单的、记录在案的步骤
在终端:

sudo xcode-select -r
解释
该命令将 xcode 重置为默认路径(参见 文档 下面的摘录)。这个命令
  • 为我和
  • 解决了这个问题
  • 避免了从陌生人那里引入随机、无证想法的风险。

  • 这些优势使其值得首先尝试,特别是因为记录在案的方法通常不会干扰 future 的版本升级。实验性变通办法可能需要先撤消。
    文件
    % xcode-select -h
    Usage: xcode-select [options]

    Print or change the path to the active developer directory. This directory
    controls which tools are used for the Xcode command line tools (for example,
    xcodebuild) as well as the BSD development commands (such as cc and make).

    Options:
    -h, --help print this help message and exit
    [...]
    -r, --reset reset to the default command line tools path

    关于ios - 类 AMSupportURLConnectionDelegate 在两者中都实现,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65089767/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com