In order to run the bluetooth C program on my ubuntu desktop I installed the libbluetooth-dev
using
sudo apt-get install libbluetooth-dev
Then I compiled the code with
gcc -o simplescan simplescan.c -lbluetooth
and it executed just fine. However when I tried to cross compiled it for Android using
arm-linux-gnueabi-gcc -o simplescan simplescan.c -lbluetooth
It gave me the error
/usr/lib/gcc-cross/arm-linux-gnueabi/4.7/../../../../arm-linux-gnueabi/bin/ld: cannot find -lbluetooth
collect2: error: ld returned 1 exit status
I noticed there was similar post here: Bluetooth programming in Linux - cross compiler issue
But seems like it didn't give a solution, I am still confused how to install the libbluetooth-dev
support for the cross compiler.