Error using Apple frameworks in my CocoaPod podspec?

I have a cross platform library that I'm trying to push to CocoaPod, but the it is failing on the podspec validation. The error I get is:

  • ERROR | xcodebuild: Returned an unsuccessful exit code. You can use --verbose for more information.
  • ERROR | xcodebuild: MyPod/Sources/CLKComplicationServer.swift:10:8: error: no such module 'ClockKit'
  • I tried adding the frameworks to my podspec, but it is still not accepting. Here is what my podspec looks like:

    Pod::Spec.new do |s|
        ...
        s.ios.deployment_target = "8.4"
        s.watchos.deployment_target = "2.0"
        s.tvos.deployment_target = "9.0"
    
        s.requires_arc = true
    
        s.ios.framework = 'AVFoundation'
        s.watchos.framework = 'ClockKit'
    
        s.source_files = "Sources/**/*.{h,swift}"
    end
    

    What am I doing wrong? I'm having the same issue with AVFoundation . I tried adding both to my header file, but ClockKit is not recognized.

    链接地址: http://www.djcxy.com/p/89650.html

    上一篇: Process和WaitForExit而不是

    下一篇: 在我的CocoaPod podspec中使用Apple框架时出错?