Re: carbon Bluetooth
Re: carbon Bluetooth
- Subject: Re: carbon Bluetooth
- From: "Daniel Birns" <email@hidden>
- Date: Fri, 23 Mar 2007 11:28:45 -0700
After more research, I've discovered that the obex headers appear to actually be obj-c, but the rest of that directory's headers are all c++ and work fine. Unfortunately, they don't appear to address much functionality
On 3/23/07, Joseph Kelly <email@hidden> wrote:
That's horrible! I have no idea what the answer is, but have you
tried commenting out #import <Foundation/Foundation.h> in OBEX.h and
see what happens? Importing objective-C headers into a source file
that is clearly marked "Contains generic OBEX constants, structs, and
C API..." is flat out wrong, and this is probably a really dumb
oversight by Apple.
Joe K.
On Mar 23, 2007, at 9:40 AM, Daniel Birns wrote:
> All,
>
> We have a C++ app using carbon. We need to use Bluetooth. I've tried
> adding this framework to my app and to a simple test c program, and in
> both cases I get the following error:
>
> In file included from
> /System/Library/Frameworks/Foundation.framework/Headers/
> Foundation.h:12,
> from
> /System/Library/Frameworks/IOBluetooth.framework/Headers/OBEX.h:12,
> from dant2.c:1:
> /System/Library/Frameworks/Foundation.framework/Headers/
> NSObjCRuntime.h:60:
> error: stray '@' in program
> [...]
>
> It seems like the framework always include Obj-C headers, which cause
> the C compiler to choke.
>
> Here's my sample program:
> $ cat dant2.c
> #include <IOBluetooth/OBEX.h>
> main()
> {
> OBEXSessionHasOpenOBEXConnection();
> }
>
> Here's the command line I use:
> gcc -framework IOBluetooth
dant2.c
>
> I got the same error in XCode when I added the IOBluetooth Framework
> and included this header.
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Bluetooth-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden