flutter - Swift pod 还不能集成为静态库
问题描述
我正在用 Flutter 构建一个应用程序。我在执行“pod install”时收到此错误消息,并且 pod 安装失败并停止。
错误信息:
[!] 以下 Swift pod 还不能集成为静态库:
Swift pod
DKPhotoGallery
依赖于SDWebImage
andSDWebImageFLPlugin
,它们不定义模块。要选择生成模块映射的目标(在构建为静态库时需要从 Swift 导入它们),您可以use_modular_headers!
在 Podfile 中全局设置,或指定:modular_headers => true
特定的依赖项。
我应该在哪里设置“use_modular_headers!” 在 Podfile 中?谢谢!
解决方案
我尝试了解决方案。“使用框架!” 应在 'ios/Podfile' 中添加:
.
.
.
target 'Runner' do
# Flutter Pod
use_frameworks! #add here
copied_flutter_dir = File.join(__dir__, 'Flutter')
copied_framework_path = File.join(copied_flutter_dir, 'Flutter.framework')
copied_podspec_path = File.join(copied_flutter_dir, 'Flutter.podspec')
.
.
.
推荐阅读
- javascript - 如何在茉莉花中获取当前的套件名称?
- php - 将 pdf 导出添加到购物用品模板
- amazon-web-services - Access 2 AWS API Gateways with single CNAME
- java - passing boolean value between class not working as intended
- quickbooks - How to filter for a object wiith a "value" and "name" in QBO api?
- javascript - Slick slider thumbs not showing
- python - 自生成密钥程序
- regex - 搜索 2 列,但第一列可能有空格
- c# - Syncfusion GridTemplateColumn 第一个输入的字母被忽略
- javascript - 如何禁用下拉菜单中的第一个链接(js)