antonio081014 antonio081014 - 1 month ago 24
Swift Question

Cocoapods: no such module 'CorePlot'

I have an Objective-C project.


  • Most of files are written in Objc

  • Several custom
    UIView
    classes are written in Swift.

  • Specially one of
    UIViewController
    subclass using Core-Plot is written in Objc.



It has no problem, until...
Now, I am trying to create a new
UIViewController
using Core-Plot written in Swift.

Trying to use
import CorePlot
to import external framework Core-Plot as described here. But the compiler shows the error "No such module 'CorePlot'"

Here is my Podfile:

platform :ios, '8.0'

target 'Meters' do
# use_frameworks!

# Pods for Meters
pod 'PQFCustomLoaders', '~> 1.1.0'
pod 'CorePlot'
end



  • I have used
    pod install
    and 'pod update'

  • I tried "Clean and rebuild"



Neither works for me. Please let me know if any other information needed.

Answer

You have to build pods as frameworks (uncomment use_frameworks! in the pod file) to create modules. Core Plot will work fine that way but I don't know about the other pod you're using.