From b0d4c25c1c66ec4b0394bae3ea4890e02cb00402 Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Wed, 29 Aug 2018 11:35:00 +0200 Subject: fwupd: do not wrap efi capsule (#45719) wrapGAppsHook is not able to skip efi capsules so we need to switch to manual wrapping. Closes: https://github.com/NixOS/nixpkgs/issues/45715 --- pkgs/os-specific/linux/firmware/fwupd/default.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/pkgs/os-specific/linux/firmware/fwupd/default.nix b/pkgs/os-specific/linux/firmware/fwupd/default.nix index f018b5c2a7df..e29dd2e6ee53 100644 --- a/pkgs/os-specific/linux/firmware/fwupd/default.nix +++ b/pkgs/os-specific/linux/firmware/fwupd/default.nix @@ -79,6 +79,19 @@ in stdenv.mkDerivation { FONTCONFIG_FILE = fontsConf; # Fontconfig error: Cannot load default config file + # TODO: wrapGAppsHook wraps efi capsule even though it is not elf + dontWrapGApps = true; + # so we need to wrap the executables manually + postFixup = '' + find -L "$out/bin" "$out/libexec" -type f -executable -print0 \ + | while IFS= read -r -d ''' file; do + if [[ "''${file}" != *.efi ]]; then + echo "Wrapping program ''${file}" + wrapProgram "''${file}" "''${gappsWrapperArgs[@]}" + fi + done + ''; + # /etc/fwupd/uefi.conf is created by the services.hardware.fwupd NixOS module passthru = { filesInstalledToEtc = [ -- cgit 1.4.1