I have a .app file. When I double click to open it, I get an error :
Dyld Error Message:
Library not loaded: /Library/Frameworks/CoreFactoryTestStation.framework/Versions/A/CoreFactoryTestStation
Referenced from: /Users/USER/Desktop/FixtureController.app/Contents/MacOS/FixtureController
Reason: image not found
I dont have the source code for the project, but I do have the missing framework CoreFactoryTestStation.framework with me. Where am I supposed to add this library. Should I need the source code of the project to fix this?
Go to folder /Library/Frameworks/ in finder and paste CoreFactoryTestStation.framework, run your app. That should resolve the loader error. If you dont find the Frameworks folder, do create one and paste your CoreFactoryTestStation.framework in that.
Go to Target > Build Phase > Link Binary With Libraries pane and add your framework there
Related
I have a Qt project and I need to include some libraries
I have this in my .pro file:
QT += webengine
I can build and run it fine on my Mac but if I try to send the .app to someone else and they run it, there is this error:
Dyld Error Message:
Library not loaded: #rpath/QtWebEngine.framework/Versions/5/QtWebEngine
Referenced from: /path/myApp.app/Contents/MacOS/myApp
Reason: image not found
I have the QtWebEngine.framework and its corresponding QtWebEngine.framework.dSYM file in my directory:
Users/myUsername/Qt/5.11.0/clang_64/lib
I also have the .framework in my directory:
Library/Frameworks
In the editor, I looked at Projects > Desktop Qt 5.11.0 clang 64bit2 > Run > Run Environment, and I found that the DYLD_FRAMEWORK_PATH points to where the .framework file is located. Same for DYLD_LIBRARY_PATH.
This is confusing me because it works on my Mac but not on others. It also seems like the paths are all in order. I have tried using other suggestions on this website but they do not seem to work for me or maybe I just did them wrong. Maybe someone could help me?
Update:
If I need to add the .pak resource files to my deployment, how can I do this?
I'm trying to build my first ARKit app with Xcode 9 beta for iOS 11.
When I build my application on Xcode, I get the following error
"Xcode 7 build failed due to ld: library not found for -liPhone-lib
error: linker command failed with exit code 1"
Any idea how to solve it?
I guess its Unity3D game. I also observed linker error for liPhone-lib.
Solution is simple, just drag liPhone-lib's parent folder to library search path.
Clean Build. Cheers
In my project, liPhone-lib placed in Libraries folder. So I just dragged Libraries folder to Xcode library search path...its solved my problem.
See attach image:
Looks like either Unity or Xcode incorrectly puts double quotes around the search path for the Libraries folder.
In Xcode, click your target and open Build Settings
Find Library Search Paths and remove all the escaped double quotes,
In the project's Library Search Paths, find the entry that looks like this:
\"$(SRCROOT)/Libraries\"
double click the entry to edit it and remove the escaped double quotes, so it looks like this:
$(SRCROOT)/Libraries
The project should now compile correctly again.
I am attempting to run my xcode project and I get this error:
dyld: Library not loaded: libosgd.130.dylib
Referenced from: /Users/raj/MyApp-Build-XCODE/bin/Debug/MyApp2.app/Contents/MacOS/Myapp2
Reason: image not found
My project .xcodeproj was created using CMake. I know where this library is present. How can I tell xcode to look for it in a specific path.I am fairly new to xcode 7.Here is what I tried.
I went into the build settings of the project.Expanded "Linking". Then expanded "RunPath Search Paths". Then inside the debug row underneath my project column added the path to the library such as
~/Mypaths/lib/
However I am stilling getting this error when I run project. Any suggestions ?
I faced this problem while I was using Alamofire library
The following step solved it for me:
I have an OSX app and I have added the ParseOSX sdk. I have followed all the instructions on the quick start page (https://www.parse.com/apps/quickstart#parse_data/desktop/osx/existing)
The app is running fine in Xcode (Version 5.1.1 (5B1008)) but when I archive and create a package and install this. I get the following Dyld error;
Dyld Error Message:
Library not loaded: #executable_path/../Frameworks/ParseOSX.framework/ParseOSX
Referenced from: /Applications/MyApp.app/Contents/MacOS/MyApp
Reason: image not found
It goes on and lists the Binary Images loaded.
Searching the web I found reference to adding a copy files build phase and adding the parse framework to that with the destination set to Products directory.
So it appears there is a dynamic lib not being installed somewhere.
UPDATE:
I just cleaned the build folder and now the app will not even run under Xcode. I get:
dyld: Library not loaded: #executable_path/../Frameworks/ParseOSX.framework/ParseOSX
Referenced from: /Users/Ants/Library/Developer/Xcode/DerivedData/MyApp-hjrbgyhzpwnxhiaskxpojqyqxnvh/Build/Products/Debug/Actual.app/Contents/MacOS/MyApp
Reason: image not found
UPDATE 2:
It turns out when you are in the quick start page. If you chose the new app option you get a Xcode project. This compiles. Going through it I can see that there is is a Copy Files step that copies the ParseOSX.framework into the Frameworks destination. Tried this is my app and I now get a signing error
/Users/Ants/Library/Developer/Xcode/DerivedData/MyApp-hjrbgyhzpwnxhiaskxpojqyqxnvh/Build/Products/Debug/MyApp.app: code object is not signed at all
In subcomponent: /Users/Ants/Library/Developer/Xcode/DerivedData/MyApp-hjrbgyhzpwnxhiaskxpojqyqxnvh/Build/Products/Debug/MyApp.app/Contents/Frameworks/ParseOSX.framework
I ran into the same problem with xcode 6.1. Fixed it by adding ParseOSX.framework to "Embedded Binaries" on the general tab of the Targets page.
Two things fixed this for me.
First I needed to add a copy files section to the build phases and copy the ParseOSX.framework into the Frameworks destination.
And second, I needed to add --deep to the "Other Code Signing Flags" in the Code Signing section of Build Settings. It now signs the frameworks being copied it seems.
I was updating an existing parse project to the newest SDK (1.12.0) using Xcode 7.2 and ran into the same problem.
The solution for me was to set Runpath Search Paths to #executable_path/../Frameworks.
I found this by comparing the Starter project from Parse to my project.
I have a Cocoa application as XCode project that has several supplementary bits of functionality as dylib targets.
When XCode builds the project, it places all the build outputs in a single folder: The .app bundle and the dylib files. And when executed from the XCode debugger, the .app launches.
I can't however launch the application from finder.
How do I setup XCode to 'deploy' the app in a standalone state? I have found that I can use ld on the actual app binary to contain a relative path to the dylibs: #executable_path/../../mylib.dylib
Running a script after each build seems wrong: there must be some way (that Im totally missing) to do this easily from inside XCode - it must be a common issue surely?
It looks like that XCode supports having #executable_path, #loader_path and #rpath used in the Target Info > Build > Linking > Dynamic Library Install Name setting (LD_DYLIB_INSTALL_NAME) setting.
The help text says: "Sets an internal "install path" (LC_ID_DYLIB) in a dynamic library. Any clients linked against the library will record that path as the way dyld should locate this library"
This seems very promising, but usability is a problem if I need to link dylibs in multiple paths against a common library - the relative path is going to be different each time.
Running my testapp from finder, I get the following (relevant) error text
Dyld Error Message:
Library not loaded: #executable_path/../../util.dylib
Referenced from: /Volumes/data/Code/TestApp/build/Debug/TestApp.app/Contents/MacOS/TestApp
Reason: image not found
util.dylib is in /Volumes/data/Code/TestApp/build/Debug/ so I am confused :/
You should use a Copy Files build phase to copy the dylib to the app's bundle when building the app. You'll want to copy it to Frameworks. You can then set the install path to #executable_path/../Frameworks/mylib.dylib.