0

First of all I can't use Cocoapods.

My framework uses SocketRocket, I have its .framework file.

It's fine if the client has to manually add both my framework and SocketRocket.framework, I don't want to use an umbrella framework.

The problem is my framework depends on SocketRocket, but

#import <SocketRocket/SocketRocket.h>

doesn't work.

My framework doesn't add SocketRocket to the "Link Binary With Libraries" phase, I just added SocketRocket.framework's path to "Framework Search Paths". I think that should be enough for it to find the headers and the symbols.

I haven't found a guide about creating a framework which depends on another framework, everybody seems to be using CocoaPods.

1 Answer 1

2

You should add SocketRocket.framework into your header search paths too. And if your library is using SocketRocket.framework, you should link your library against it. Otherwise, you'll get linker errors.

Also, you should embed SocketRocket.framework into your application target. If you don't, your app will crash when it tries to load SocketRocket.framework with "image not found" error.

You can embed SocketRocket.framework under your target's Build Phases -> "Embed Frameworks" phase. If you don't have that phase, you can create it "New Copy File Phase" button.

enter image description here

And then selecting "Frameworks" as destination:

enter image description here

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.