backports: fix uninstall filename
authorHauke Mehrtens <hauke@hauke-m.de>
Fri, 24 Jan 2014 20:21:16 +0000 (21:21 +0100)
committerHauke Mehrtens <hauke@hauke-m.de>
Fri, 24 Jan 2014 20:27:58 +0000 (21:27 +0100)
The uninstall script calculated the filename in the wrong way. It added
the current working dir into the file name, this resulted in names like
this:
/lib/modules/2.6.32-431.3.1.el6.x86_64/updates//home/hauke/backports-20140124/drivers/net/wireless/ipw2x00/ipw2100.ko
The correct one would be this
/lib/modules/2.6.32-431.3.1.el6.x86_64/updates/drivers/net/wireless/ipw2x00/ipw2100.ko

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
backport/scripts/uninstall.sh

index 99f74ab1a0a71f639a1df839a74e12a188f4361e..1eb42b0ba7da58ae3a3e058d438eb45b13f78a4e 100755 (executable)
@@ -11,7 +11,7 @@ else
 fi
 
 for driver in $(find ${BACKPORT_PWD} -type f -name *.ko); do
-       mod_name=${KLIB}${KMODDIR}/${driver}${compr}
+       mod_name=${driver/${BACKPORT_PWD}/${KLIB}${KMODDIR}}${compr}
        echo "  uninstall" $mod_name
        rm -f $mod_name
 done