views:

35

answers:

1

I'm building a framework, which aims to provide a new development environment for the user, but I need to use things like RegexKit and almost certainly some other established frameworks in order to do this. Any functionality exposed from such frameworks would be abstracted through classes and methods in my own framework for maintenance reasons (allowing me to change my mind on which dependencies I want).

In an ideal world I just want to ship a single .framework. However I'm aware that unlike with standard bundles and applications it is not possibile to embed a framework inside the framework bundle. Do I have any other option other than to tell the end user that they must also install RegexKit and any other dependencies? I have a feeling this lessens the appeal value of the easy to use embedded framework I'd envisaged building.

Right now I'm feeling like I have some limited options:

  1. Force the user to install the dependencies.
  2. Write my own classes that provide the same functionality -- ugh!
  3. If at all possible, try to statically link the third party frameworks (is this possible??)

My end-product is ideally a single .framework bundle that uses @rpath and so can be installed in the system or simply bundled with the app that uses it.

A: 

Sorry to answer my own question, but a loadable bundle is definitely what I want if I want encapsulate the dependencies without the user ever having to even concern themselves with their existence.

I'm actually considering just making my whole framework a loadable bundle instead of a framework since on first impressions it appears you can achieve more or less them same thing, just that the way the code is loaded into memory differs. Either that or just have two files: the framework and a bundle it requires in order to run.

EDIT | If anybody has a better answer to the original question I'll keep this question unanswered for a while.

d11wtq
Apple heavily discourages it, but you could create an umbrella framework.
JeremyP
My understanding of umbrella frameworks is that the frameworks they aggregate live elsewhere (such is in the filesystem, or copied into the application bundle). This is what I'm trying to avoid. Myabe I've misunderstand what an umbrella framework is. I got the impression that, for example, Cocoa is just #import <Foundation/Foundation.h> #import <AppKit/AppKit.h> #import <CoreData/CoreData.h> and nothing in particular in the binary. The code all lives in the respective frameworks.
d11wtq