mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 06:53:01 +00:00
compressFirmwareXz: preserve meta attributes
Among other things, this preserves the package priority, which is important when building the `hardware.firmware` environment in NixOS.
This commit is contained in:
parent
1c9db9710c
commit
4124eb7bd5
@ -1,8 +1,12 @@
|
||||
{ runCommand }:
|
||||
{ runCommand, lib }:
|
||||
|
||||
firmware:
|
||||
|
||||
runCommand "${firmware.name}-xz" {} ''
|
||||
let
|
||||
args = lib.optionalAttrs (firmware ? meta) { inherit (firmware) meta; };
|
||||
in
|
||||
|
||||
runCommand "${firmware.name}-xz" args ''
|
||||
mkdir -p $out/lib
|
||||
(cd ${firmware} && find lib/firmware -type d -print0) |
|
||||
(cd $out && xargs -0 mkdir -v --)
|
||||
|
Loading…
Reference in New Issue
Block a user