我尝试为 ubuntu 18.04 编译 bluez,从 here 下载最新版本(5.50) .
配置
命令:
./configure --prefix=/usr --mandir=/usr/share/man --sysconfdir=/etc --localstatedir=/var --enable-mesh
失败并显示消息:
...
checking for ELL... no
configure: error: ell library >= 0.3 is required
我忽略了什么是 ELL 以及为什么使用它(很高兴知道),但真正的问题是关于缺少安装的依赖项以消除此错误。
最佳答案
如果您来到这里,一个原因应该是您需要启用了网状协议(protocol)的 bluez。
这是适合我在 ubuntu 18.04 和 bluez 5.50 上的配方。
构建并安装 ELL
我没有找到 ELL 的打包版本,所以我从 here 下载了最新的 ELL 版本.
> tar xvf ~/Downloads/ell-0.6.tar.gz
> cd ell-0.6
> ./configure --prefix=/usr
> make
> sudo make install
构建并安装 Bluez
bluez 可以从 here 下载.
> tar xvf ~/Downloads/bluez-5.50.tar.xz
> cd bluez-5.50
# install required dependencies
> sudo apt install libdbus-1-dev libudev-dev libical-dev libreadline-dev libjson-c-dev
> ./configure --prefix=/usr --mandir=/usr/share/man --sysconfdir=/etc --localstatedir=/var --enable-mesh --enable-deprecated
> make
> sudo make install
注 1:如果您需要 hcitool
,请使用 --enable-deprecated
,因为它在最近的 bluez 版本中已被弃用。
注 2:在运行 meshctl
之前,请确保 bluetooth
服务正在运行:
> systemctl status bluetooth
# if not running:
> systemctl start bluetooth
# if start fails with
# Failed to start bluetooth.service: Unit bluetooth.service is masked.
> systemctl unmask bluetooth
关于ubuntu - 在ubuntu上编译BlueZ : configure error,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51367075/