dyld: Library not loaded: #rpath/Realm.framework/Realm error with Realm Objective C framework - objective-c

I have installed the Realm Objective C Framework (2.0.3) by simply dragging it into my project created in Xcode 8. When I first tried it on simulator I got the typical dyld error.
dyld: Library not loaded: #rpath/Realm.framework/Realm
Referenced from: /var/containers/Bundle/Application/89F5987A-F3F0-45F2-9014-6BA662135E00/RelamDemo.app/RelamDemo
Reason: image not found
So I tried to fix it using the following suggestion:
https://github.com/realm/realm-cocoa/issues/1681#issuecomment-120749962
And it worked on iOS 10 Simulators.
But when I tried to run the same project on a device (iOS 10/9.3.2) I got the same dyld error again.
I have checked that I have copied the Realm.framework in my project. Now how can I solve the problem?

You need to ensure that Realm.framework is also copied to the 'Embedded Binaries' section of your app as well.
You can find that section in the 'General' tab of your project's settings.
(Screenshot courtesy of this iOSDevCenter post)

Related

Dyld Message- Library not loaded - #rpath/libswiftAVFoundation.dylib in iOS

I added some Swift classes to my objective c project. then the project has no build errors but it crash immediately after running.
Dyld Message: Library not loaded: #rpath/libswiftAVFoundation.dylib
This is a common issue and I found some solutions, like cleaning project and cleaning drive data. but it didn't work.
Also I should mention that I have 2 targets. One with provision profile the other with developer profile. The one with provision profile crashes.
When I add the bridging header this crash happens when I remove it from target setting, app works but I cannot use Swift files.

Getting error on importing Sparkle Framwork for Xcode 5

I am downloaded Sparkle 1.5 from git hub. when i am copying it into my existing project it is giving following error.Can anybody tell me what is the reason of this
dyld: Library not loaded: #loader_path/../Frameworks/Sparkle.framework/Versions/A/Sparkle
Referenced from: /Users/SS/Library/Developer/Xcode/DerivedData/Capture_It-dswmsaclkiypqrbcnbaymxlwxxgo/Build/Products/Debug/Capture It.app/Contents/MacOS/Capture It
Reason: image not found

Add a third-party framework to a compiled app

I'm trying to add a third-party framework to my OS X app. It's a framework called MapKit, and it was specifically built for OS X. I added the framework to the "Copy Files" section of Xcode (see screenshot below). However, when I create an archive of my app and export it to my desktop, launching it causes a crash with the following error:
Application Specific Information:
dyld: launch, loading dependent libraries
Dyld Error Message:
Library not loaded: #loader_path/../Frameworks/MapKit.framework/Versions/A/MapKit
Referenced from: /Users/USER/Desktop/Example.app/Contents/MacOS/Example
Reason: image not found
Adding the framework to Xcode:
Am I not copying the framework correctly?
You're close, in Copy Files phase you've created, change Destination to Frameworks

dyld: Symbol not found: __NSConcreteGlobalBlock after updating to OSX 10.8

I just updated to Mac OSX10.8 and I'm trying to compile a Mac app that ran perfectly when using 10.7 + Xcode 4.5. Now I get this error:
dyld: Symbol not found: __NSConcreteGlobalBlock
Expected in: /System/Library/Frameworks/CoreServices.framework/Versions/A/CoreServices
I've looked everywhere and things seem to be ok. The deployment target for the app is 10.6 which already supports blocks. Any ideas?
Thanks!!
It turns out that my project was trying to use an old version of the CoreServices framework which was causing this issue. I re-added all the frameworks that my project was using and the problem was gone :)
+1 on your question... Not sure if that would help finding the problem with OS X, but there is a similar error that happens with iPhone apps, with a solution in the link below. Another reason I am providing this link is that googling this error for the iPhone got me to this page.
iOS 4 app crashes at startup on iOS 3.1.3: Symbol not found: __NSConcreteStackBlock

while i try to run in iOS 6 my code throws Sen test Framework error. why?

I have a project that is developed in iOS 5.0 and now i need to update my project to iOS 6.0 .
While doing this my xcode 4.5 throws the error as below...
dyld: Library not loaded: #rpath/SenTestingKit.framework/Versions/A/SenTestingKit
Referenced from: /Users/developer/Library/Application Support/iPhone Simulator/6.0/Applications/6EFF12B6-DA80-4DD8-B3CF-B217C5EA63DF/XxxxXxxx.app/xxxxXxxxXxx
Reason: image not found
still it runs and works perfectly in iOS 5 devices and i am trying to run this app in iphone Simulator iOS 6.0 it throws that error...
Any body have any idea about this...
Thanks in advance...
its working....set SentestingKit.framework as optional
#fry copied his answer from here:
http://www.cocoabuilder.com/archive/xcode/260066-sentesttingkit-framework-runtime-failure.html
There's more information there which I found useful in solving this problem.
Try to delete the derived Data, then clean the project and restart Xcode.
If its still not working, check the Target dependencies of your library.
It seams like it has Problems with the armv7s Architecture, check that in the
Buildsettings of your Framework!