Search code examples
iosxcodeframeworkscocoapodspodfile

iOS App CocoaPod Blues: Podfile not pulling in Frameworks any more


I have an Build issue (with cocoapods) that's been dogging me for a day. It came out of the blue as the Builds were working fine until yesterday.

The way the frameworks section of my cocoapods is setup is:

For the framework

platform :ios, '7.0'

def common_pods
  pod 'Godzippa'
  pod 'FrostyLIB', :path => "~/dev/AppCode/FrostyLib/"
end

target 'CoolDocsSDK' do
  common_pods
end

target 'CoolDocsSDKTests' do
  common_pods
  pod 'OCMock', '~> 3.2'
end

post_install do |installer|
  installer.pods_project.targets.each do |target|
    if target.name == 'FROSTY'
      target.build_configurations.each do |config|
      config.build_settings['CLANG_WARN_DOCUMENTATION_COMMENTS'] = ['NO']
        if config.name == 'Release'
          config.build_settings['GENERATE_MASTER_OBJECT_FILE'] = ['YES']
          config.build_settings['STRIP_STYLE'] = ['non-global']
          config.build_settings['DEPLOYMENT_POSTPROCESSING'] = ['YES']
          config.build_settings['GCC_GENERATE_DEBUGGING_SYMBOLS'] = ['NO']
          config.build_settings['GCC_PRECOMPILE_PREFIX_HEADER'] = ['NO']
        end
      end
    end
  end
end

This builds perfectly.

The way the App Podfile is setup is:

platform :ios, '10.0'

def common_pods
    # Pods for CoolDocsApp

    pod 'Fabric'
    pod 'Crashlytics', '~>  3.9'
    pod 'M13ProgressSuite'
    pod 'SwiftyStoreKit'
    pod 'OpenSSL-Universal', '~> 1.0'
    pod 'FacebookCore'
    pod 'AppsFlyerFramework'
    pod 'SideMenu'
    pod 'GoogleMaps'
    pod 'GooglePlaces'
    pod 'VideoBackgroundViewController'

    #Release Pod
    pod 'CoolDocsSDK', :path => "~/Desktop/CoolDocsSDK-iOS/"
end

target 'CoolDocsApp' do
    use_frameworks!
    common_pods
end

target 'CoolDocsAppStaging' do
    use_frameworks!
    common_pods
end

Framework builds fine. As you can see, the App has a Production target (CoolDocsApp) and a Staging target (CoolDocsAppStaging)

Blockquote

The App has the following Pods not being installed during pod install (shown in XCode)

enter image description here As you can see, aside from GodZippa - none of the other Pods are being installed.

I am not sure why this stopped working yesterday. The App builds started failing right around the time I built the Production Target in XCode, and then switched back to building the Dev Target. The framework builds work fine

Some of the Pods fail with the following error:

The file “VideoBackgroundViewController.xcconfig” couldn’t be opened because there is no such file. (/Users/CooldocsMan/dev/AppCode/CoolDocsApp/Pods/Target Support Files/VideoBackgroundViewController/VideoBackgroundViewController.xcconfig)
error: unable to read module map contents from 'Target Support Files/VideoBackgroundViewController/VideoBackgroundViewController.modulemap': Error Domain=NSCocoaErrorDomain Code=260 "The file “VideoBackgroundViewController.modulemap” couldn’t be opened because there is no such file." UserInfo={NSFilePath=/Users/CooldocsMan/dev/AppCode/CoolDocsApp/Pods/Target Support Files/VideoBackgroundViewController/VideoBackgroundViewController.modulemap, NSUnderlyingError=0x7f8965daaa40 {Error Domain=NSPOSIXErrorDomain Code=2 "No such file or directory"}}
error: unable to read module map contents from 'Target Support Files/VideoBackgroundViewController/VideoBackgroundViewController.module

APPRECIATE YOUR HELP RESOLVING THIS!


Solution

  • I rebooted my Mac and reran the pod install and XCode build for the App and it worked just fine..

    So in this situation a simple reboot helps.