Don't use absolute paths for utilities
PATCH 1/1 Don't use absolute paths for utilities
dracut +0 -0
@@ -61,6 +61,8 @@ while (($# > 0)); do shift
done
+PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:$PATH +
[[ $debug ]] && {
export PS4='${BASH_SOURCE}@${LINENO}(${FUNCNAME[0]}): ';
set -x@@ -138,8 +140,8 @@ echo $mods_to_load
## final stuff that has to happen
# generate module dependencies for the initrd
-if ! /sbin/depmod -a -b "$initdir" $kernel; then
- echo "\"/sbin/depmod -a $kernel\" failed."
+if ! depmod -a -b "$initdir" $kernel; then
+ echo "\"depmod -a $kernel\" failed."
exit 1
fidracut-functions +0 -0
@@ -307,7 +307,7 @@ instmods() {
fi
inst_simple "$modpath"
done
- for fw in $(/sbin/modinfo -F firmware $mod 2>/dev/null); do
+ for fw in $(modinfo -F firmware $mod 2>/dev/null); do
if [[ -f /lib/firmware/$fw ]]; then inst_simple "/lib/firmware/$fw" else
--
To unsubscribe from this list: send the line "unsubscribe initramfs" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
dracut
Quoted 1 line · Seewer Philippe
dracut +0
-0
It would be good if your commit message mentioned why it is not a good idea to use absolute paths, eg different distros put things in different places, etc.
--
To unsubscribe from this list: send the line "unsubscribe initramfs" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 1246545040.28989.7.camel-FqX9LgGZnHWDB2HL1qBt2PIbXMQ5te18@public.gmane.org
Quoted 6 lines · David Dillow
dracut
Quoted 1 line · Seewer Philippe
dracut +0
-0It would be good if your commit message mentioned why it is not a good idea to use absolute paths, eg different distros put things in different places, etc.
We've had the discussion about absolute paths and distros a few times, so it should be obvious. --
To unsubscribe from this list: send the line "unsubscribe initramfs" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 11 lines · Seewer Philippe
Quoted 6 lines · David Dillow
dracut
Quoted 1 line · Seewer Philippe
dracut +0
-0It would be good if your commit message mentioned why it is not a good idea to use absolute paths, eg different distros put things in different places, etc.
We've had the discussion about absolute paths and distros a few times, so it should be obvious.
We have, on the list and in IRC, but newcomers to the project will only have the commit log. Our commit text has often been of the same quality as
int i = 0; /* set i to zero */
and I'd like to see it improve. This isn't directed solely at you -- many of us are guilty, including myself.
--
To unsubscribe from this list: send the line "unsubscribe initramfs" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 28 lines · Seewer Philippe
dracut +0
-0@@ -61,6 +61,8 @@ while (($# > 0)); doshift
donedracut +2
-0+PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:$PATH +[[ $debug ]] && { export PS4='${BASH_SOURCE}@${LINENO}(${FUNCNAME[0]}): '; set -x
dracut +2
-2@@ -138,8 +140,8 @@ echo $mods_to_load ## final stuff that has to happen # generate module dependencies for the initrd -if ! /sbin/depmod -a -b "$initdir" $kernel; then - echo "\"/sbin/depmod -a $kernel\" failed." +if ! depmod -a -b "$initdir" $kernel; then + echo "\"depmod -a $kernel\" failed."exit 1
fidracut-functions +0
-0@@ -307,7 +307,7 @@ instmods() {
Quoted 8 lines
fi
inst_simple"$modpath"
done
- for fw in $(/sbin/modinfo -F firmware $mod 2>/dev/null); do
+ for fw in $(modinfo -F firmware $mod 2>/dev/null); do if [[ -f/lib/firmware/$fw]]; theninst_simple"/lib/firmware/$fw"
else
pushed
--
To unsubscribe from this list: send the line "unsubscribe initramfs" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html