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

Re: [bluetooth-dev] patch for arm

I try to run in user mode the axis stack for ARM. I have applied your patch and
encountered a link problem.

arm-linux-gcc -g -Wall -I../include -DBTD_USERSTACK   -c btd.c -o btd.o
arm-linux-gcc -g -Wall -I../include -DBTD_USERSTACK   -c l2cap.c -o l2cap.o
l2cap.c: In function `l2cap_connect_req':
l2cap.c:1620: warning: implicit declaration of function `cpu_to_le16'
l2cap.o: In function `l2cap_connect_req':
/home/xde/bluetooth/axis/arm/apps/userstack/l2cap.c:1620: undefined reference to
/home/xde/bluetooth/axis/arm/apps/userstack/l2cap.c:1620: relocation truncated
to fit: R_ARM_PC24 cpu_to_le16
/home/xde/bluetooth/axis/arm/apps/userstack/l2cap.c:2026: relocation truncated
to fit: R_ARM_PC24 cpu_to_le16
collect2: ld returned 1 exit status
make: *** [btduser] Error

This macro is defined in the kernel headers...
What did I miss ?

Thank you

Gordon McNutt wrote:
> Hi,
> Here's the promised patch to make the stack work on ARM processors. This
> is the first time I've ever submitted a patch to anything so please be
> tolerant but inform me of errors you find. I've verified that it works
> for me, but you know how these things go...
> If you've never applied a patch here's a crash course:
> Get the bluetooth_20000814 tarball from axis's website, and save the
> patchfile attached to this mail.
> gunzip bluetooth_20000814-gmcnutt-patch1.gz
> tar -xvzf bluetooth_20000814.tgz
> cd bluetooth
> patch -p3 < ../bluetooth_20000814-gmcnutt-patch1
> That's it. Hints for cross-compiling can be found in the Makefile under
> apps and src, respectively. If you need an arm cross-compiler for the
> i386 I got my toolchain from handhelds.org (it's known as the skiff
> toolchain, and works best when installed in /).
> This patch is too big for a single patch, I know, and contains multiple
> changes. I apologize for any inconvenience the unwanted changes make and
> will keep these things in mind in the future. Here's a summary:
> 1. Modified .h files and a few .c files to make the stack work on ARM
> 2. Added a few options to btd, including -a <IP address> and -f <flow
> control>.
> 3. Some initial changes to hci for big-endian processors.
> Have fun,
> --Gordon
>   --------------------------------------------------------------------------------
>                                            Name: bluetooth_20000814-gmcnutt-patch1.gz
>    bluetooth_20000814-gmcnutt-patch1.gz    Type: application/x-gzip
>                                        Encoding: base64