Framework not found GoogleMaps sdk in iOS
Asked Answered
E

12

28

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 error like this

ld: framework not found GoogleMaps
clang: error: linker command failed with exit code 1 (use -v to see invocation)

How to solve this issue.I am using xcode4.5 and google map iOS sdk version is 1.5. When i am creating new project with google map iOS sdk then no error getting for me.Error only for existing iOS Project.Please help me.

Effortful answered 2/10, 2013 at 5:40 Comment(0)
E
45

I solved my issue

You need to do this

  1. Click on your project (targets)
  2. Click on Build Settings
  3. Under Framework search paths (set your framework path)

Following information for getting framework search paths

  1. Right click on your framework folder (for ex: GoogleMaps.framework)
  2. select Get info
  3. copy the path from General->where and paste this path in your framework search path (path should contain in single line)

Good luck

Effortful answered 13/11, 2013 at 6:3 Comment(5)
Oh, thank you sooo much. Incorrect search path was my problem. +1Odysseus
I am not able to replicate your way. Please enlight meGalegalea
It happened to me when I started changing my FS foldersLacrimatory
For me only helped link to Headers Folder of GoogleMap Framework in Header Search PathSamualsamuel
works even without f..d PODS. when a serious implementation of SPM lib?Hyperform
T
12

I encountered a scenario in which I had to import a project that was using Google Maps and noticed the same problem - module: "Google Maps" not found. To solve this problem it was necessary to delete Podfile.lock and Podfile folder and re-install the pods again. Good luck !

Telluric answered 14/10, 2015 at 8:42 Comment(0)
C
10

You can also : - remove GoogleMaps from Podfile - pod install - add GoogleMaps to your Podfile again - pod install

This solution works for me, you can also check the search paths a well.

Cooler answered 27/8, 2018 at 12:11 Comment(1)
pod update worked for me , without modifying the pod fileForepart
I
3

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.

Incult answered 2/10, 2013 at 5:44 Comment(0)
E
2

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

Encumbrancer answered 2/10, 2013 at 5:46 Comment(0)
T
2

my problem was fixed by adding in:

build settings

Framework Search Paths

clickable and add the following lines:

"${PODS_ROOT}/GoogleMaps/Base/Frameworks"

"${PODS_ROOT}/GoogleMaps/Maps/Frameworks"

Truckload answered 1/11, 2017 at 20:7 Comment(1)
I have this problem but the baths are already included, this doesn't fix it for meConnie
A
2

If you use Pods

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

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

enter image description here

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

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

enter image description here

Anneliese answered 15/11, 2018 at 4:24 Comment(0)
M
1

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.

Mas answered 7/5, 2019 at 8:16 Comment(0)
I
0

I've been struggling with this issue for hours; I'm using CocoaPods, Swift and Xcode 6.1.1. I followed all the steps for including GoogleMaps in my project carefully, tried many different things like removing symbolic links in the downloaded package or manually linking the binaries in build phases or trying #include "GoogleMaps.h", #include "GoogleMaps/GoogleMaps.h" and "#include <GoogleMaps/GoogleMaps.h> in my bridge file, none of that worked... Finally used CocoaPods instead of including the framework myself and it worked! Hope it helps someone out there:

In the Podfile:

pod 'Google-Maps-iOS-SDK', '~> 1.9.2'

And in your Bridge file:

#import "GoogleMaps.h"

Instead answered 6/3, 2015 at 6:57 Comment(0)
K
0

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

Kymry answered 27/3, 2017 at 11:44 Comment(0)
L
0

Maybe it'll be useful for anybody, next steps helped me: 1. Delete "Headers" and "GoogleMaps" folders manually (from the Finder). 2. Run 'pod install' 3. Re-build the project in Xcode.

Legislation answered 6/3, 2018 at 21:0 Comment(0)
M
0

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

Melson answered 21/10, 2018 at 22:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.