blob: dace9dd95d9fcf119f34c98afa65ee73c458a6aa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
From 3d15bc001e6ae4d92ff749a8159f9d1bfa2a7a74 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Amadeusz=20=C5=BBo=C5=82nowski?= <aidecoe@aidecoe.name>
Date: Sun, 7 Oct 2012 14:23:29 +0200
Subject: [PATCH 1/2] dracut-functions.sh: find_binary: path starting with
variable
Credits go to Alexander Tsoy <bugs+gentoo@puleglot.ru> who provided the
patch with following explanation:
I get messages "Skipping program $env{DM_SBIN_PATH}/..." when
generating initramfs. This happens because some udev rules contains
variables in path to command:
$ egrep -r 'IMPORT\{program\}=\"\$' /lib64/udev/rules.d/
/lib64/udev/rules.d/10-dm.rules:ENV{DM_COOKIE}=="?*", IMPORT{program}="$env{DM_SBIN_PATH}/dmsetup udevflags $env{DM_COOKIE}"
[...]
$ sudo dracut -f "" 3.5.4-hardened-r1
I: *** Including module: dm ***
I: Skipping program $env{DM_SBIN_PATH}/dmsetup using in udev rule 10-dm.rules as it cannot be found
---
dracut-functions.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dracut-functions.sh b/dracut-functions.sh
index 2ad8f4a..43a0e16 100755
--- a/dracut-functions.sh
+++ b/dracut-functions.sh
@@ -45,7 +45,7 @@ find_binary() {
fi
fi
- type -P $1
+ type -P ${1##*/}
}
if ! [[ $dracutbasedir ]]; then
--
1.7.12
|