Re: Xcode not compiling a .c file?
Re: Xcode not compiling a .c file?
- Subject: Re: Xcode not compiling a .c file?
- From: Ben Kazez <email@hidden>
- Date: Wed, 9 Nov 2005 10:08:06 -0600
On Nov 9, 2005, at 9:08 AM, Prachi Gauriar wrote:
On Nov 9, 2005, at 9:06 AM, Ben Kazez wrote:
This question is so simple that I can't believe I still can't
figure it out. I'm compiling a framework in Xcode and I just added
a .h/.c file pair. I put the .h file in the "Copy Headers" build
phase and included it from the main framework include file, and
that's working. Then I put the .c file in the "Compile Sources"
build phase. Xcode just isn't compiling it -- I can put blatant
syntax errors in there and it doesn't complain about them.
I'd like to keep the project confidential, unfortunately, but
given this description, does anyone see my (probably outrageously
simple) mistake?
Did you actually add the file to your framework target? There's a
column of checkboxes indicating Target Membership in the detailed
file list. Make sure that when your framework target is selected,
your .c and .h files have checkboxes by them.
Thanks for the help. I made sure that box was checked, and then just
for fun I deleted the files from the project and re-added them,
making sure I checked the framework in the target membership list in
the sheet. I'm still getting a linker error (it saw my extern for the
NSString * const but couldn't find where it was defined). So it seems
like nothing has changed.
My .h file has this:
extern NSString * const BKSomeConstant;
My .c file has this:
NSString * const BKSomeConstant = @"BKSomeConstant";
And they're both members of the framework target. Any further ideas?
Ben
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden