Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No Such Module Found adding dependency in Podspec

I am creating a framework in iOS Using Swift. I have created the podspec file and put the dependency of googlemap in my framework.

When I am trying to install the my framework in sample application,It shows "No Such Module Find" for "GooogleMaps". Please let me how to link google maps in my framework so any application when install my cocoapod will automatically get GoogleMaps without any error.

like image 730
ManiaChamp Avatar asked Oct 17 '22 09:10

ManiaChamp


1 Answers

If you have created a pod and in your .podspec file you are trying to add a dependency (like Alamofire, RealmSwift..) after that you should go to the Example/.. folder and do a pod install to make the dependencies required from the .podspec of your custom pod visible to the .swift files in your custom pod/framework.

A typical example of a pod project folder hierarchy would be:

- SMCustomPod/
  - _Pods.xcodeproj
  - Example/ // <-- do a pod install under this folder in order to get the dependencies declared in your .podspec
    - Podfile
    - SMCustomPod.xcodeproj
    - SMCustomPod.xcworkspace
  - SMCustomPod/
    - Classes/ // <-- folder with pod specific logic that also uses Alamofire
    - Assets/
  - SMCustomPod.podspec  // <-- your podspec with dependencies (Alamofire..)
like image 118
denis_lor Avatar answered Nov 02 '22 23:11

denis_lor