summaryrefslogtreecommitdiffstats
path: root/initrd
diff options
context:
space:
mode:
Diffstat (limited to 'initrd')
-rw-r--r--initrd/initrd-stuff/bin/.hwautocfg.swpbin32768 -> 0 bytes
-rwxr-xr-xinitrd/initrd-stuff/bin/hwautocfg2
-rwxr-xr-xinitrd/mkdxsinitrd22
3 files changed, 20 insertions, 4 deletions
diff --git a/initrd/initrd-stuff/bin/.hwautocfg.swp b/initrd/initrd-stuff/bin/.hwautocfg.swp
deleted file mode 100644
index 2a4776d5..00000000
--- a/initrd/initrd-stuff/bin/.hwautocfg.swp
+++ /dev/null
Binary files differ
diff --git a/initrd/initrd-stuff/bin/hwautocfg b/initrd/initrd-stuff/bin/hwautocfg
index e19f533a..396b58fa 100755
--- a/initrd/initrd-stuff/bin/hwautocfg
+++ b/initrd/initrd-stuff/bin/hwautocfg
@@ -305,7 +305,7 @@ Please check that\n hwsetup is properly installed and executable."
# "drivers" (pseudo, placeholder strings, ...) to exclude from loading
DRIVERLIST="disabled unknown ignore pcspkr synaptics"
# driver blacklist (real modules which fail to load)
-DRIVERLIST=" "${DRIVERLIST}
+DRIVERLIST="hw_random "${DRIVERLIST}
# check for USB, pcmcia and ieee1394 hardware drivers
for DRIVER in ohci-hcd uhci-hcd ehci-hcd \
ohci1394; do
diff --git a/initrd/mkdxsinitrd b/initrd/mkdxsinitrd
index a2bfe7d5..01172185 100755
--- a/initrd/mkdxsinitrd
+++ b/initrd/mkdxsinitrd
@@ -47,16 +47,31 @@ D_DEFAULTCOUNTRY="<set in ~/distro-config/distro file>"
# End of global variable declaration, nothing needed to be changed at
# default below that line
+# replaces which to find executables inside ROOTDIR
+binfinder()
+{
+ local PROGRAM="$1"
+ local RET=1
+ for ELEMENT in sbin bin usr/bin usr/local/bin usr/bin/X11; do
+ if [ -f "${ROOTDIR}/$ELEMENT/$PROGRAM" ] && [ -x "${ROOTDIR}/$ELEMENT/$PROGRAM" ]; then
+ printf '%s\n' "${ROOTDIR}/$ELEMENT/$PROGRAM"
+ RET=0
+ break
+ fi
+ done
+ return "$RET"
+}
+
# copy some binary to given destination. Takes binary in $1 and
# destination in $2
cobi()
{
local DEST=$2
-local FPTB=`which $1`
+local FPTB=`binfinder $1`
if [ -z ${FPTB} ] ; then
return 1;
else
- cp ${ROOTDIR}/${FPTB} ${INSTDIR}/${DEST}
+ cp ${FPTB} ${INSTDIR}/${DEST}
fi
}
@@ -85,6 +100,7 @@ fi
}
+
# Resolve dynamic library dependencies. Returns a list of symbolic links
# to shared objects and shared object files for the binaries in $*.
# stolen from SuSE mkinitrd
@@ -349,7 +365,7 @@ done
# one of the dhcp clients
for dhcp in dhclient dhcpcd pump ipconfig ; do
- which $dhcp && break;
+ binfinder $dhcp && break;
done
cobi $dhcp bin
mkdir -p ${INSTDIR}/var/{lib,run}