I use xcode4, on a openglES project
i have added code for in-app purchase from the tutorial:
http://www.raywenderlich.com/2797/introduction-to-in-app-purchases
i have added SystemConfiguration.framework but this errors occurs:
Ld /Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator/blatest.app/blatest normal i386
cd /Users/Eros/Desktop/blatestDB
setenv MACOSX_DEPLOYMENT_TARGET 10.6
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator -F/Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator -F/Users/Eros/Desktop/blatestDB -filelist /Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Intermediates/blatest.build/Debug-iphonesimulator/SLQTSOR.build/Objects-normal/i386/blatest.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -framework Foundation -framework UIKit -framework OpenGLES -framework QuartzCore -framework AVFoundation -framework AudioToolbox -framework CoreAudio -framework CoreGraphics -framework OpenAL -lz -framework MediaPlayer -framework AVFoundation -framework GameKit -framework StoreKit -o /Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator/blatest.app/blatest
Undefined symbols for architecture i386:
"_SCNetworkReachabilitySetCallback", referenced from:
-[Reachability startNotifier] in Reachability.o
"_SCNetworkReachabilityScheduleWithRunLoop", referenced from:
-[Reachability startNotifier] in Reachability.o
"_SCNetworkReachabilityUnscheduleFromRunLoop", referenced from:
-[Reachability stopNotifier] in Reachability.o
"_SCNetworkReachabilityGetFlags", referenced from:
-[Reachability currentReachabilityStatus] in Reachability.o
-[Reachability connectionRequired] in Reachability.o
"_SCNetworkReachabilityCreateWithName", referenced from:
+[Reachability reachabilityWithHostName:] in Reachability.o
"_SCNetworkReachabilityCreateWithAddress", referenced from:
+[Reachability reachabilityWithAddress:] in Reachability.o
ld: symbol(s) not found for architecture i386
collect2: ld returned 1 exit status
if i delete framework reference the error is the same.
adding again nothing happens...
in -Xlinker 2 -framework Foundation -framework UIKit [...] should i see "-framework SystemConfiguration" right?
why is not there?
do anyone has ideas?
pulling up the framework from the project->build phases->link binary with library making it the first framework i have this erros:
Ld /Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator/blatest.app/blatest normal i386
cd /Users/Eros/Desktop/blatestDB
setenv MACOSX_DEPLOYMENT_TARGET 10.6
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/gcc-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator -F/Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator -F/Users/Eros/Desktop/blatestDB -filelist /Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Intermediates/blatest.build/Debug-iphonesimulator/SLQTSOR.build/Objects-normal/i386/blatest.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -framework SystemConfiguration -framework Foundation -framework UIKit -framework OpenGLES -framework QuartzCore -framework AVFoundation -framework AudioToolbox -framework CoreAudio -framework CoreGraphics -framework OpenAL -lz -framework MediaPlayer -framework AVFoundation -framework GameKit -framework StoreKit -o /Users/Eros/Library/Developer/Xcode/DerivedData/blatest-acmdklrqungznggpjewgxuxqsvwo/Build/Products/Debug-iphonesimulator/blatest.app/blatest
ld: warning: ignoring file /Users/Eros/Desktop/blatestDB/SystemConfiguration.framework/SystemConfiguration, missing required architecture i386 in file
Undefined symbols for architecture i386:
"_SCNetworkReachabilitySetCallback", referenced from:
-[Reachability startNotifier] in Reachability.o
"_SCNetworkReachabilityScheduleWithRunLoop", referenced from:
-[Reachability startNotifier] in Reachability.o
"_SCNetworkReachabilityUnscheduleFromRunLoop", referenced from:
-[Reachability stopNotifier] in Reachability.o
"_SCNetworkReachabilityGetFlags", referenced from:
-[Reachability currentReachabilityStatus] in Reachability.o
-[Reachability connectionRequired] in Reachability.o
"_SCNetworkReachabilityCreateWithName", referenced from:
+[Reachability reachabilityWithHostName:] in Reachability.o
"_SCNetworkReachabilityCreateWithAddress", referenced from:
+[Reachability reachabilityWithAddress:] in Reachability.o
ld: symbol(s) not found for architecture i386
collect2: ld returned 1 exit status
SystemConfiguration is there, the error still there...
what can it be?
thanks
found it!
i have copied the SystemConfiguration.framework into my project folder (checking the box when i added from xcode).
deleting that folder in my project now compiles well
After adding SystemConfiguration.framework from build phases my project compiles well...
have a fun...!
I had also the same problem. I added some frameworks directly with dragging and dropping them.
To resolve it, I deleted all of them and added them through the menu Target>Build Phases and then again added all needed frameworks through Link Binary With Libraries.
After this, your code should be working fine again.
it's simple.
scnetworkreachability callback is labeled as undefined symbol which implies some library or framework file is missing
the prefix sc means system configuration
click on the project name choose Summary on right side
click link binaries and frameworks
click plus on it then you can see a drill down with collections of frameworks and libaries see if there is anything called
systemConfigurationframework
select that and press ok
Now build and run the problem is solved
When i was using AFNetworking, after getting these errors imported 3 frameworks
CFNetwork.framework
Security.framework
SystemConfiguration.framework
All errors will gone.. enjoy !!!
As mentioned above, after importing the following 3 frameworks, it works!
CFNetwork.framework
Security.framework
SystemConfiguration.framework
Thanks a lot!
I would like to point out I also got a problem simular to this.
I copied some files over to xcode and accidently had "ProjectTests" selected instead of the project. Just delete the files and re-add them to your project making sure the main project ( not the unit tests) is selected
I had the same problem after an update from repo.
The solution that worked for me was to delete references from project for all classes and add them again. The problem is that there is a big possibility to mess up the repo synchronization.
Related
I am having trouble building my iOS app since probably last Thursday, February 12. I use DCIntrospect as an imported library using CocoaPods, and when I build the app (Standard Architectures + armv7s) the build fails over a DEBUGGER instruction in DCIntrospect, giving me the error message
Instruction requires: Not 64-bit mode
I reverted my changes to a stable build to make sure it wasn't an issue with the code, and I still get the same build failures. Has anyone else experienced this issue within the past week or so?
Edit:
I've since been able to get around the failure with DCIntrospect, but I'm now receiving linker errors due to the KIF library:
Ld /Users/mcampo/Library/Developer/Xcode/DerivedData/beam-ehqrhnpimyxzdkgifcnxicyobbgo/Build/Products/Debug-iphonesimulator/beamTests.octest/beamTests normal x86_64
cd "/Users/mcampo/Documents/Web Apps/beam"
export IPHONEOS_DEPLOYMENT_TARGET=7.0
export 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 x86_64 -bundle -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.1.sdk -L/Users/mcampo/Library/Developer/Xcode/DerivedData/beam-ehqrhnpimyxzdkgifcnxicyobbgo/Build/Products/Debug-iphonesimulator -L/Users/mcampo/Documents/Web\ Apps/beam/Pods/build/Debug-iphoneos -F/Users/mcampo/Library/Developer/Xcode/DerivedData/beam-ehqrhnpimyxzdkgifcnxicyobbgo/Build/Products/Debug-iphonesimulator -F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator8.1.sdk/Developer/Library/Frameworks -F/Applications/Xcode.app/Contents/Developer/Library/Frameworks -F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Library/Frameworks -filelist /Users/mcampo/Library/Developer/Xcode/DerivedData/beam-ehqrhnpimyxzdkgifcnxicyobbgo/Build/Intermediates/beam.build/Debug-iphonesimulator/beamTests.build/Objects-normal/x86_64/beamTests.LinkFileList -bundle_loader /Users/mcampo/Library/Developer/Xcode/DerivedData/beam-ehqrhnpimyxzdkgifcnxicyobbgo/Build/Products/Debug-iphonesimulator/beam.app/beam -Xlinker -objc_abi_version -Xlinker 2 -ObjC -lPods-beamTests-AFNetworking -lPods-beamTests-DCIntrospect-ARC -lPods-beamTests-Expecta -lPods-beamTests-KIF -lPods-beamTests-KIFViewControllerActions -lPods-beamTests-Kiwi -lPods-beamTests-OCMock -lPods-beamTests-RKKiwiMatchers -lPods-beamTests-RestKit -lPods-beamTests-SOCKit -lPods-beamTests-TransitionKit -framework CFNetwork -framework CoreData -framework CoreGraphics -framework Foundation -framework MobileCoreServices -framework QuartzCore -framework Security -framework SenTestingKit -framework SystemConfiguration -framework XCTest -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=7.0 -lPods-beamTests-KIF -lPods-beamTests-KIFViewControllerActions -framework SenTestingKit -framework UIKit -framework Foundation -lPods-beamTests -Xlinker -dependency_info -Xlinker /Users/mcampo/Library/Developer/Xcode/DerivedData/beam-ehqrhnpimyxzdkgifcnxicyobbgo/Build/Intermediates/beam.build/Debug-iphonesimulator/beamTests.build/Objects-normal/x86_64/beamTests_dependency_info.dat -o /Users/mcampo/Library/Developer/Xcode/DerivedData/beam-ehqrhnpimyxzdkgifcnxicyobbgo/Build/Products/Debug-iphonesimulator/beamTests.octest/beamTests
ld: warning: directory not found for option '-L/Users/mcampo/Documents/Web Apps/beam/Pods/build/Debug-iphoneos'
Undefined symbols for architecture x86_64:
"_OBJC_IVAR_$_UITouch._locationInWindow", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
-[UITouch(KIFAdditions) setLocationInWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
"_OBJC_IVAR_$_UITouch._phase", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
-[UITouch(KIFAdditions) setPhase:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
"_OBJC_IVAR_$_UITouch._previousLocationInWindow", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
-[UITouch(KIFAdditions) setLocationInWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
"_OBJC_IVAR_$_UITouch._tapCount", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
"_OBJC_IVAR_$_UITouch._timestamp", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
-[UITouch(KIFAdditions) setPhase:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
-[UITouch(KIFAdditions) setLocationInWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
"_OBJC_IVAR_$_UITouch._touchFlags", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
"_OBJC_IVAR_$_UITouch._view", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
"_OBJC_IVAR_$_UITouch._window", referenced from:
-[UITouch(KIFAdditions) initAtPoint:inWindow:] in libPods-beamTests-KIF.a(UITouch-KIFAdditions.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Please note: these issues were not occurring until February 12, and the build was stable until then. Rolling back did nothing to fix this error.
Trying to add Google Mobile Ad SDK to a project and looks like i'm missing a frame work. I've added the AVfoundation frame work to the project but still triggering these.
Ld /Users/kevzettler/Library/Developer/Xcode/DerivedData/ForgeInspector-hatfxtfbvtjkzgalvydfjjdmgdvi/Build/Products/Debug-iphonesimulator/ForgeInspector.app/ForgeInspector normal i386
cd /Users/kevzettler/checkiday/forge-admob/inspector/ios-inspector
setenv IPHONEOS_DEPLOYMENT_TARGET 5.0.1
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/iPhoneSimulator7.0.sdk -L/Users/kevzettler/Library/Developer/Xcode/DerivedData/ForgeInspector-hatfxtfbvtjkzgalvydfjjdmgdvi/Build/Products/Debug-iphonesimulator -F/Users/kevzettler/Library/Developer/Xcode/DerivedData/ForgeInspector-hatfxtfbvtjkzgalvydfjjdmgdvi/Build/Products/Debug-iphonesimulator -F/Users/kevzettler/checkiday/forge-admob/inspector/ios-inspector -filelist /Users/kevzettler/Library/Developer/Xcode/DerivedData/ForgeInspector-hatfxtfbvtjkzgalvydfjjdmgdvi/Build/Intermediates/ForgeInspector.build/Debug-iphonesimulator/ForgeInspector.build/Objects-normal/i386/ForgeInspector.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -ObjC -all_load -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=5.0.1 /Users/kevzettler/Library/Developer/Xcode/DerivedData/ForgeInspector-hatfxtfbvtjkzgalvydfjjdmgdvi/Build/Products/Debug-iphonesimulator/libForgeModule.a -framework SystemConfiguration -framework AssetsLibrary -framework UIKit -framework Foundation -framework CoreGraphics -framework ForgeCore -Xlinker -dependency_info -Xlinker /Users/kevzettler/Library/Developer/Xcode/DerivedData/ForgeInspector-hatfxtfbvtjkzgalvydfjjdmgdvi/Build/Intermediates/ForgeInspector.build/Debug-iphonesimulator/ForgeInspector.build/Objects-normal/i386/ForgeInspector_dependency_info.dat -o /Users/kevzettler/Library/Developer/Xcode/DerivedData/ForgeInspector-hatfxtfbvtjkzgalvydfjjdmgdvi/Build/Products/Debug-iphonesimulator/ForgeInspector.app/ForgeInspector
Undefined symbols for architecture i386:
"_AVAudioSessionPortBuiltInSpeaker", referenced from:
-[GADDevice audioRouteUsingAVAudioSession] in libForgeModule.a(GADDevice.o)
"_AVAudioSessionPortHeadphones", referenced from:
-[GADDevice audioRouteUsingAVAudioSession] in libForgeModule.a(GADDevice.o)
"_AudioServicesPlaySystemSound", referenced from:
-[GADDefaultGMSGHandler didReceiveVibrateNotification:] in libForgeModule.a(GADDefaultGMSGHandler.o)
"_AudioSessionGetProperty", referenced from:
-[GADDevice audioRouteUsingAudioToolkit] in libForgeModule.a(GADDevice.o)
"_AudioSessionInitialize", referenced from:
-[GADDevice audioRouteUsingAudioToolkit] in libForgeModule.a(GADDevice.o)
"_OBJC_CLASS_$_ASIdentifierManager", referenced from:
objc-class-ref in libForgeModule.a(GADDevice.o)
"_OBJC_CLASS_$_AVAudioSession", referenced from:
objc-class-ref in libForgeModule.a(GADDevice.o)
"_OBJC_CLASS_$_MFMailComposeViewController", referenced from:
objc-class-ref in libForgeModule.a(GADOpener.o)
"_OBJC_CLASS_$_MFMessageComposeViewController", referenced from:
objc-class-ref in libForgeModule.a(GADOpener.o)
"_OBJC_CLASS_$_SKStoreProductViewController", referenced from:
objc-class-ref in libForgeModule.a(GADOpener.o)
"_SKStoreProductParameterITunesItemIdentifier", referenced from:
-[GADOpener openInAppStore:fallbackURLString:] in libForgeModule.a(GADOpener.o)
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
frameworks in build phase:
You need the AudioToolbox framework for those remaining AVAudioSession... and AudioSession... symbols.
You also need the StoreKit and MessageUI frameworks for the other symbols.
Ok looks like the problem was that I am building a module for trigger.io and it has nested xcode projects. I was adding the frameworks to a child project when the parent project was what actually needed them.
I know this type of error has been raised many times before, but I have not found solution of my error. I am using xcode 4.0. I downloaded ASIHTTPRequest zip and copied classes folder along with two files of 'Reachability". After compilation, it is giving me strange errors which I can't figure out. Below I copied text of error for undefined symbols for architecture i386.
Ld /Users/svp/Library/Developer/Xcode/DerivedData/Manual_BeforePres2-fahkeiivemkgpubswgvzglvndszw/Build/Products/Debug-iphonesimulator/Manual.app/Manual normal i386
cd "/Users/svp/Desktop/Manual nav before pres 2"
setenv MACOSX_DEPLOYMENT_TARGET 10.6
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-gcc-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/svp/Library/Developer/Xcode/DerivedData/Manual_BeforePres2-fahkeiivemkgpubswgvzglvndszw/Build/Products/Debug-iphonesimulator -F/Users/svp/Library/Developer/Xcode/DerivedData/Manual_BeforePres2-fahkeiivemkgpubswgvzglvndszw/Build/Products/Debug-iphonesimulator -filelist /Users/svp/Library/Developer/Xcode/DerivedData/Manual_BeforePres2-fahkeiivemkgpubswgvzglvndszw/Build/Intermediates/Manual_BeforePres2.build/Debug-iphonesimulator/Manual.build/Objects-normal/i386/Manual.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -lz -framework SystemConfiguration -framework CFNetwork -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/svp/Library/Developer/Xcode/DerivedData/Manual_BeforePres2-fahkeiivemkgpubswgvzglvndszw/Build/Products/Debug-iphonesimulator/Manual.app/Manual
Undefined symbols for architecture i386:
"_UTTypeCreatePreferredIdentifierForTag", referenced from:
+[ASIHTTPRequest mimeTypeForFileAtPath:] in ASIHTTPRequest.o
"_UTTypeCopyPreferredTagWithClass", referenced from:
+[ASIHTTPRequest mimeTypeForFileAtPath:] in ASIHTTPRequest.o
"_kUTTagClassFilenameExtension", referenced from:
+[ASIHTTPRequest mimeTypeForFileAtPath:] in ASIHTTPRequest.o
"_kUTTagClassMIMEType", referenced from:
+[ASIHTTPRequest mimeTypeForFileAtPath:] in ASIHTTPRequest.o
ld: symbol(s) not found for architecture i386
collect2: ld returned 1 exit status
Also it is giving me a warning in ASIAuthenticationDialog.m file:
ASIAuthenticationDialog may not respond to _presentingViewController
Please anyone tell me what are these errors and warning for? What am I doing wrong? I have wasted many hours over it :(
EDIT:
Code for warning in ASIAuthenticationDialog.m file:
#import "ASIAuthenticationDialog.h"
#import "ASIHTTPRequest.h"
#pragma mark show / dismiss
+ (void)dismiss
{
if ([sharedDialog respondsToSelector:#selector(presentingViewController)])
[[sharedDialog presentingViewController] dismissModalViewControllerAnimated:YES];
else
[[sharedDialog parentViewController] dismissModalViewControllerAnimated:YES];
}
If you were to look up the missing symbols in the documentation, you would find them listed along with the framework where they are located. For example, UTTypeCreatePreferredIdentifierForTag says it is located in the MobileCoreServices.framework. (The others may be there too; I didn't look for all of them.) Add the necessary framework(s) to the link library step of your target's build phases and the symbols should be resolved.
As for the warning, please show the code where it's happening.
Hi I have been having this problem for a very long time and its driving me insane.
Ld /Users/soc/Library/Developer/Xcode/DerivedData/friendSpotted-dohwbjpnqfiztkcphlehsjqjusjk/Build/Products/Debug-iphonesimulator/friendSpotted.app/friendSpotted normal i386
cd /Users/soc/Desktop/friendSpotted
setenv MACOSX_DEPLOYMENT_TARGET 10.6
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/clang -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -L/Users/soc/Library/Developer/Xcode/DerivedData/friendSpotted-dohwbjpnqfiztkcphlehsjqjusjk/Build/Products/Debug-iphonesimulator -F/Users/soc/Library/Developer/Xcode/DerivedData/friendSpotted-dohwbjpnqfiztkcphlehsjqjusjk/Build/Products/Debug-iphonesimulator -filelist /Users/soc/Library/Developer/Xcode/DerivedData/friendSpotted-dohwbjpnqfiztkcphlehsjqjusjk/Build/Intermediates/friendSpotted.build/Debug-iphonesimulator/friendSpotted.build/Objects-normal/i386/friendSpotted.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -Xlinker -no_implicit_dylibs -D__IPHONE_OS_VERSION_MIN_REQUIRED=50000 -framework MobileCoreServices -framework UIKit -framework Foundation -framework CoreGraphics -o /Users/soc/Library/Developer/Xcode/DerivedData/friendSpotted-dohwbjpnqfiztkcphlehsjqjusjk/Build/Products/Debug-iphonesimulator/friendSpotted.app/friendSpotted
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_ViewController", referenced from:
objc-class-ref in AppDelegate.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
This has literally put me at a dead end, and I have tried some solutions on this site to no avail. I have checked the viewController.m to see if it was targeting the right project which it was, and as far as I can see I have all the right frameworks added. See below:
http://imgur.com/AeLny
Please I really do need help with this, I will greatly appreciate it.
I am using CLLocationManager.
I got this compile error:
Ld /Users/Teguh/Library/Developer/Xcode/DerivedData/BadgerNew-bjopcgcgsjkcvcevflfbvsjwfgnu/Build/Products/Debug-iphonesimulator/BadgerNew.app/BadgerNew normal i386
cd /Users/Teguh/Dropbox/badgers/BadgerNew
setenv MACOSX_DEPLOYMENT_TARGET 10.6
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/llvm-g++-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk -L/Users/Teguh/Library/Developer/Xcode/DerivedData/BadgerNew-bjopcgcgsjkcvcevflfbvsjwfgnu/Build/Products/Debug-iphonesimulator -F/Users/Teguh/Library/Developer/Xcode/DerivedData/BadgerNew-bjopcgcgsjkcvcevflfbvsjwfgnu/Build/Products/Debug-iphonesimulator -filelist /Users/Teguh/Library/Developer/Xcode/DerivedData/BadgerNew-bjopcgcgsjkcvcevflfbvsjwfgnu/Build/Intermediates/BadgerNew.build/Debug-iphonesimulator/BadgerNew.build/Objects-normal/i386/BadgerNew.LinkFileList -mmacosx-version-min=10.6 -Xlinker -objc_abi_version -Xlinker 2 -framework UIKit -framework Foundation -framework CoreGraphics -framework CoreData -o /Users/Teguh/Library/Developer/Xcode/DerivedData/BadgerNew-bjopcgcgsjkcvcevflfbvsjwfgnu/Build/Products/Debug-iphonesimulator/BadgerNew.app/BadgerNew
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_CLLocationManager", referenced from:
objc-class-ref in UtilitiesQuick.o
"_kCLLocationAccuracyBest", referenced from:
-[BNUtilitiesQuick init] in UtilitiesQuick.o
ld: symbol(s) not found for architecture i386
collect2: ld returned 1 exit status
So how am I supposed to program CLLocationmanager? I mean does that mean location manager is not available on iMac?
You need to add CoreLocation.framework to your project.
I got the same issue.. after a long struggle I found the issue..
I resolved it this way..
Go to Build Settings
Search for 'framework search path'
And delete the pre filled path.
Now it works perfectly.. I have given the answer in this question.. hope it helps some one..