Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Apple Mach O Linker Error #1847

Closed
Closed

Description

@junelsolis

I'm new to software development and I've run out of Google and StackOverflow searches as to how to fix this problem, so I decided to post here.

I'm running Xcode 6.4 with Mapbox-GL 0.4.5-symbols installed via Cocoapods. I get this error when I try to run my project on my iPad Retina. Here is a screenshot of the linker error.
screen shot 2015-07-08 at 5 25 42 pm

Please help me figure this out.

Activity

  1. added
    iOS
    on Jul 8, 2015
  2. 1ec5 commented on Jul 8, 2015

    @1ec5
    Contributor

    Mapbox GL doesn’t come with a “MapboxViewController” class. Any reference to it should be a compiler error. Since you’ve come as far as the linker, have you defined a MapboxViewController yourself?

  3. 1ec5 commented on Jul 8, 2015

    @1ec5
    Contributor

    Ack, never mind, I misread that log. Can you verify that your project has the -ObjC linker flag set? It should be set by CocoaPods automatically.

  4. junelsolis commented on Jul 8, 2015

    @junelsolis
    Author

    That -ObjC linker flag was set in the Project Target Build Settings, but not in the Pods, so I added it in. Now the project builds, but I get this runtime error in the console:

    dyld: Library not loaded: @rpath/Pods.framework/Pods
    Referenced from: /private/var/mobile/Containers/Bundle/Application/90EA36E2-FE37-4F3A-AA80-13198FEBAAB3/appName.app/appName
    Reason: image not found
    
  5. junelsolis commented on Jul 8, 2015

    @junelsolis
    Author

    ah, I found a solution to that: Pods.framework was set to required, not optional. In any case, setting the -ObjC linker flag in both the project and pods target solved the problem. Thank you for solving the issue for me; I've been slaving at this linker error the entire day. Now I can get around to playing with Mapbox

  6. 1ec5 commented on Jul 8, 2015

    @1ec5
    Contributor

    @flightsimmer668, that’s good to hear. Still curious as to how you got into this situation, though; pod install should set up the build settings correctly. What version of CocoaPods are you using?

  7. junelsolis commented on Jul 8, 2015

    @junelsolis
    Author

    yes, i thought it would. but also today I was tempted to install a pre-release version of cocoapods, maybe that was the problem. pod --version tells me i'm running `0.38.0.beta.2'

    I was also using mapbox-gl 0.4.5-symbols but I downgraded to 0.4.0

  8. incanus commented on Jul 8, 2015

    @incanus
    Contributor

    👉 #1849

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    buildiOS

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions