flutter 学习四

1,flutter导入二维码插件的时候,Android apk run正常运行,iPhone就不行,根据提示安装了brew 但是一直出错,

发现是github的ping不下来,ping github.com 然后到hosts修改 

需要打开 https://ipchaxun.com/github.com/

然后修改第一个 改成自己的ip(就这个地址的ip最准确最快)

13.229.188.59 github.com

不然有可能你改完hosts以后ping可以下来数据,但是浏览器打不开github了。

2,每次新增flutter插件都要 get pagages,这样操作的话,iPhone的配置就有可能出错,所以会报错。就需要到ios文件内
pod repo update

pod install 

来处理包管理,

如果报错:

[!] The following Swift pods cannot yet be integrated as static libraries:

1就找到 ios文件下 open podfile 然后里面

 

pod install 以后 

出现了 Automatically assigning platform `ios` with version `8.0` on target `Runner` because no platform was specified. Please specify a platform for this target in your Podfile

解决办法:

修改项目里的ios/Podfile文件,

# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'
platform :ios, '8.0' #增加的内容

又出现了

CocoaPods did not set the base configuration of your project because because your project already has a custom config set. In order for CocoaPods integration to work at all, please either set the base configurations of the target BluePlaquesLondonFramework to Pods/Target Support Files/Pods/Pods.debug.xcconfig or include the Pods/Target Support Files/Pods/Pods.debug.xcconfig in your build configuration.


解决如下:在项目里把下面的Configuration都改为None,然后在pod install

在flutter中,把running的三个文件修改了

左边的三个文件也可以删了,我没有删,

之后再次 pod install就成功了

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值