ios - Xcode - 在归档项目时在框架模块错误中包含非模块化 header

标签 ios objective-c swift xcode cocoapods

当我遇到这个问题时,我目前正在尝试存档我的项目,以便最终在应用商店中更新我的应用。

我在 XlsxReaderWriter 中的多个文件上遇到此错误框架。

在框架模块“XlsxReaderWriter.BRARelationship”中包含非模块化 header :“/Users/dannyespina/Documents/iOS_Applications/LoanMaster/loan-master/Pods/XMLDictionary/XMLDictionary/XMLDictionary.h”

enter image description here

enter image description here

我过去曾遇到过这个框架的问题,但不幸的是,这是唯一一个写入 excel 文件的框架。我必须进行一些更改才能使其正常工作,如图所示 here .

我尝试了一切来解决这个问题,例如:

  • 将 Pods 项目和 LoanMaster 的“允许非模块化包含在框架模块中”设置为 YES
  • 多次清理项目并删除派生数据
  • 正在重新安装 Xcode。
  • 将 XMLDictionary.h 作为堆栈溢出答案之一中提到的公共(public) header
  • 确保框架是公开的
  • 将 pod 更新到最新版本 (1.8.4)

奇怪的是,我过去使用这个框架对这个项目进行了完全相同的更改。该库已经 3 年没有更新了,所以没有什么新的东西会导致这个。这是新版 Xcode 的问题吗?

我真的只想更新我过去 6 个月一直在开发的应用程序 :(

任何帮助都会很棒!


播客文件

# Uncomment the next line to define a global platform for your project
platform :ios, '11.0'

target 'LoanMaster' do
  # Comment the next line if you're not using Swift and don't want to use dynamic frameworks
  use_frameworks!

  # Pods for LoanMaster
  pod 'MPNumericTextField', '~> 1.4.0'
  pod 'Charts', '~> 3.2.1'
  pod 'LGButton'
  pod 'RealmSwift'
  pod 'SpreadsheetView'
  pod 'IQKeyboardManagerSwift'
  pod 'GoogleMobileAdsMediationMoPub'
  pod 'PersonalizedAdConsent'
  pod 'PopupDialog', '~> 1.1'
  pod 'NVActivityIndicatorView'
  pod 'FBAudienceNetwork'
  pod 'Firebase/Core'
  pod 'Firebase/AdMob'
  pod 'XlsxReaderWriter', '~> 1.0'
  pod 'M13Checkbox'

    post_install do |installer|
      installer.pods_project.targets.each do |target|
        if ['SpreadsheetView', 'IQKeyboardManagerSwift', 'NVActivityIndicatorView'].include? target.name
          target.build_configurations.each do |config|
            config.build_settings['SWIFT_VERSION'] = '4.0'
          end
        target.build_configurations.each do |config|
          config.build_settings['CLANG_WARN_DOCUMENTATION_COMMENTS'] = 'NO'
        end
      end
    end
  end

end

最佳答案

我通过将 XMLDictionary.h 添加到 XlsxReaderWriter 的公共(public) header 并将导入“XMLDictionary/XMLDictionary.h”改回“XMLDictionary.h”解决了这个问题。

我关注了这个answer

我希望这对仍在使用这个古老且被遗忘的框架的人有所帮助。

关于ios - Xcode - 在归档项目时在框架模块错误中包含非模块化 header ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59312997/

相关文章:

arrays - swift 。 2个数组中的替代项合并

swift - 需要一些一般类(class)的建议

ios - CADisplayLink 在 iOS5.1 上运行较低的帧率

ios - 在 Swift 3 中将数据从 JSON 传递到表格 View 单元格

iOS Objective-C IBAction 两次运行方法中的代码

iphone - timeIntervalSinceNow 返回随机数

iphone - 递归方法中的 NSMutableArray 内存泄漏

ios - 从 LinkedIn API 获取电子邮件地址

ios - 没有初始化器但有属性观察器的 Swift 类

ios - 当 UICollectionView 最初加载其数据时,我们如何获得可见的 Cell IndexPath