compiling for macOS 10.11, but module xxx has a minimum deployment target of macOS 10.12

compiling for macOS 10.11, but module xxx has a minimum deployment target of macOS 10.12,第1张

想尝试flutter的桌面webview组件

搜到一个 desktop_webview_window

pubspec.yaml

  desktop_webview_window: ^0.1.5
  path_provider: ^2.0.8
flutter pub get

报错信息:

Launching lib/main.dart on macOS in debug mode...
Running pod install...
CocoaPods' output:
↳
      Preparing

    Analyzing dependencies

    Inspecting targets to integrate
      Using `ARCHS` setting to build architectures of target `Pods-Runner`: (``)

    Fetching external sources
    -> Fetching podspec for `FlutterMacOS` from `Flutter/ephemeral`
    -> Fetching podspec for `desktop_webview_window` from `Flutter/ephemeral/.symlinks/plugins/desktop_webview_window/macos`
    -> Fetching podspec for `path_provider_macos` from `Flutter/ephemeral/.symlinks/plugins/path_provider_macos/macos`

    Resolving dependencies of `Podfile`
      CDN: trunk Relative path: CocoaPods-version.yml exists! Returning local because checking is only perfomed in repo update
    [!] CocoaPods could not find compatible versions for pod "desktop_webview_window":
      In Podfile:
        desktop_webview_window (from `Flutter/ephemeral/.symlinks/plugins/desktop_webview_window/macos`)

    Specs satisfying the `desktop_webview_window (from `Flutter/ephemeral/.symlinks/plugins/desktop_webview_window/macos`)` dependency were found, but they required a higher minimum deployment target.

    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:328:in `raise_error_unless_state'
    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:310:in `block in unwind_for_conflict'
    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:308:in `tap'
    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:308:in `unwind_for_conflict'
    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:684:in `attempt_to_activate'
    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:254:in `process_topmost_state'
    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolution.rb:182:in `resolve'
    /Library/Ruby/Gems/2.6.0/gems/molinillo-0.6.6/lib/molinillo/resolver.rb:43:in `resolve'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/resolver.rb:94:in `resolve'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:1074:in `block in resolve_dependencies'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/user_interface.rb:64:in `section'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:1072:in `resolve_dependencies'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer/analyzer.rb:124:in `analyze'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:414:in `analyze'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:239:in `block in resolve_dependencies'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/user_interface.rb:64:in `section'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:238:in `resolve_dependencies'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/installer.rb:160:in `install!'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/command/install.rb:52:in `run'
    /Library/Ruby/Gems/2.6.0/gems/claide-1.0.3/lib/claide/command.rb:334:in `run'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/lib/cocoapods/command.rb:52:in `run'
    /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.10.1/bin/pod:55:in `'
    /usr/local/bin/pod:23:in `load'
    /usr/local/bin/pod:23:in `
' Error output from CocoaPods: ↳ /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/universal-darwin20/rbconfig.rb:229: warning: Insecure world writable dir /Users/qiang/program in PATH, mode 040777 Exception: Error running pod install
Specs satisfying the `desktop_webview_window (from `Flutter/ephemeral/.symlinks/plugins/desktop_webview_window/macos`)` dependency were found, but they required a higher minimum deployment target.
sudo chmod 775 路径
Launching lib/main.dart on macOS in debug mode...
Running pod install...
Building macOS application...
--- xcodebuild: WARNING: Using the first of multiple matching destinations:
{ platform:macOS, arch:x86_64, id:A986645C-6596-5690-B2B9-1BA7B1F60514 }
{ platform:macOS, name:Any Mac }

Launching lib/main.dart on macOS in debug mode...
Building macOS application...
--- xcodebuild: WARNING: Using the first of multiple matching destinations:
{ platform:macOS, arch:x86_64, id:A986645C-6596-5690-B2B9-1BA7B1F60514 }
{ platform:macOS, name:Any Mac }
/Users/qiang/code/项目代码/p3_jd/macos/Flutter/GeneratedPluginRegistrant.swift:8:8: error: compiling for macOS 10.11, but module 'desktop_webview_window' has a minimum deployment target of macOS 10.12: /Users/qiang/code/项目代码/p3_jd/build/macos/Build/Products/Debug/desktop_webview_window/desktop_webview_window.framework/Modules/desktop_webview_window.swiftmodule/x86_64-apple-macos.swiftmodule
import desktop_webview_window
       ^
/Users/qiang/code/项目代码/p3_jd/macos/Flutter/GeneratedPluginRegistrant.swift:8:8: error: compiling for macOS 10.11, but module 'desktop_webview_window' has a minimum deployment target of macOS 10.12: /Users/qiang/code/项目代码/p3_jd/build/macos/Build/Products/Debug/desktop_webview_window/desktop_webview_window.framework/Modules/desktop_webview_window.swiftmodule/x86_64-apple-macos.swiftmodule
import desktop_webview_window
       ^
/Users/qiang/code/项目代码/p3_jd/macos/Flutter/GeneratedPluginRegistrant.swift:8:8: error: compiling for macOS 10.11, but module 'desktop_webview_window' has a minimum deployment target of macOS 10.12: /Users/qiang/code/项目代码/p3_jd/build/macos/Build/Products/Debug/desktop_webview_window/desktop_webview_window.framework/Modules/desktop_webview_window.swiftmodule/x86_64-apple-macos.swiftmodule
import desktop_webview_window
       ^
note: Using new build system
note: Planning
note: Build preparation complete
note: Building targets in dependency order
** BUILD FAILED **

Exception: Build process failed

使用Xcode打开项目中macOS下的项目
修改项目的目标平台版本

项目成功运行

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/web/996992.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-21
下一篇 2022-05-21

发表评论

登录后才能评论

评论列表(0条)

保存