Cross Compile "bluez-4.18" Arm-xScale Platform (原创)

 

The following is my last two days' experience of using bluz-4.18 on arm-xscale.

I did it with 完颜 TX.

 

mkdir -p /nfsroot/arm-xscale-linux-gnu/steven_root/         <= It is the root file system of my arm-xscale board.
export PKG_CONFIG_LIBDIR/nfsroot/arm-xscale-linux-gnu/steven_root/lib/pkgconfig      <= It is to configue my cross compile pkg-config.

pkg-config --list-all

 

**  bluez-4.18 is based on dbus and glib and dbus is based on expat (a xml paser lib), so we must cross compile expat, dbus and glib first.

 

1.cross compile expat-2.0.1
./configure --host=arm-xscale-linux-gnu --prefix=/nfsroot/arm-xscale-linux-gnu/steven_root/ 

make & make install

 

2.cross compile dbus-1.0.3   (* Here we first use verion 1.0.3, but we found this verion is too low to compile dbus-gib.0.78 )
echo ac_cv_have_abstract_sockets=yes>arm-linux.cache
./configure --host=arm-xscale-linux-gnu --cache-file=arm-linux.cache --with-xml=libxml/expat --with-x=no --prefix=/nfsroot/arm-xscale-linux-gnu/steven_root/
make & make install

 

 

3.corss compile glib-2.18
echo ac_cv_type_long_long=yes>arm-linux.cache
echo glib_cv_stack_grows=no>>arm-linux.cache
echo glib_cv_uscore=no>>arm-linux.cache
echo ac_cv_func_posix_getpwuid_r=yes>>arm-linux.cache
echo ac_cv_func_posix_getgrgid_r=yes>>arm-linux.cache
./configure --host=arm-xscale-linux-gnu --cache-file=arm-linux.cache --prefix=/nfsroot/arm-xscale-linux-gnu/steven_root/
make

* It fails to cross compile the "gio", so we have to do some modification to the gio/Makefile.

* At line1252 and 1257, I deleted word "--internal".

make & make install

 

4.cross compile bluez-4.18
./configure --host=arm-xscale-linux-gnu --prefix=/nfsroot/arm-xscale-linux-gnu/steven_root/ --disable-audio --enable-test

make & make install

 

5. How to run bluz-4.18 on arm-xscale

 

#insmod bluetooth.ko
#insmod hci_uart.ko
#insmod l2cap.ko
#insmod rfcomm.ko

 

#/bin/busybox adduser messagebus  <<- 板子自带的busybox中无 adduser 命令, 这个busybox是我自己交叉编译的.

#/bin/busybox adduser passwd   

#dbus-daemon --system

#bluetoothd.

 

#hciattach -s 115200 ttyS1 bcsp 115200
#hciconfig hci0 reset
#hciconfig -a
#hcitool scan

 


To be added those steps using obex functions.


 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 5
    评论
评论 5
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值