美文网首页
flutter爬坑日记

flutter爬坑日记

作者: aven_kang | 来源:发表于2022-02-05 14:14 被阅读0次

    有时候在pubspec.yaml里面加依赖库,flutter run运行的时候会报错

    Error output from CocoaPods:
    ↳
        /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/universal-darwin21/rbconfig.rb:230: warning: Insecure world writable
        dir /Users/huwenkang/flutter/bin in PATH, mode 040777
        Searching for inspections failed: undefined method `map' for nil:NilClass
    
        [!] Automatically assigning platform `iOS` with version `9.0` on target `Runner` because no platform was specified. Please specify a platform
        for this target in your Podfile. See `https://guides.cocoapods.org/syntax/podfile.html#platform`.
    
    Error running pod install
    Error launching application on iPhone 11.
    

    其实这个问题,主要是iOS这里报错的,因为iOS需要执行pod下载依赖,我个人觉得,主要是苹果Mac的系统不同造成的,我的是苹果的M1自己的内核,如果单纯执行pod install,可能会报错的,综合上面代码提示的错误,需要执行下面命令

    sudo arch -x86_64 gem install ffi
    

    相关文章

      网友评论

          本文标题:flutter爬坑日记

          本文链接:https://www.haomeiwen.com/subject/pwoekrtx.html