Patrick Williams | 8b8bc41 | 2016-08-17 15:02:23 -0500 | [diff] [blame] | 1 | FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" |
| 2 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 3 | BCM_BT_SOURCES = " \ |
Patrick Williams | 8b8bc41 | 2016-08-17 15:02:23 -0500 | [diff] [blame] | 4 | file://0001-bcm43xx-Add-bcm43xx-3wire-variant.patch \ |
| 5 | file://0002-bcm43xx-The-UART-speed-must-be-reset-after-the-firmw.patch \ |
| 6 | file://0003-Increase-firmware-load-timeout-to-30s.patch \ |
| 7 | file://0004-Move-the-43xx-firmware-into-lib-firmware.patch \ |
| 8 | file://brcm43438.service \ |
| 9 | " |
| 10 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 11 | BCM_BT_SERVICE = "brcm43438.service" |
Patrick Williams | 8b8bc41 | 2016-08-17 15:02:23 -0500 | [diff] [blame] | 12 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 13 | enable_bcm_bluetooth() { |
Patrick Williams | 8b8bc41 | 2016-08-17 15:02:23 -0500 | [diff] [blame] | 14 | if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then |
| 15 | install -d ${D}${systemd_unitdir}/system |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 16 | install -m 0644 ${WORKDIR}/${BCM_BT_SERVICE} ${D}${systemd_unitdir}/system |
Patrick Williams | 8b8bc41 | 2016-08-17 15:02:23 -0500 | [diff] [blame] | 17 | fi |
| 18 | } |
| 19 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 20 | BCM_BT_RDEPENDS = "\ |
| 21 | udev-rules-rpi \ |
| 22 | pi-bluetooth \ |
| 23 | " |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 24 | |
| 25 | # for raspberrypi3 |
| 26 | SRC_URI_append_raspberrypi3 = " ${BCM_BT_SOURCES}" |
| 27 | |
| 28 | do_install_append_raspberrypi3() { |
| 29 | enable_bcm_bluetooth |
| 30 | } |
| 31 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 32 | SYSTEMD_SERVICE_${PN}_append_raspberrypi3 = " ${BCM_BT_SERVICE}" |
| 33 | |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 34 | RDEPENDS_${PN}_append_raspberrypi3 = " ${BCM_BT_RDEPENDS}" |
| 35 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 36 | # for raspberrypi0-wifi |
| 37 | SRC_URI_append_raspberrypi0-wifi = " ${BCM_BT_SOURCES}" |
| 38 | |
| 39 | do_install_append_raspberrypi0-wifi() { |
| 40 | enable_bcm_bluetooth |
| 41 | } |
| 42 | |
Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 43 | SYSTEMD_SERVICE_${PN}_append_raspberrypi0-wifi = " ${BCM_BT_SERVICE}" |
Brad Bishop | 316dfdd | 2018-06-25 12:45:53 -0400 | [diff] [blame] | 44 | |
| 45 | RDEPENDS_${PN}_append_raspberrypi0-wifi = " ${BCM_BT_RDEPENDS}" |