Apple Mach-O Linker Error when using Google Maps SDK for IOS

后端 未结 3 2053
滥情空心
滥情空心 2020-12-21 12:21

I am trying to use the Google Maps SDK in my app. So far, I have linked all the frameworks. I am pretty sure I have added the appropriate -ObjC flags as per the

相关标签:
3条回答
  • 2020-12-21 12:30

    Versions 1.9.2 and earlier of the Google Maps SDK for iOS were available as a zip file containing a static framework. There was also the option to install recent versions from a CocoaPods pod. From version 1.10.0 onwards, the Google Maps SDK for iOS is available for installation only via CocoaPods.

    0 讨论(0)
  • 2020-12-21 12:34

    UPDATE: this answer is outdated. The documentation now tells you to use CocoaPods instead of manually linking dependencies.

    For more information, see Google Developers Console.

    OLD ANSWER:

    The Google Maps SDK requires you to link quite a few frameworks. Here they are:

    • AVFoundation.framework
    • CoreData.framework
    • CoreLocation.framework
    • CoreText.framework
    • GLKit.framework
    • ImageIO.framework
    • libc++.dylib
    • libicucore.dylib
    • libz.dylib
    • OpenGLES.framework
    • QuartzCore.framework
    • SystemConfiguration.framework

    I found this list at here.

    0 讨论(0)
  • 2020-12-21 12:38

    As you said, you're using the Google Maps SDK for iOS. Yet, it looks like you are compiling for OS X, as the symbols are undefined for i386, an Intel processor. (Unless you are trying to compile for the simulator)

    The SDK may not be compiled for the simulator. You can check by running the SDK binary through the "file" command. If it has support for ARM processors, but not i386, it doesn't have support for the simulator. You'll have to change your build flags to only compile for armv7/armv7s processors.

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