Forums > Dev

third party framework deployment

Apr 09 2010 | 2:00 pm


I have some troubles in deploying a Jitter external using the dc1394 framework
I’ve got the error :
av.jit.iidc: unable to load object bundle executable
2010-04-09 15:54:56.735 av.jit.iidc-app[379:20b] Error loading /private/var/folders/zz/zzzivhrRnAmviuee++4K-U+-ZUM/TemporaryItems/appRuntime-mxt/av.jit.iidc.mxo/Contents/MacOS/av.jit.iidc: dlopen(/private/var/folders/zz/zzzivhrRnAmviuee++4K-U+-ZUM/Tempor
aryItems/appRuntime-mxt/av.jit.iidc.mxo/Contents/MacOS/av.jit.iidc, 262): Library not loaded: @executable_path/../Frameworks/dc1394.framework/Versions/A/dc1394
Referenced from: /private/var/folders/zz/zzzivhrRnAmviuee++4K-U+-ZUM/TemporaryItems/appRuntime-mxt/av.jit.iidc.mxo/Contents/MacOS/av.jit.iidc
Reason: image not found

It looks like a Xcode configuration problem but I can’t find out a solution with google so I post it here…
I think I have to include the framework in the MachO bundle and to link it with the external but I don’t know how…
Could someone help me ?



Apr 09 2010 | 7:02 pm

There are a variety of approaches:

1. If you have the source, the easiest solution may to simply include it all in your project and avoid any linking issues.

2. If you configure your project correctly, you can automatically link to it in one of the standard frameworks folders or inside the application bundle. Personally I’m not aware of whether or not it is possible to set it up to automatically find inside your own object bundle:

3. You can load from somewhere in the search path (or explicitly from a known location like in your object’s bundle) with a dynamic loading and linking strategy like the following, which we do for the Cg framework:

void jit_gl_shader_framework_init_cg(void)

OSStatus err;
short path;
char name[MAX_PATH_CHARS];
long type=0;

g_jit_gl_shader_cg_framework_ok = FALSE;
if (!locatefile_extended(name,&path,&type,0L,0))
char outname[MAX_PATH_CHARS];
char natname[MAX_PATH_CHARS];

if (!path_topathname(path, name, outname))
CFStringRef str;
CFURLRef url;

path_nameconform(outname, natname, PATH_STYLE_NATIVE, PATH_TYPE_PATH);
str = CFStringCreateWithCString(kCFAllocatorDefault, natname, kCFStringEncodingUTF8);
if (url = CFURLCreateWithFileSystemPath(kCFAllocatorDefault, str, kCFURLPOSIXPathStyle, true))
// we need to get rid of this in a quitmethodthingy
if (g_cg_bundle_ref = CFBundleCreate(kCFAllocatorDefault, url))
// jit_object_post((t_object *)x," loaded CG framework.");

// include the bundle binding operations
#include ""
The above file explicitly loads each function to a typed function pointer like the following:
pf_cgCreateContext = CFBundleGetFunctionPointerForName(g_cg_bundle_ref, CFSTR("cgCreateContext"));
if(!pf_cgCreateContext) {
error(" unable to load CG framework function 'cgCreateContext'");

// toggle global flag
g_jit_gl_shader_cg_framework_ok = TRUE;
error(" error loading CG framework : no URL from FSRef.");
error(" unable to find CG framework.");

So to summarize, you’ll want to either: include the source, use an installer to put in standard frameworks location, or manually load and link to every function you want to use.

Good luck.

Apr 13 2010 | 9:05 am

hi Joshua,

thanks for your reply

actually, I’m including the sources into my Xcode project
it compiles and i can run the external on my laptop (the one with which I compiled the external)
but when I try to load the external on another machine I always got some errors.

I look into the bundle architecture and i saw that the framework wasn’t in there.

So i’m trying to configure Xcode in the right way…

Thanks again



Viewing 3 posts - 1 through 3 (of 3 total)

Forums > Dev