1

I'm having an issue with Xcode 7.2 and the linker command.

Since i added the google analitycs library WITHOUT POD, in my project, everytime y close the project and reopen it, i get this error.

enter image description here

What i have to do to workaround this problem is remove the library reference and add it again, and all goes well.

enter image description here

What i want to know is if this is a bug or i'm doing something wrong. Thanks!

EDIT:

this is the location of the library

enter image description here

alfreedom
  • 447
  • 5
  • 15
  • Can you specify the exact location of the Google Analytics library file location in finder? – Varun Feb 06 '16 at 17:52
  • "/Users/alfredo/Desktop/PROYECTOS IOS/Personal Musica/Personal Musica/GoogleAnalytics" i'm starting to think is because of the space in "Pesonal Musica" folder... – alfreedom Feb 06 '16 at 17:55
  • @Varun i edited the question with a photo of the path – alfreedom Feb 06 '16 at 18:00
  • 1
    Go to your build settings -> Search "library search paths" and click on that row. Let me know what data is shown. It should look something like this $SRCROOT/"Personal Musica". Also check if BITCODE is set to NO – Varun Feb 06 '16 at 18:02
  • $(inherited) $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics $(PROJECT_DIR)/Personal Musica/GoogleAnalytics BITCODE is set to NO – alfreedom Feb 06 '16 at 18:06
  • the repetition of the "$(inherited) $(PROJECT_DIR)/Personal Musica/GoogleAnalytics" is because i add the reference everytime the error happens, right? – alfreedom Feb 06 '16 at 18:09
  • Solution is simple, drag googleAnalytics folder into library search path window. Cheers – Guru Feb 06 '16 at 18:11

1 Answers1

3

Got the problem. Your library search path should have been like this

$(PROJECT_DIR)/"Personal Musica"/GoogleAnalytics


Add double quotes wherever there are folders with 2 words. xocde tries to slpit the folder name. This will generate an error. Your linker error is saying the exact thing. It's splitting the analytics folder when it encounters folder with two words.

Varun
  • 759
  • 6
  • 12
  • ok so i made this: $(inherited) $(PROJECT_DIR)/"Personal Musica"/GoogleAnalytics What is $(inherited)? – alfreedom Feb 06 '16 at 18:19
  • Here's a reference link http://stackoverflow.com/questions/15343122/what-is-inherited-in-xcodes-search-path-settings and https://amokafullofstuff.wordpress.com/2013/07/09/cocoapods-the-inherited-flag/ – Varun Feb 06 '16 at 18:32