[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Re: [bluetooth-dev] newbie question, compile problems



thanks peter

I changed __u16 and __u32 to u16 and u32 in local.h but unfortunately the
result is still the same. I get the same errors while compiling for uClinux
(m68k-elf-gcc -m68000 -Wl, -elf2flt -o test test.c -lc).

In file included from
 /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
 /btcommon.h:57
 ,
                  from test.c:1:
 /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
 /local.h:74:
 parse error before `cpu_to_le16'
 /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
 /local.h:74:
 parse error before `x'
 /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
 /local.h: In
 function `cpu_to_le16':
 /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
 /local.h:74:
....

I attached my changed local.h file but there wasn't much to do wrong. :-)

I'm not sure what you mean with building the stack for user mode. The stack
itself runs later in kernel mode on the BlueMod. 
But the problem is already if I try to compile the application on its own.

if somebody has more ideas I would be the first who wants to hear them.
thanks in advance
mathias



> The types used in the macros on line 74 and 75 in local.h
> are wrong. Replace __u16 with u16, and __u32 with u32 and
> you should (probably) be better off.
> 
> However, are you building the stack for user mode?
> In that case, please be aware that the use mode support
> was terminated a long time ago, and I have no idea how much
> of it that actually still works.
> 
> //Peter
> 
> > -----Original Message-----
> > From: Mathias Handorf [mailto:m.handorf@xxxxxxx.au] 
> > Sent: 11 July 2003 12:03
> > To: bluetooth-dev@xxxxxxx.com
> > Subject: [bluetooth-dev] newbie question, compile problems
> > 
> > hey everybody
> > 
> > I started recently on a project with BlueMod and 
> > uClinux-2.4.x. It was no
> > problem to start and run the Bluetooth stack on the BlueMod.
> > But now I try to write my own Application and I get stuck.
> > 
> > I just include btcommon.h and compile it so that I can run 
> > the program on
> > BlueMod (e.g. m68k-elf-gcc -m68000 -Wl, -elf2flt -o test 
> > test.c -lc). But
> > then I got plenty of parse errors in local.h :
> > 
> > In file included from
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /btcommon.h:57
> > ,
> >                  from test.c:1:
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:74:
> > parse error before `cpu_to_le16'
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:74:
> > parse error before `x'
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h: In
> > function `cpu_to_le16':
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:74:
> > `x' undeclared (first use in this function)
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:74:
> > (Each undeclared identifier is reported only once
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:74:
> > for each function it appears in.)
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h: At
> > top level:
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:75:
> > parse error before `cpu_to_le32'
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:75:
> > parse error before `x'
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h: In
> > function `cpu_to_le32':
> > /home/BlueMod/uClinux-hcv/OpenBT/linux/include/linux/bluetooth
> > /local.h:75:
> > `x' undeclared (first use in this function)
> > 
> > can somebody kindly tell me what I'm doing wrong.
> > probably it is just a simple mistake and I'm to blind to see
> it. > 
> > thanks in advance
> > mathias

Attachment: local.h
Description: Binary data