Download the source-code of bluez (version 5.39 at the time of writing). Extract the archive and create a subfolder named ‘patches‘ within the bluez directory.
Change into the ‘patches‘ directory and download all bluez patches found at:
Please note that you have to download these files in ‘raw mode’, otherwise HTML tags will remain and patch will complain about the garbage within the files.
While being in the bluez folder apply all patches with:
patch -p 1 < patches/bluez-01_add-obexd-policy.patch patch -p 1 < patches/bluez-02_obexd-use-system-bus.patchpatch -p1 < patches/bluez-03_storagedir.patch ...
Navigate to the bluez/src subdirectory and edit the file ‘bluetooth.ver’. Add this line into the ‘global:’ block:
Alternatively, download the already patched bluez source code from my github repo:
git clone https://github.com/luetzel/bluez
I will try to keep my repo in sync with future releases of bluez and patches to support other PS3 clones than Gasia/Shanwan. Current version of patched blueZ is 5.43.
Change into the bluez folder, then, configure, compile and install bluez:
./configure --prefix=/usr --mandir=/usr/share/man --sysconfdir=/etc --localstatedir=/var --enable-sixaxis make -j3 sudo make install
Be aware that this will overwrite your distribution’s bluetooth/bluez package.
It is highly recommended to purge/uninstall your distributions bluez package prior to the installation of patched bluez in order to avoid version conflicts.
Now, restart the bluetooth daemon with:
sudo systemctl daemon-reload sudo systemctl start bluetooth
On distributions without systemd, you have to use:
sudo service bluetooth restart
If this doesn’t work or if you are unable to pair your controller in the following steps, reboot your Pi after installation of patched bluez!