%general-entities; ]> $Date$ BlueZ-&bluez-version; BlueZ Introduction to BlueZ The BlueZ package contains the Bluetooth protocol stack for Linux. &lfs110_checked; Package Information Download (HTTP): Download (FTP): Download MD5 sum: &bluez-md5sum; Download size: &bluez-size; Estimated disk space required: &bluez-buildsize; Estimated build time: &bluez-time; Additional Downloads Required patch: BlueZ Dependencies Required , , and Optional (to generate man pages) User Notes: Kernel Configuration If you are building this package to use bluetooth devices (rather than as a build dependency), enable the following options in the kernel configuration, also the options below the next paragraph if you intend to run the tests, and recompile the kernel if necessary: General Setup ---> [*] Configure standard kernel features (expert users) [CONFIG_EXPERT] [*] Enable timerfd() system call [CONFIG_TIMERFD] [*] Enable eventfd() system call [CONFIG_EVENTFD] [*] Networking support ---> [CONFIG_NET] <*/M> Bluetooth subsystem support ---> [CONFIG_BT] <*/M> RFCOMM protocol support [CONFIG_BT_RFCOMM] [*] RFCOMM TTY support [CONFIG_BT_RFCOMM_TTY] <*/M> BNEP protocol support [CONFIG_BT_BNEP] [*] Multicast filter support [CONFIG_BT_BNEP_MC_FILTER] [*] Protocol filter support [CONFIG_BT_BNEP_PROTO_FILTER] <*/M> HIDP protocol support [CONFIG_BT_HIDP] Bluetooth device drivers ---> (Select the appropriate drivers for your Bluetooth hardware) <*/M> RF switch subsystem support ---- [CONFIG_RFKILL] -*- Cryptographic API ---> <*/M*> User-space cryptographic algorithm configuration [CONFIG_CRYPTO_USER] <*/M*> User-space interface for hash algorithms [CONFIG_CRYPTO_USER_API_HASH] <*/M*> User-space interface for symmetric key cipher algorithms [CONFIG_CRYPTO_USER_API_SKCIPHER] <*/M*> MD5 digest algorithm [CONFIG_CRYPTO_MD5] <*/M*> SHA1 digest algorithm [CONFIG_CRYPTO_SHA1] Security Options ---> <*/M*> Diffie-Hellman operations on retained keys [CONFIG_KEY_DH_OPERATIONS] bluez Installation of BlueZ At first, fix an issue building the package with Glibc-2.34 or later: sed 's/pause(/bluez_&/' -i profiles/audio/media.c Now, make some changes needed for SystemV systems: patch -Npi -i ../bluez-&bluez-version;-obexd_without_systemd-1.patch Install BlueZ by running the following commands: ./configure --prefix=/usr \ --sysconfdir=/etc \ --localstatedir=/var \ --enable-library \ --disable-manpages \ --disable-systemd && make ./configure --prefix=/usr \ --sysconfdir=/etc \ --localstatedir=/var \ --disable-manpages \ --enable-library && make To test the results, issue: make check. Now, as the root user: make install && ln -svf ../libexec/bluetooth/bluetoothd /usr/sbin Install the main configuration file as the root user: install -v -dm755 /etc/bluetooth && install -v -m644 src/main.conf /etc/bluetooth/main.conf If desired, install the API documentation as the root user: install -v -dm755 /usr/share/doc/bluez-&bluez-version; && install -v -m644 doc/*.txt /usr/share/doc/bluez-&bluez-version; Command Explanations --disable-manpages: This switch disables generating the manual pages because of the reliance on 'rst2man' in docutils. Remove this switch if you have installed and wish to generate the manual pages. --enable-library: This switch enables building the BlueZ 4 compatibility library which is required by some applications. --disable-systemd: This switch is needed because systemd is not part of LFS/BLFS. If you are using systemd, remove this switch. ln -svf ../libexec/bluetooth/bluetoothd /usr/sbin: This command makes access to the bluetooth daemon more convenient. Configuring BlueZ Configuration Files /etc/bluetooth/main.conf is installed automatically during the install. Additionally, there are three supplementary configuration files. /etc/sysconfig/bluetooth is installed as a part of the boot script below. In addition, you optionally can install the following, as the root user: /etc/bluetooth/mail.conf is installed automatically during the installation. Additionally, there are two supplementary configuration files. In addition, you can optionally install the following files, as the root user: cat > /etc/bluetooth/rfcomm.conf << "EOF" # Start rfcomm.conf # Set up the RFCOMM configuration of the Bluetooth subsystem in the Linux kernel. # Use one line per command # See the rfcomm man page for options # End of rfcomm.conf EOF cat > /etc/bluetooth/uart.conf << "EOF" # Start uart.conf # Attach serial devices via UART HCI to BlueZ stack # Use one line per device # See the hciattach man page for options # End of uart.conf EOF /etc/bluetooth/main.conf <phrase revision="sysv">Boot Script</phrase> <phrase revision="systemd">Systemd Bluez Services</phrase> To automatically start the bluetoothd daemon when the system is rebooted, install the /etc/rc.d/init.d/bluetooth bootscript from the package. To start the bluetoothd daemon at boot, enable the previously installed systemd unit by running the following command as the root user: systemctl enable bluetooth To start the obexd daemon for a user session (to support some Bluetooth programs using it), enable the previously installed systemd unit for all users by running the following command as the root user: systemctl enable --global obex bluetooth make install-bluetooth Systemd will start the Bluetooth daemon only when a bluetooth device is detected on the system. Contents Installed Programs Installed Library Installed Directories bluemoon, bluetoothctl, bluetoothd (symlink), btattach, btmon, hex2hcd, l2ping, l2test, mpris-proxy, and rctest libbluetooth.so /etc/bluetooth, /usr/{include,libexec}/bluetooth, and /usr/share/doc/bluez-&bluez-version; Short Descriptions bluemoon is a Bluemoon configuration utility bluemoon bluetoothctl is the interactive Bluetooth control program bluetoothctl bluetoothd is the Bluetooth daemon bluetoothd btmon provides access to the Bluetooth subsystem monitor infrastructure for reading HCI traces btmon hex2hcd is used to convert a file needed by Broadcom devices to hcd (Broadcom bluetooth firmware) format hex2hcd l2ping is used to send a L2CAP echo request to the Bluetooth MAC address given in dotted hex notation l2ping l2test is a L2CAP testing program l2test rctest is used to test RFCOMM communications on the Bluetooth stack rctest libbluetooth.so contains the BlueZ 4 API functions libbluetooth.so