2012-03-12 205 views
2

我得到這個錯誤:Xcode鏈接器錯誤?

Undefined symbols for architecture i386: 
    "_OBJC_CLASS_$_GameCenterManager", referenced from: 
     objc-class-ref in BT_viewController.o 
ld: symbol(s) not found for architecture i386 
clang: error: linker command failed with exit code 1 (use -v to see invocation) 

我的信息:

Ld /Users/Raoul/Library/Developer/Xcode/DerivedData/latintogopro-fbrntyvxhakjwlfaxcckdbvsvcli/Build/Products/Debug-iphonesimulator/LatinToGo.app/LatinToGo normal i386 
cd /Users/Raoul/Downloads/latintogopro_v15_iOS 
setenv MACOSX_DEPLOYMENT_TARGET 10.6 
setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" 

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -L/Users/Raoul/Library/Developer/Xcode/DerivedData/latintogopro-fbrntyvxhakjwlfaxcckdbvsvcli/Build/Products/Debug-iphonesimulator -L/Users/Raoul/Downloads/latintogopro_v15_iOS/BT_Objects/TwitterOAuth/SAOAuthTwitterEngine -F/Users/Raoul/Library/Developer/Xcode/DerivedData/latintogopro-fbrntyvxhakjwlfaxcckdbvsvcli/Build/Products/Debug-iphonesimulator -F/Users/Raoul/Downloads/latintogopro_v15_iOS/BT_Objects -filelist /Users/Raoul/Library/Developer/Xcode/DerivedData/latintogopro-fbrntyvxhakjwlfaxcckdbvsvcli/Build/Intermediates/latintogopro.build/Debug-iphonesimulator/latintogopro.build/Objects-normal/i386/LatinToGo.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -Xlinker -no_implicit_dylibs -D__IPHONE_OS_VERSION_MIN_REQUIRED=50000 -framework Security -framework GameKit -lxml2.2 -framework CoreAudio -framework CoreLocation -framework Foundation -framework SystemConfiguration -weak_framework UIKit -framework MobileCoreServices -framework AVFoundation -weak_framework MessageUI -lOAuth -framework MapKit -weak_framework MediaPlayer -framework CoreGraphics -framework QuartzCore -weak_framework iAd -o /Users/Raoul/Library/Developer/Xcode/DerivedData/latintogopro-fbrntyvxhakjwlfaxcckdbvsvcli/Build/Products/Debug-iphonesimulator/LatinToGo.app/LatinToGo 
+0

有人可以幫我嗎? – Raoul 2012-03-12 01:49:54

+1

您可以在下次更清晰地設置問題的格式嗎? – matt 2012-03-12 01:51:45

回答

1

想必你的代碼是指稱爲GameCenterManager類,但你的項目沒有鏈接到定義它的框架。

如果這是一個內置框架,那麼鏈接到該框架:編輯目標,在Summary中向下滾動到鏈接的框架,按加號按鈕添加框架。

如果這是第三方框架,他們應該提供鏈接到他們的框架的指示。

2

轉到您的項目,單擊生成階段,編譯源代碼,將GameCenterManager.m添加到列表中。

希望這會有所幫助:)