6

我尝试导入谷歌地图 SDK,并添加所有库,如谷歌地图网站上所述。请帮我!:)

Undefined symbols for architecture i386:
"_GLKMatrix3Identity", referenced from:
  gmscore::vector::GLLineGroup::SetTransform(gmscore::math::Matrix4f const&, gmscore::base::reffed_ptr<gmscore::vector::Camera> const&) in GoogleMaps(GLLineGroup.o)
  gmscore::vector::GLAlphaOnlyTextureShaderProgram::GLAlphaOnlyTextureShaderProgram(bool) in GoogleMaps(GLBasicShaderState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit, bool, gmscore::renderer::TextureState::Filter, gmscore::renderer::TextureState::Filter) in GoogleMaps(TextureState.o)
  ...
  gmscore::vector::GLLineGroup::SetTransform(gmscore::math::Matrix4f const&, gmscore::base::reffed_ptr<gmscore::vector::Camera> const&) in GoogleMaps(GLLineGroup.o)
  gmscore::vector::GLAlphaOnlyTextureShaderProgram::GLAlphaOnlyTextureShaderProgram(bool) in GoogleMaps(GLBasicShaderState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit, bool, gmscore::renderer::TextureState::Filter, gmscore::renderer::TextureState::Filter) in GoogleMaps(TextureState.o)
  ...
  gmscore::vector::GLLineGroup::SetTransform(gmscore::math::Matrix4f const&, gmscore::base::reffed_ptr<gmscore::vector::Camera> const&) in GoogleMaps(GLLineGroup.o)
  gmscore::vector::GLAlphaOnlyTextureShaderProgram::GLAlphaOnlyTextureShaderProgram(bool) in GoogleMaps(GLBasicShaderState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit, bool, gmscore::renderer::TextureState::Filter, gmscore::renderer::TextureState::Filter) in GoogleMaps(TextureState.o)
  ...
  gmscore::vector::GLLineGroup::SetTransform(gmscore::math::Matrix4f const&, gmscore::base::reffed_ptr<gmscore::vector::Camera> const&) in GoogleMaps(GLLineGroup.o)
  gmscore::vector::GLAlphaOnlyTextureShaderProgram::GLAlphaOnlyTextureShaderProgram(bool) in GoogleMaps(GLBasicShaderState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(unsigned int) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit) in GoogleMaps(TextureState.o)
  gmscore::renderer::TextureState::TextureState(gmscore::base::reffed_ptr<gmscore::renderer::ImageData> const&, gmscore::renderer::TextureState::TextureUnit, bool, gmscore::renderer::TextureState::Filter, gmscore::renderer::TextureState::Filter) in GoogleMaps(TextureState.o)
  ...
"_GLKMatrix4Identity", referenced from:
  -[GMSTilesEntityProvider updateAndTransformTile:camera:renderer:behavior:] in GoogleMaps(GMSTilesEntityProvider.o)
  -[GMSGLVectorTile applyTransform:camera:] in GoogleMaps(GMSGLVectorTile.o)
  (anonymous namespace)::PointsBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSPointsEntityProvider.o)
  (anonymous namespace)::StickerBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSStickersEntityProvider.o)
  (anonymous namespace)::BubbleBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSBubbleEntityProvider.o)
  gmscore::streetview::Panorama::Panorama(int, int, int, int, int, int) in GoogleMaps(Panorama.o)
  gmscore::vector::UpdateMyLocationBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GLMyLocation.o)
  ...
  -[GMSTilesEntityProvider updateAndTransformTile:camera:renderer:behavior:] in GoogleMaps(GMSTilesEntityProvider.o)
  -[GMSGLVectorTile applyTransform:camera:] in GoogleMaps(GMSGLVectorTile.o)
  (anonymous namespace)::PointsBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSPointsEntityProvider.o)
  (anonymous namespace)::StickerBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSStickersEntityProvider.o)
  (anonymous namespace)::BubbleBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSBubbleEntityProvider.o)
  gmscore::streetview::Panorama::Panorama(int, int, int, int, int, int) in GoogleMaps(Panorama.o)
  gmscore::vector::UpdateMyLocationBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GLMyLocation.o)
  ...
  -[GMSTilesEntityProvider updateAndTransformTile:camera:renderer:behavior:] in GoogleMaps(GMSTilesEntityProvider.o)
  -[GMSGLVectorTile applyTransform:camera:] in GoogleMaps(GMSGLVectorTile.o)
  (anonymous namespace)::PointsBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSPointsEntityProvider.o)
  (anonymous namespace)::StickerBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSStickersEntityProvider.o)
  (anonymous namespace)::BubbleBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSBubbleEntityProvider.o)
  gmscore::streetview::Panorama::Panorama(int, int, int, int, int, int) in GoogleMaps(Panorama.o)
  gmscore::vector::UpdateMyLocationBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GLMyLocation.o)
  ...
  -[GMSTilesEntityProvider updateAndTransformTile:camera:renderer:behavior:] in GoogleMaps(GMSTilesEntityProvider.o)
  -[GMSGLVectorTile applyTransform:camera:] in GoogleMaps(GMSGLVectorTile.o)
  (anonymous namespace)::PointsBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSPointsEntityProvider.o)
  (anonymous namespace)::StickerBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSStickersEntityProvider.o)
  (anonymous namespace)::BubbleBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSBubbleEntityProvider.o)
  gmscore::streetview::Panorama::Panorama(int, int, int, int, int, int) in GoogleMaps(Panorama.o)
  gmscore::vector::UpdateMyLocationBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GLMyLocation.o)
  ...
  -[GMSTilesEntityProvider updateAndTransformTile:camera:renderer:behavior:] in GoogleMaps(GMSTilesEntityProvider.o)
  -[GMSGLVectorTile applyTransform:camera:] in GoogleMaps(GMSGLVectorTile.o)
  (anonymous namespace)::PointsBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSPointsEntityProvider.o)
  (anonymous namespace)::StickerBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSStickersEntityProvider.o)
  (anonymous namespace)::BubbleBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSBubbleEntityProvider.o)
  gmscore::streetview::Panorama::Panorama(int, int, int, int, int, int) in GoogleMaps(Panorama.o)
  gmscore::vector::UpdateMyLocationBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GLMyLocation.o)
  ...
  -[GMSTilesEntityProvider updateAndTransformTile:camera:renderer:behavior:] in GoogleMaps(GMSTilesEntityProvider.o)
  -[GMSGLVectorTile applyTransform:camera:] in GoogleMaps(GMSGLVectorTile.o)
  (anonymous namespace)::PointsBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSPointsEntityProvider.o)
  (anonymous namespace)::StickerBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSStickersEntityProvider.o)
  (anonymous namespace)::BubbleBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSBubbleEntityProvider.o)
  gmscore::streetview::Panorama::Panorama(int, int, int, int, int, int) in GoogleMaps(Panorama.o)
  gmscore::vector::UpdateMyLocationBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GLMyLocation.o)
  ...
  -[GMSTilesEntityProvider updateAndTransformTile:camera:renderer:behavior:] in GoogleMaps(GMSTilesEntityProvider.o)
  -[GMSGLVectorTile applyTransform:camera:] in GoogleMaps(GMSGLVectorTile.o)
  (anonymous namespace)::PointsBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSPointsEntityProvider.o)
  (anonymous namespace)::StickerBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSStickersEntityProvider.o)
  (anonymous namespace)::BubbleBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GMSBubbleEntityProvider.o)
  gmscore::streetview::Panorama::Panorama(int, int, int, int, int, int) in GoogleMaps(Panorama.o)
  gmscore::vector::UpdateMyLocationBehavior::Commit(gmscore::renderer::EntityRenderer*) in GoogleMaps(GLMyLocation.o)
  ...
  ...
"_GLKMatrix4Invert", referenced from:
  gmscore::streetview::Camera::Unproject(gmscore::math::Vector2f const&, bool*) in GoogleMaps(Camera-B046EE312980DB98.o)
  gmscore::vector::Camera::UpdateInternals() in GoogleMaps(Camera-3E3856CABC8A9C74.o)
  gmscore::renderer::Camera3D::SetTransform(gmscore::math::Matrix4f const&) in GoogleMaps(Camera3D.o)
  gmscore::renderer::Camera3D::Transform() in GoogleMaps(Camera3D.o)
"_OBJC_CLASS_$_GLKView", referenced from:
  _OBJC_CLASS_$_GMSEntityRendererView in GoogleMaps(GMSEntityRendererView.o)
"_OBJC_METACLASS_$_GLKView", referenced from:
  _OBJC_METACLASS_$_GMSEntityRendererView in GoogleMaps(GMSEntityRendererView.o)
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
4

2 回答 2

29

希望你现在已经解决了这个问题。您遇到的问题是您在构建阶段没有GLKit.framework链接。

您应该查看入门页面以获取设置说明的完整列表,但相关步骤如下。

打开 Build Phases 选项卡,在 Link Binary with Libraries 中,添加以下框架:

  • AVFoundation.framework
  • CoreData.framework
  • CoreLocation.framework
  • CoreText.framework
  • GLKit.framework
  • ImageIO.framework
  • libc++.dylib
  • libicucore.dylib
  • libz.dylib
  • OpenGLES.framework
  • QuartzCore.framework
  • SystemConfiguration.framework
于 2013-09-25T16:07:17.663 回答
1

以上框架加

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

需要在 Build Phases -> Link Bundle with Libraries 中链接到 CoreBluetooth.framework 和 Accelerate.framework。“其他链接器标志”下的 -all_load 标志将导致“重复符号”错误。(使用 -ObjC 代替。)如果您使用 CocoaPods 安装方法(根据他们当前的说明),它应该采用所需的框架,但它仍然会被 -all_load 搞砸。

于 2015-07-15T10:28:06.903 回答