本文介绍了如何修复Cocoapod .modulemap文件未找到的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试构建项目时,出现编译时错误,提示找不到我的pod的模块映射文件",并且缺少"SwiftShimes"模块.

When I try to build my project, I get a compile time error saying that a "Module map file" for my pod cannot be found and that I am missing a "SwiftShimes" module.

这很奇怪,因为我所有的模块映射文件都在我安装Pod时应该放置的位置.

This is weird because all my modulemap files are where they should be when I install my pods.

我正在使用Xcode 10.2和Cocoapods 1.6.1.

I am using Xcode 10.2 and Cocoapods 1.6.1.

我尝试了以下->

  • 从我的项目中分解出椰壳足纲
  • 清理项目
  • 已删除的ModuleCache和DerivedData
  • 重新启动计算机

这是我遇到的错误类型->

This is the type of error I am getting ->

Module map file '/Users/kaunamohammed/Library/Developer/Xcode/DerivedData/OutNow-gxdxvzwmnijmrlajtbtyclkhrgqs/Build/Products/Debug-iphoneos/CodableFirebase/CodableFirebase.modulemap' not found

我希望我的项目能够正确构建,但事实并非如此,我不确定还有其他事情要做.

I expect my project to build properly but this is not the case and I am not sure what else to do.

这是我的Podfile的样子

This is what my Podfile looks like

platform :ios, '10.0'

workspace 'OutNow'

target 'OutNow' do
  use_modular_headers!
  #Pods for OutNow
  pod 'Instabug'
  pod 'SwiftMessages'
  pod 'CodableFirebase'
  pod 'Firebase/Core'
  pod 'Firebase/Auth'
  pod 'Firebase/Storage'
  pod 'Firebase/Firestore'
  pod 'Firebase/Messaging'
  pod 'Firebase/DynamicLinks'
  pod 'MarqueeLabel/Swift'
  pod 'RxSwift', '4.4.2'
  pod 'RxCocoa', '4.4.2'
  pod 'Kingfisher', '5.3.1'
  pod 'InstantSearchClient', '6.0'
  pod 'CoordinatorLibrary', '1.0.5'
  pod 'UIScrollView-InfiniteScroll', '1.1.0'

  target 'OutNowTests' do
    inherit! :search_paths
    # Pods for testing
  end

end

推荐答案

如果可以帮助其他人,我可以用其他方法解决此问题.我不小心打开了我的.xcproject而不是我的.xcworkspace.当我打开正确的文件时,错误消失了.

In case it helps anyone else, I was able to solve this issue a different way. I was accidentally opening up my .xcproject instead of my .xcworkspace. When I opened the correct file, the error went away.

这篇关于如何修复Cocoapod .modulemap文件未找到的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-15 06:38