Can't include objective c file in carbon project
Can't include objective c file in carbon project
- Subject: Can't include objective c file in carbon project
- From: Kurt Spaker <email@hidden>
- Date: Tue, 28 Oct 2008 12:49:46 -0400
- Organization: Asar Corporation
Hello,
I'm trying to use NSCursor in a carbon project, based on the
CarbonCocoa_PictureCursor sample code. I can open and build the sample
project w/o any problems.
I added the Cocoa framework, NSCursorWrappers.m and .h to my project,
confirmed that all build settings were identical to the
CarbonCocoa_PictureCursor sample project, including the setting to compile
sources according to File Type, and changed my prefix file as follows:
#include <Carbon/Carbon.h>
#ifdef __OBJC__
#import <Cocoa/Cocoa.h>
#else
All other contents of my prefix file, including C++ headers that I don't want
included for ObjC files
#endif
Yet NSCursorWrappers.m is being compiled as C++ and generating 1000s of
errors. From the preprocessor:
NSCursorWrappers.o ../NSCursorWrappers.m normal i386 c++
com.apple.compilers.gcc.4_0
Any idea why XCode is compiling this as c++?
Kurt
_______________________________________________
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