关于倒入百度地图出现一堆Bug问题解决【 symbol(s) n
2016-12-19 本文已影响964人
iOS_Gato_老猫
最近接手了一个新项目
在加载百度地图SDK的时候 用的是cocoapods
一般的三方加载以后都会自动配置xcode 不需要在手动到处各种框架根库
但是百度不行
我加载的是百度2.8.1 版本
如果你出现以下为题 那么 往下看吧
d: warning: directory not found for option '-F/Users/xbm/Desktop/test/fnjss/Release-iphoneos'
Undefined symbols for architecture arm64:
"___cxa_guard_release", referenced from:
_baidu_vi::BGLCreatePolySurfaceList(_baidu_vi::CVArray<_baidu_vi::_VPointS3, _baidu_vi::_VPointS3&>&, _baidu_vi::CVArray<unsigned short, unsigned short>&, _baidu_vi::_VPointS3*, unsigned int, unsigned int, float) in BaiduMapAPI(BGLBase.o)
_baidu_vi::CreateMipMapTextrue(unsigned int&, unsigned int, unsigned int, unsigned int, char*) in BaiduMapAPI(BGLTextrue.o)
_baidu_framework::CBVDBGeoObjSet::Read(char const*, unsigned int, unsigned int) in BaiduMapAPI(BVDBBase.o)
_baidu_framework::CBVDBEntiy::Read(char const*, unsigned int, unsigned int) in BaiduMapAPI(BVDBBase.o)
_baidu_framework::GridDrawObj::CreatePolyLineCropArrowListSVBO(_baidu_vi::_VPointS3*, unsigned int, float, float) in BaiduMapAPI(DrawUnit.o)
_baidu_framework::GridDrawObj::CreatePolyLineCropArrowListS(_baidu_vi::_VPointS3*, unsigned int, float, float) in BaiduMapAPI(DrawUnit.o)
_baidu_framework::CPOIData::CalculateArc(_baidu_framework::CPOIData*, _baidu_framework::CBVDBEntiy*, _baidu_framework::CMapStatus&, _baidu_framework::EMAPSTYLE, int) in BaiduMapAPI(PoiMarkData.o)
...
"___cxa_guard_abort", referenced from:
_baidu_vi::BGLCreatePolySurfaceList(_baidu_vi::CVArray<_baidu_vi::_VPointS3, _baidu_vi::_VPointS3&>&, _baidu_vi::CVArray<unsigned short, unsigned short>&, _baidu_vi::_VPointS3*, unsigned int, unsigned int, float) in BaiduMapAPI(BGLBase.o)
_baidu_vi::CreateMipMapTextrue(unsigned int&, unsigned int, unsigned int, unsigned int, char*) in BaiduMapAPI(BGLTextrue.o)
_baidu_framework::CBVDBGeoObjSet::Read(char const*, unsigned int, unsigned int) in BaiduMapAPI(BVDBBase.o)
_baidu_framework::CBVDBEntiy::Read(char const*, unsigned int, unsigned int) in BaiduMapAPI(BVDBBase.o)
_baidu_framework::GridDrawObj::CreatePolyLineCropArrowListSVBO(_baidu_vi::_VPointS3*, unsigned int, float, float) in BaiduMapAPI(DrawUnit.o)
_baidu_framework::GridDrawObj::CreatePolyLineCropArrowListS(_baidu_vi::_VPointS3*, unsigned int, float, float) in BaiduMapAPI(DrawUnit.o)
_baidu_framework::CPOIData::CalculateArc(_baidu_framework::CPOIData*, _baidu_framework::CBVDBEntiy*, _baidu_framework::CMapStatus&, _baidu_framework::EMAPSTYLE, int) in BaiduMapAPI(PoiMarkData.o)
...
"___cxa_pure_virtual", referenced from:
vtable for _baidu_framework::CBaseLayer in BaiduMapAPI(BaseLayer.o)
vtable for _baidu_vi::CVHttpRequestBase in BaiduMapAPI(VHttpRequestBase.o)
vtable for _baidu_framework::CBaseLayerData in BaiduMapAPI(BaseLayerData.o)
"operator new[](unsigned long)", referenced from:
-[BMKArcline initWithPoints:count:] in BaiduMapAPI(BMKArcline.o)
-[BMKArcline setArclineWithPoints:] in BaiduMapAPI(BMKArcline.o)
-[BMKArcline setArclineWithCoordinates:] in BaiduMapAPI(BMKArcline.o)
-[BMKArcline initWithCoordinates:count:] in BaiduMapAPI(BMKArcline.o)
-[BMKCircle setCircleWithCenterCoordinate:radius:] in BaiduMapAPI(BMKCircle.o)
-[BMKCircle setCircleWithMapRect:] in BaiduMapAPI(BMKCircle.o)
-[BMKCircle initWithCenterCoordinate:radius:] in BaiduMapAPI(BMKCircle.o)
...
"vtable for __cxxabiv1::__si_class_type_info", referenced from:
typeinfo for BMCloudEngine in BaiduMapAPI(BMCloudEngine.o)
typeinfo for BMRadarEngine in BaiduMapAPI(BMRadarEngine.o)
typeinfo for LocalMapEngine in BaiduMapAPI(LocalMapEngine.o)
typeinfo for BMMapMsgObserver in BaiduMapAPI(BMMapMsgObserver.o)
typeinfo for CVNetStateObservable in BaiduMapAPI(VNetStateObservable.o)
typeinfo for _baidu_framework::CBaseLayer in BaiduMapAPI(BaseLayer.o)
typeinfo for _baidu_framework::IVMapbaseInterface in BaiduMapAPI(VMapControl.o)
...
NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
"vtable for __cxxabiv1::__vmi_class_type_info", referenced from:
typeinfo for CAppMan in BaiduMapAPI(AppMan.o)
typeinfo for BMSearchEngine in BaiduMapAPI(BMSearchEngine.o)
typeinfo for _baidu_framework::CVMapControl in BaiduMapAPI(VMapControl.o)
typeinfo for _baidu_framework::CSearchControl in BaiduMapAPI(SearchControl.o)
typeinfo for _baidu_framework::CCloudControl in BaiduMapAPI(CloudControl.o)
typeinfo for _baidu_framework::CVStyle in BaiduMapAPI(Style.o)
typeinfo for _baidu_framework::CRadarControl in BaiduMapAPI(RadarControl.o)
...
NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
"operator new(unsigned long)", referenced from:
-[BMKLocationServiceInternal init] in BaiduMapAPI(BMKLocationServiceInternal.o)
-[BMMapViewManager creatFirstMapControl] in BaiduMapAPI(BMMapViewManager.o)
CVNetStateObservable::getInstance() in BaiduMapAPI(VNetStateObservable.o)
CVObservable::addObserver(CVObserver*) in BaiduMapAPI(VNetStateObservable.o)
_baidu_vi::CVThreadEventMan::GetIntance() in BaiduMapAPI(VThread.o)
_baidu_vi::CVException::Init() in BaiduMapAPI(VException.o)
_baidu_framework::CNearbyRadar::GetLocationInfosNearby(unsigned int&, _baidu_vi::CVBundle&) in BaiduMapAPI(NearbyRadar.o)
...
"___cxa_begin_catch", referenced from:
___clang_call_terminate in BaiduMapAPI(BMCloudSerail.o)
"vtable for __cxxabiv1::__class_type_info", referenced from:
typeinfo for _baidu_vi::CVArray<_baidu_vi::CVString, _baidu_vi::CVString&> in BaiduMapAPI(BMCloudSerail.o)
typeinfo for _baidu_vi::CVArray<_baidu_vi::_VPoint3, _baidu_vi::_VPoint3> in BaiduMapAPI(BMKOverlayView.o)
typeinfo for _baidu_vi::CVArray<_baidu_vi::CVArray<_baidu_vi::_VPoint3, _baidu_vi::_VPoint3>, _baidu_vi::CVArray<_baidu_vi::_VPoint3, _baidu_vi::_VPoint3> > in BaiduMapAPI(BMKOverlayView.o)
typeinfo for _baidu_vi::CVArray<unsigned short, unsigned short&> in BaiduMapAPI(BMKOverlayView.o)
typeinfo for _baidu_vi::CVArray<unsigned short, unsigned short> in BaiduMapAPI(BMKOverlayView.o)
typeinfo for _baidu_vi::CVArray<float, float> in BaiduMapAPI(BMKOverlayView.o)
typeinfo for _baidu_vi::CVArray<_baidu_vi::_VPointF3, _baidu_vi::_VPointF3&> in BaiduMapAPI(BMKOverlayView.o)
...
NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
"operator delete[](void*)", referenced from:
-[BMKArcline setArclineWithPoints:] in BaiduMapAPI(BMKArcline.o)
-[BMKArcline setArclineWithCoordinates:] in BaiduMapAPI(BMKArcline.o)
-[BMKCircle setCircleWithCenterCoordinate:radius:] in BaiduMapAPI(BMKCircle.o)
-[BMKMultiPoint dealloc] in BaiduMapAPI(BMKMultiPoint.o)
-[BMKOverlayView dealloc] in BaiduMapAPI(BMKOverlayView.o)
-[BMKPolygon setPolygonWithCoordinates:count:] in BaiduMapAPI(BMKPolygon.o)
-[BMKPolygon resetPoints:count:] in BaiduMapAPI(BMKPolygon.o)
...
"___cxa_guard_acquire", referenced from:
_baidu_vi::BGLCreatePolySurfaceList(_baidu_vi::CVArray<_baidu_vi::_VPointS3, _baidu_vi::_VPointS3&>&, _baidu_vi::CVArray<unsigned short, unsigned short>&, _baidu_vi::_VPointS3*, unsigned int, unsigned int, float) in BaiduMapAPI(BGLBase.o)
_baidu_vi::CreateMipMapTextrue(unsigned int&, unsigned int, unsigned int, unsigned int, char*) in BaiduMapAPI(BGLTextrue.o)
_baidu_framework::CBVDBGeoObjSet::Read(char const*, unsigned int, unsigned int) in BaiduMapAPI(BVDBBase.o)
_baidu_framework::CBVDBEntiy::Read(char const*, unsigned int, unsigned int) in BaiduMapAPI(BVDBBase.o)
_baidu_framework::GridDrawObj::CreatePolyLineCropArrowListSVBO(_baidu_vi::_VPointS3*, unsigned int, float, float) in BaiduMapAPI(DrawUnit.o)
_baidu_framework::GridDrawObj::CreatePolyLineCropArrowListS(_baidu_vi::_VPointS3*, unsigned int, float, float) in BaiduMapAPI(DrawUnit.o)
_baidu_framework::CPOIData::CalculateArc(_baidu_framework::CPOIData*, _baidu_framework::CBVDBEntiy*, _baidu_framework::CMapStatus&, _baidu_framework::EMAPSTYLE, int) in BaiduMapAPI(PoiMarkData.o)
...
"operator delete(void*)", referenced from:
_baidu_vi::CVArray<_baidu_vi::CVString, _baidu_vi::CVString&>::~CVArray() in BaiduMapAPI(BMCloudSerail.o)
-[BMKArcline initWithCoordinates:count:] in BaiduMapAPI(BMKArcline.o)
-[BMKArcline dealloc] in BaiduMapAPI(BMKArcline.o)
-[BMKGroundOverlay dealloc] in BaiduMapAPI(BMKGroundOverlay.o)
-[BMKLocationServiceInternal dealloc] in BaiduMapAPI(BMKLocationServiceInternal.o)
-[BMKOverlayPathView applyStrokePropertiesToContext:atZoomScale:] in BaiduMapAPI(BMKOverlayPathView.o)
_baidu_vi::CVArray<_baidu_vi::_VPoint3, _baidu_vi::_VPoint3>::~CVArray() in BaiduMapAPI(BMKOverlayView.o)
...
"std::terminate()", referenced from:
___clang_call_terminate in BaiduMapAPI(BMCloudSerail.o)
"___gxx_personality_v0", referenced from:
-[MSFLocation init] in MSFLocation.o
-[MSFLocation didUpdateBMKUserLocation:] in MSFLocation.o
-[MSFLocation onGetReverseGeoCodeResult:result:errorCode:] in MSFLocation.o
-[BMAreaSearchResult init] in BaiduMapAPI(BMAreaSearchResult.o)
-[BMCityList init] in BaiduMapAPI(BMCityList.o)
+[BMCloudSerail parseCloudPOIListSearchResult:outPutResult:] in BaiduMapAPI(BMCloudSerail.o)
+[BMCloudSerail parsingCloudPOIListWithBundle:Result:] in BaiduMapAPI(BMCloudSerail.o)
...
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
问题原因
出现这个问题是因为 objc和c++混编错误 导致的 在xcode8的时候 如果不主动倒入文本库 他是不能通过编译的 更不要说使用了
解决方法
解决方法:倒入 libstdc++.6.0.9.dylib
具体 是在 General-Linked Frameworks and Libraries - libstdc++.6.0.9.dylib