2019-06-16 20:59:06 +01:00
|
|
|
{ stdenv, fetchFromGitHub }:
|
2018-05-25 04:03:42 +01:00
|
|
|
|
2019-08-13 22:52:01 +01:00
|
|
|
stdenv.mkDerivation {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "raspberrypi-wireless-firmware";
|
2019-08-17 17:42:22 +01:00
|
|
|
version = "2019-08-16";
|
2018-05-25 04:03:42 +01:00
|
|
|
|
|
|
|
srcs = [
|
2018-10-21 03:56:20 +01:00
|
|
|
(fetchFromGitHub {
|
|
|
|
name = "bluez-firmware";
|
|
|
|
owner = "RPi-Distro";
|
|
|
|
repo = "bluez-firmware";
|
2019-08-17 17:42:22 +01:00
|
|
|
rev = "96eefffcccc725425fd83be5e0704a5c32b79e54";
|
|
|
|
sha256 = "05h57gcxhb2c84h99cyxxx4mzi6kd5fm8pjqkz3nq5vs3nv8cqhr";
|
2018-05-25 04:03:42 +01:00
|
|
|
})
|
2018-10-21 03:56:20 +01:00
|
|
|
(fetchFromGitHub {
|
|
|
|
name = "firmware-nonfree";
|
|
|
|
owner = "RPi-Distro";
|
|
|
|
repo = "firmware-nonfree";
|
2019-08-17 17:42:22 +01:00
|
|
|
rev = "130cb86fa30cafbd575d38865fa546350d4c5f9c";
|
|
|
|
sha256 = "0jmhgbpldzz8n8lncpzwfl5ym8zgss05y952rfpwcf9v5c7vgabx";
|
2018-05-25 04:03:42 +01:00
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
sourceRoot = ".";
|
2018-10-21 03:56:20 +01:00
|
|
|
|
2018-05-25 04:03:42 +01:00
|
|
|
dontBuild = true;
|
|
|
|
# Firmware blobs do not need fixing and should not be modified
|
|
|
|
dontFixup = true;
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p "$out/lib/firmware/brcm"
|
|
|
|
|
|
|
|
# Wifi firmware
|
2018-10-21 03:56:20 +01:00
|
|
|
for filename in firmware-nonfree/brcm/brcmfmac434??-sdio.*; do
|
2018-05-25 04:03:42 +01:00
|
|
|
cp "$filename" "$out/lib/firmware/brcm"
|
|
|
|
done
|
|
|
|
|
|
|
|
# Bluetooth firmware
|
2018-10-21 03:56:20 +01:00
|
|
|
cp bluez-firmware/broadcom/*.hcd "$out/lib/firmware/brcm"
|
2018-05-25 04:03:42 +01:00
|
|
|
'';
|
|
|
|
|
2018-07-14 19:49:01 +01:00
|
|
|
outputHashMode = "recursive";
|
|
|
|
outputHashAlgo = "sha256";
|
2019-08-17 17:42:22 +01:00
|
|
|
outputHash = "1r4alf1fbj6vkkf54d0anm47ymb6gn2ykl4a2hhd34b0hnf1dnhn";
|
2018-07-14 19:49:01 +01:00
|
|
|
|
2018-05-25 04:03:42 +01:00
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Firmware for builtin Wifi/Bluetooth devices in the Raspberry Pi 3 and Zero W";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/RPi-Distro/firmware-nonfree";
|
2018-05-25 04:03:42 +01:00
|
|
|
license = licenses.unfreeRedistributableFirmware;
|
|
|
|
platforms = platforms.linux;
|
|
|
|
maintainers = with maintainers; [ lopsided98 ];
|
|
|
|
};
|
|
|
|
}
|