WIP: feat(linux-firmware): initial packaging of linux firmware

This commit is contained in:
Lars Sjöström 2025-03-28 18:58:21 +01:00
parent d10bd7bb04
commit 2894de6b45
No known key found for this signature in database
4 changed files with 241 additions and 29 deletions
pkgs/linux-firmware

View file

@ -0,0 +1,38 @@
{
stdenv,
pkgs,
}:
stdenv.mkDerivation {
pname = pkgs.linux-firmware.name;
version = pkgs.linux-firmware.version;
src = pkgs.linux-firmware.src;
buildInputs = with pkgs; [
erofs-utils
cryptsetup
];
nativeBuildInputs = with pkgs; [
python3
rdfind
which
zstd
];
noBrokenSymlinks = true;
installTargets = [
"install-zst"
"dedup"
];
# inspo: https://gitlab.archlinux.org/archlinux/packaging/packages/linux-firmware/-/blob/main/PKGBUILD?ref_type=heads#L93
makeFlags = [
"DESTDIR=$(out)"
"ZSTD_CLEVEL=19"
"FIRMWAREDIR=/usr/lib/firmware"
];
postInstall = ./post-install.sh;
}