我试图在Ubuntu16.04上安装BlueZ 5.50,因为我需要MIDI支持。
我按以下方式编译和安装了它:
sudo apt-get install libudev-dev
sudo apt-get install libical-dev
sudo apt-get install libreadline-dev
cd bluez-5.50
./configure --enable-midi
make -j8
sudo make install问题是它没有更新/usr/sbin/bluetoothd,这是在我重新启动时启动的默认版本。
bluetoothd -v导致5.37
但./src/bluetoothd -v导致5.50。
路径中唯一的版本似乎是旧版本:
whereis bluetoothd
bluetoothd: /usr/sbin/bluetoothd /usr/share/man/man8/bluetoothd.8.gz为什么安装脚本保留旧版本?如何将所有内容更新到新版本?非做不可吗?
现在,MIDI BLE似乎正在发挥作用,即使是使用旧版本的蓝宝石。
发布于 2018-08-11 12:56:12
如果您从源代码编译程序,并且不使用预编译的dpkg包,则dpkg包将不会以任何方式被触摸或更改。
通常,configure步骤指示构建使用/usr/local作为安装前缀,而不是使用/usr。这是为了防止自编程序覆盖二进制文件或在dpkg包中提供的其他文件。
所以您的bluetoothd二进制文件驻留在/usr/local中。
root@localhost:~/bluez-5.50# find /usr/local -name bluetoothd
/usr/local/libexec/bluetooth/bluetoothd不幸的是,或者幸运的是,不太确定,make install确实在/lib/systemd/system中放置了systemd服务和目标,后者覆盖了dpkg包bluez中的文件。
在我看来,这两个文件应该进入/etc/systemd/system,以防止bluez的更新覆盖手动安装的版本。要做到这一点,您还应该将--with-systemdsystemunitdir=/etc/systemd/system添加到configure命令中,并重新安装新的蓝光和旧的蓝光。
root@localhost:~/bluez-5.50# ./configure --enable-midi --with-systemdsystemunitdir=/etc/systemd/system
root@localhost:~/bluez-5.50# make
root@localhost:~/bluez-5.50# make install
root@localhost:~/bluez-5.50# apt-get install --reinstal bluezhttps://askubuntu.com/questions/1064406
复制相似问题