 |
 |
Frameworks Target...
|
 |
|
 |
|
Grizzled Veteran
Join Date: Jun 2002
Status:
Offline
|
|
I need to add a framework to my app.
I looked in PB help and found this.
Prepare the Framework to be Embedded
In the Framework's target, you must make some changes to ensure it's properly built for embedding.
1. In the project window, click the Targets tab and open the framework target.
2. In the Settings > Simple View > Installation Settings section, select Path and enter @executable_path/../Frameworks
This causes Project Builder to build the framework so you can embed it in an application bundle.
3. In the Settings > Expert View section, click the plus sign button, type SKIP_INSTALL, press tab, and type YES.
Now Project Builder won't place the framework at the location you just entered in the Install Path field. Instead, the copy-files build phase that you added to the application target will copy the framework into the application.
Copy the Framework Into the Application
In the application's target, you need to add a copy-files build phase that copies the framework into the application
1. Add the framework to the application's target. See "Adding Files and Frameworks".
If the application's target and framework's target are in the same project, you should also make the application's target dependent on the framework's target. See "Managing Target Dependencies".
2. In the project window, click the Targets tab and open the application target.
3. Click the last build phase under Build Phases, and choose Project > New Build Phase > New Copy Files Build Phase.
4. Choose Frameworks from the Where menu, select the "Copy only when installing" option, and drag the framework to the Files field.
You can find the framework in the Products group in the project's file list.
Where it says:
1. In the project window, click the Targets tab and open the framework target.
I need to find the frameworks target, I go into the active target of my app, but I see no frameworks target, please help.
|
|
|
| |
|
|
|
 |
|
 |
|
Addicted to MacNN
Join Date: Mar 2000
Location: London, UK
Status:
Offline
|
|
You first need to ADD a framework target -- the instructions below assume you already have one. Switch to the targets list, then go Project->New Target...
|
|
|
| |
|
|
|
 |
|
 |
|
Grizzled Veteran
Join Date: Jun 2002
Status:
Offline
|
|
I keep getting an error when I build the app:
Maintain Your Mac has exited due to signal 10 (SIGBUS).
This is what is in the crash log:
Date/Time: 2003-02-21 17:10:32 +0000
OS Version: 10.2.4 (Build 6I32)
Host: Oliver-Camerons-Computer.local.
Command: Maintain Your Mac
PID: 896
Exception: EXC_BAD_ACCESS (0x0001)
Codes: KERN_PROTECTION_FAILURE (0x0002) at 0x00000006
Thread 0 Crashed:
#0 0x90132004 in CFRelease
#1 0x90810268 in _decodeObjectBinary
#2 0x9083cb0c in -[NSKeyedUnarchiver _decodeArrayOfObjectsForKey:]
#3 0x907fcac8 in -[NSArray initWithCoder:]
#4 0x908103ec in _decodeObjectBinary
#5 0x908185d4 in _decodeObject
#6 0x930ad1a4 in -[NSView initWithCoder:]
#7 0x908103ec in _decodeObjectBinary
#8 0x908185d4 in _decodeObject
#9 0x931300fc in -[NSWindowTemplate initWithCoder:]
#10 0x908103ec in _decodeObjectBinary
#11 0x9083cb0c in -[NSKeyedUnarchiver _decodeArrayOfObjectsForKey:]
#12 0x90819218 in -[NSSet initWithCoder:]
#13 0x908103ec in _decodeObjectBinary
#14 0x908185d4 in _decodeObject
#15 0x931491a4 in -[NSIBObjectData initWithCoder:]
#16 0x908103ec in _decodeObjectBinary
#17 0x908185d4 in _decodeObject
#18 0x931b2c9c in loadNib
#19 0x930e9de0 in +[NSBundle(NSNibLoading) _loadNibFile:nameTable:withZone:ownerBundle:]
#20 0x93149098 in +[NSBundle(NSNibLoading) loadNibFile:externalNameTable:withZone:]
#21 0x93148e58 in +[NSBundle(NSNibLoading) loadNibNamed:owner:]
#22 0x9315f65c in NSApplicationMain
#23 0x00003d94 in main (main.m:8)
#24 0x00003b14 in _start (crt.c:267)
#25 0x00003994 in start
Thread 1:
#0 0x90073c48 in mach_msg_trap
#1 0x90005f90 in mach_msg
#2 0xc0007758 in __ape_internal
#3 0xc0001160 in __ape_agent
#4 0x90020d48 in _pthread_body
PPC Thread State:
srr0: 0x90132004 srr1: 0x0200f030 vrsave: 0x00000000
xer: 0x00000000 lr: 0x90131ff4 ctr: 0x90131fdc mq: 0x00000000
r0: 0x90810268 r1: 0xbfffe770 r2: 0x28000242 r3: 0x00000000
r4: 0x906ade3c r5: 0x00000000 r6: 0x00000077 r7: 0x73636c6f
r8: 0xa0131ff4 r9: 0xa0131ff4 r10: 0x00000000 r11: 0xa07e0c70
r12: 0x90131fdc r13: 0x00000000 r14: 0x00000000 r15: 0xa30990f8
r16: 0x0005a560 r17: 0xa3099b00 r18: 0xa30990f8 r19: 0xa3099b00
r20: 0xa07dfd2c r21: 0x0000001e r22: 0x00000000 r23: 0x001bde10
r24: 0x908d3664 r25: 0x00000000 r26: 0x00001278 r27: 0x001ae7b0
r28: 0x00000000 r29: 0x00000000 r30: 0x00000000 r31: 0x90131ff4
This is after adding the framework and following those instructions perfect.
|
|
|
| |
|
|
|
 |
 |
|
 |
|
|
|
|
|

|
|
 |
Forum Rules
|
 |
 |
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
 |
 |
 |
 |
|
 |