我正在尝试在我的应用中使用Google Maps SDK.到目前为止,我已经链接了所有框架.我很确定我-ObjC按照说明添加了适当的标志.但是,当我将代码复制并粘贴到我的ViewController.m类中时,我收到以下错误:
架构i386的未定义符号:
"_ OBJC_CLASS _ $ _ GMSCameraPosition",引用自:FoothillTourViewController.o中的objc-class-ref"_OBJC_CLASS _ $ _ GMSMapView",引自:FoothillTourViewController.o中的objc-class-ref"_OBJC_CLASS _ $ _ GMSMarker",引用自:FoothillTourViewController.o中的objc-class-ref"_OBJC_CLASS _ $ _ GMSServices",引自:FoothillTourAppDelegate.o中的objc-class-ref:ld:未找到架构i386 clang的符号:错误:链接器命令失败,退出代码为1 (使用-v查看调用)
"FoothillTourViewController"是我ViewController班级的名字.这是我的View Controller类的代码.代码直接取自说明.
#import "FoothillTourViewController.h"
#import <GoogleMaps/GoogleMaps.h>
@implementation FoothillTourViewController {
GMSMapView *mapView_;
}
// You don't need to modify the default initWithNibName:bundle: method.
- (void)loadView {
//Create a GMSCameraPosition that tells the map to display the
// coordinate -33.86,151.20 at zoom level 6.
GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:-33.86 …Run Code Online (Sandbox Code Playgroud)