You must use either CoreFoundation (C) or Foundation (ObjC). Access to any objects in the application bundle ("Basic Kit") is carried out using the CFBundle / NSBundle .
In CoreFoundation you do (NULL-check omitted):
CFURLRef manifest_url = CFBundleCopyResourceURL(CFBundleGetMainBundle(), CFSTR("manifest"), CFSTR("xml"), NULL); char manifest_path[1024]; CFURLGetFileSystemRepresentation(manifest_url, true, manifest_path, sizeof(manifest_path)); CFRelease(manifest_url); FILE* f = fopen(manifest_path, "r");
At foundation you do
NSString* manifest_string = [[NSBundle mainBundle] pathForResource:@"manifest" ofType:@"xml"]; const char* manifest_path = [manifest_string fileSystemRepresentation]; FILE* f = fopen(manifest_path, "r");
source share