GoogleMapsSDK:架构x86_64的未定义符号 [英] GoogleMapsSDK : Undefined symbols for architecture x86_64

查看:365
本文介绍了GoogleMapsSDK:架构x86_64的未定义符号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试安装Google maps SDK,并且在运行时遇到此错误:

I am trying to install the Google maps SDK and I am running through this error when running:

Undefined symbols for architecture x86_64:
  "_CBAdvertisementDataManufacturerDataKey", referenced from:
      -[GMSx_PEBeaconScanner centralManager:didDiscoverPeripheral:advertisementData:RSSI:] in GoogleMaps(PEBeaconScanner.o)
  "_CBAdvertisementDataServiceDataKey", referenced from:
      -[GMSx_PEBeaconScanner centralManager:didDiscoverPeripheral:advertisementData:RSSI:] in GoogleMaps(PEBeaconScanner.o)
  "_CBCentralManagerScanOptionAllowDuplicatesKey", referenced from:
      -[GMSx_PEBeaconScanner scanIfAppropriate] in GoogleMaps(PEBeaconScanner.o)
  "_OBJC_CLASS_$_CBCentralManager", referenced from:
      objc-class-ref in GoogleMaps(PEBeaconScanner.o)
  "_OBJC_CLASS_$_CBUUID", referenced from:
      objc-class-ref in GoogleMaps(PEBeacon.o)
      objc-class-ref in GoogleMaps(PEBeaconScanner.o)
  "_vImageBoxConvolve_Planar8", referenced from:
      (anonymous namespace)::CreateBlurredImage(CGImage*, double, double) in GoogleMaps(GLWaterGroup.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)


推荐答案

当我升级使用手动安装的旧版Google地图SDK的应用时,我注意到以下更改:

I noticed the following changes when I upgraded an app that was using the older Google maps SDK that had been installed manually:


  • 需要链接到 CoreBluetooth.framework Accelerate.framework 在Build阶段 - > Link Bundle with Libraries。

  • 其他链接器标志下的 -all_load 标志将导致重复符号错误。 (改为使用 -ObjC 。)

  • Need to link to CoreBluetooth.framework and Accelerate.framework in Build Phases -> Link Bundle with Libraries.
  • The -all_load flag under "Other Linker Flags" will cause "duplicate symbol" errors. (Use -ObjC instead.)

如果您使用CocoaPods安装方法(根据他们当前的说明) ),它应该采用所需的框架,但它仍然会被 -all_load 弄乱。

If you use the CocoaPods method of installation (per their current instructions), it should take of the required frameworks but it'll still get messed up by -all_load.

这篇关于GoogleMapsSDK:架构x86_64的未定义符号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆