Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 1 | # Copyright (C) 2018 Krzysztof Kozlowski <krzk@kernel.org> |
| 2 | # Released under the MIT license (see COPYING.MIT for the terms) |
| 3 | |
| 4 | SUMMARY = "Broadcom Bluetooth firmware files" |
| 5 | DESCRIPTION = "Firmware for Broadcom Bluetooth devices. Note that in case of BT+WiFi devices, separate WiFi firmware might be needed." |
| 6 | HOMEPAGE = "https://github.com/winterheart/broadcom-bt-firmware" |
| 7 | |
| 8 | LICENSE = "Firmware-Broadcom-WIDCOMM" |
| 9 | NO_GENERIC_LICENSE[Firmware-Broadcom-WIDCOMM] = "LICENSE.broadcom_bcm20702" |
| 10 | |
| 11 | LIC_FILES_CHKSUM = "file://LICENSE.broadcom_bcm20702;md5=c0d5ea0502b00df74173d0f8a48b619d" |
Andrew Geissler | 595f630 | 2022-01-24 19:11:47 +0000 | [diff] [blame] | 12 | SRC_URI = "git://github.com/winterheart/broadcom-bt-firmware.git;branch=master;protocol=https" |
Patrick Williams | 975a06f | 2022-10-21 14:42:47 -0500 | [diff] [blame] | 13 | SRCREV = "a0eb4805dbb232f02f156b9351a23790c1a4cec7" |
Andrew Geissler | bffdb3e | 2020-08-21 16:13:29 -0500 | [diff] [blame] | 14 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 15 | PE = "1" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 16 | |
| 17 | S = "${WORKDIR}/git" |
| 18 | |
| 19 | inherit allarch |
| 20 | |
| 21 | CLEANBROKEN = "1" |
| 22 | |
| 23 | do_compile() { |
| 24 | : |
| 25 | } |
| 26 | |
| 27 | do_install() { |
| 28 | install -d ${D}${nonarch_base_libdir}/firmware/brcm/ |
| 29 | cp brcm/*.hcd ${D}${nonarch_base_libdir}/firmware/brcm/ |
| 30 | |
| 31 | # For license package: |
| 32 | install -m 0644 LICENSE.broadcom_bcm20702 ${D}${nonarch_base_libdir}/firmware/brcm/ |
| 33 | |
| 34 | # For main package: |
| 35 | install -m 0644 DEVICES.md ${D}${nonarch_base_libdir}/firmware/brcm/ |
| 36 | } |
| 37 | |
| 38 | PACKAGES =+ " \ |
| 39 | ${PN}-bcm20702a1 \ |
| 40 | ${PN}-bcm20702b0 \ |
| 41 | ${PN}-bcm20703a1 \ |
| 42 | ${PN}-bcm43142a0 \ |
| 43 | ${PN}-bcm4335c0 \ |
| 44 | ${PN}-bcm4350c5 \ |
| 45 | ${PN}-bcm4356a2 \ |
| 46 | ${PN}-bcm4371c2 \ |
| 47 | ${PN}-license \ |
| 48 | " |
| 49 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 50 | RDEPENDS:${PN}-bcm20702a1 = "${PN}-license" |
| 51 | RDEPENDS:${PN}-bcm20702b0 = "${PN}-license" |
| 52 | RDEPENDS:${PN}-bcm20703a1 = "${PN}-license" |
| 53 | RDEPENDS:${PN}-bcm43142a0 = "${PN}-license" |
| 54 | RDEPENDS:${PN}-bcm4335c0 = "${PN}-license" |
| 55 | RDEPENDS:${PN}-bcm4350c5 = "${PN}-license" |
| 56 | RDEPENDS:${PN}-bcm4356a2 = "${PN}-license" |
| 57 | RDEPENDS:${PN}-bcm4371c2 = "${PN}-license" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 58 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 59 | FILES:${PN}-bcm20702a1 = "${nonarch_base_libdir}/firmware/brcm/BCM20702A1*hcd" |
| 60 | FILES:${PN}-bcm20702b0 = "${nonarch_base_libdir}/firmware/brcm/BCM20702B0*hcd" |
| 61 | FILES:${PN}-bcm20703a1 = "${nonarch_base_libdir}/firmware/brcm/BCM20703A1*hcd" |
| 62 | FILES:${PN}-bcm43142a0 = "${nonarch_base_libdir}/firmware/brcm/BCM43142A0*hcd" |
| 63 | FILES:${PN}-bcm4335c0 = "${nonarch_base_libdir}/firmware/brcm/BCM4335C0*hcd" |
| 64 | FILES:${PN}-bcm4350c5 = "${nonarch_base_libdir}/firmware/brcm/BCM4350C5*hcd" |
| 65 | FILES:${PN}-bcm4356a2 = "${nonarch_base_libdir}/firmware/brcm/BCM4356A2*hcd" |
| 66 | FILES:${PN}-bcm4371c2 = "${nonarch_base_libdir}/firmware/brcm/BCM4371C2*hcd" |
| 67 | FILES:${PN}-license += "${nonarch_base_libdir}/firmware/brcm/LICENSE.broadcom_bcm20702" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 68 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 69 | FILES:${PN} += "${nonarch_base_libdir}/firmware/brcm/*" |
| 70 | RDEPENDS:${PN} += "${PN}-license" |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 71 | |
| 72 | # Make broadcom-bt-firmware depend on all of the split-out packages. |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 73 | python populate_packages:prepend () { |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 74 | firmware_pkgs = oe.utils.packages_filter_out_system(d) |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 75 | d.appendVar('RDEPENDS:broadcom-bt-firmware', ' ' + ' '.join(firmware_pkgs)) |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 76 | } |