--- hook-functions.old  2011-04-30 19:20:23.000000000 +0200
+++ hook-functions      2011-04-30 20:04:11.000000000 +0200
@@ -42,10 +42,20 @@
 # Add dependent modules + eventual firmware
 manual_add_modules()
 {
-       local kmod firmware
+       local kmods kmod firmware
 
-       for kmod in $(modprobe --set-version="${version}" --ignore-install \
-       --quiet --show-depends "${1}" | awk '/^insmod/ { print $2 }'); do
+       kmods=$(modprobe --set-version="${version}" --ignore-install \
+       --quiet --show-depends "${1}")
+
+       if [ $? != 0 ] && [ "${verbose}" = "y" ] ; then
+               echo "W: Getting dependencies for module ${1} failed, module 
will not be included, try running \"depmod -a ${version}\"" >&2
+       elif [ -z "${kmods}" ] && [ "${verbose}" = "y" ] ; then
+               echo "W: Got emtpy dependency list for module ${1}, module will 
not be included" >&2
+       fi 
+
+        kmods=$(echo ${kmods} | awk '/^insmod/ { print $2 }')
+
+       for kmod in ${kmods}; do
                # Prune duplicates
                if [ -e "${DESTDIR}/${kmod}" ]; then
                        continue




-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to