nixpkgs/pkgs/os-specific/linux/firmware/fwupd/no-which.patch
Jan Tojnar 5b8998fdc4
fwupd: 1.2.10 → 1.3.3
https://github.com/fwupd/fwupd/blob/1.3.3/data/org.freedesktop.fwupd.metainfo.xml#L35-L125

systemd.tmpfiles should not be necessary, as the systemd service switched to StateDirectory.
2019-11-18 19:55:39 +01:00

31 lines
763 B
Diff

--- a/plugins/uefi/efi/generate_binary.sh
+++ b/plugins/uefi/efi/generate_binary.sh
@@ -1,9 +1,9 @@
#!/bin/sh
output=$2
-objcopy_cmd=$(which objcopy)
-genpeimg_cmd=$(which genpeimg)
+objcopy_cmd=$(command -v objcopy)
+genpeimg_cmd=$(command -v genpeimg)
-$objcopy_cmd -j .text \
+"$objcopy_cmd" -j .text \
-j .sdata \
-j .data \
-j .dynamic \
@@ -11,7 +11,7 @@
-j .rel \
-j .rela \
-j .reloc \
- $*
+ "$@"
if [ -n "${genpeimg_cmd}" ]; then
$genpeimg_cmd -d \
@@ -20,5 +20,5 @@
+n \
-d \
+s \
- $output
+ "$output"
fi