Framework not found GoogleMaps sdk in iOS

后端 未结 12 2043
伪装坚强ぢ
伪装坚强ぢ 2020-12-08 20:14

I want to use google map to existing(not a new one) iPhone project.Now i am using Google map ios sdk and i successfully added google map framework to my project.But i got er

相关标签:
12条回答
  • 2020-12-08 20:53

    If you use Pods

    Left menu > Pods > Pods > choose Framework > right menu > copy path from "ios/....."

    My: ios/Pods/GoogleMaps/Maps/Frameworks/GoogleMaps.framework

    Then Project > Build Setting > Framework Search Path > Click on

    $(PROJECT_DIR)/ios/Pods/GoogleMaps/Maps/Frameworks/GoogleMapsCore.framework

    0 讨论(0)
  • 2020-12-08 20:54

    Follow the steps :

    • Download GoogleMaps-iOS-1.1.0.zip from their site
    • Unzip the file. You now have a GoogleMaps-iOS-1.1.0 folder
    • In that folder you have a GoogleMaps.framework folder.
    • Copy or move the GoogleMaps.framework folder to inside your project folder (in Finder).
    • Drag the GoogleMaps.framework folder onto your Frameworks group in Xcode.
    • In the options sheet, uncheck "Copy items into destination group's folder". Make sure your target is checked in "Add to targets". Click OK.
    • (Note that you can also do this the other way, by not copying it into your project folder and checking "Copy items into destination group's folder". Xcode will copy the folder itself.)

    • Import using #import "GoogleMaps/GoogleMaps.h". The angle bracket usually work too, but in this case it should use quotes.

    From : <GoogleMaps/GoogleMaps.h> file not found Google Maps SDK for iOS

    0 讨论(0)
  • 2020-12-08 20:56

    Clean your project. The shortcut is command + shift + k. This will clear information that xcode has stored that might imply that the sdk isn't included.

    Also press the project icon at the top of the hierarchy of files, press the target that is your project, press build phases, open link with binary libraries, and make sure that the google maps sdk is in there. If it is not, press + and add it in.

    0 讨论(0)
  • 2020-12-08 21:01

    Sometimes it happens when you are migrating the code from one system to another so your Framework search paths look empty at this moment, so one simple solution I try is to reinstall the podfile and it works for me.

    0 讨论(0)
  • 2020-12-08 21:04

    Delete derived data and delete Podfile.lock file and then run pod install.

    0 讨论(0)
  • 2020-12-08 21:04

    In my case, I forgot that I need to open the workspace file with pods, not the project.

    0 讨论(0)
提交回复
热议问题