I've created a framework in which is inserted the second framework, the so-called "umbrella framework". When I insert the framework in the test application(embedded binaries and linked frameworks and libraries, both) can not build app, I get the following error:
ld: framework not found 'embeddedInMyFramework' for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Than add that framework(embeddedInMyFramework) also in embedded binaries and linked frameworks and libraries and try to build than works ok. Later remove that framework from both, embedded binaries and linked frameworks and libraries and still works fine. Can someone help me with this, not sure what happens when I add framework to embedded binaries for the first time, and how to fix that (could it work somehow without adding to embedded binaries at all)
Swift is a multipurpose, multi-paradigm compiled language created by Apple Inc. It is used for macOS, iPadOS, iOS, watchOS, Linux, and tvOS. The team that developed it makes use of an open-source LLVM compiler framework.
A framework is a bundle (a structured directory) that contains a dynamic shared library along with associated resources, such as nib files, image files, and header files. When you develop an application, your project links to one or more frameworks.
In the app, select the project from the project navigator, select the Stocktance target, and scroll to Frameworks, Libraries, and Embedded Content. Click on the plus button, click Add Other… and select Add Files… Navigate to the SettingsKit folder and select it. We've added the framework to the project.
I was able to set up a working Umbrella Framework and wrote down my approach.
Step 5 should remove your linker error ld: framework not found ..
A Swift based "client" project that has the Umbrella Framework as dependency
A dynamic Framework (mainly C++ and ObjC) that is a dependency of the Umbrella Framework
2. Add the location of the dependent (sub-)framework to the Framework Search Paths
of the Umbrella Framework project.
3. In the "client" project make sure to link and embed the Umbrella Framework
4. Make sure the Umbrella Framework is copied into the (client-) app bundle to avoid dyld: Library not loaded: @rpath/...
errors.
The (client-) app, usually under ...Build/Products/Debug-iphoneos/YOUR_CLIENT_APP.app
should now contain your Umbrella Framework in a folder called Frameworks
.
5. In the "client" project Make sure to add the path to the Umbrella Framework to Framework Search Paths
.
If the ld: framework not found '[Framework_Name]' for
architecture ...
error persists you can also add the path to the (sub-) Framework here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With