# HG changeset patch # User Richard Dunbar # Date 1329533313 0 # Node ID fd59449e36089d761688fa6a2ede4209f79fb8b4 # Parent 4da8cad96f7612664c9dceba0778276f54134bb6 usbutils: lsusb display usb.ids diff -r 4da8cad96f76 -r fd59449e3608 usbutils/receipt --- a/usbutils/receipt Sat Feb 18 09:21:57 2012 +0100 +++ b/usbutils/receipt Sat Feb 18 02:48:33 2012 +0000 @@ -31,9 +31,26 @@ genpkg_rules() { mkdir -p $fs/usr - # We have lsusb in Busybox cp -a $_pkg/usr/bin $fs/usr - rm $fs/usr/bin/lsusb* cp -a $_pkg/usr/sbin $fs/usr sed -i s'/bash/sh/' $fs/usr/bin/usb-devices } + +# Pre and post install commands for Tazpkg. +# Busybox lsusb does not display human-readable usb.ids hardware info. +# We must remove busybox lsusb symlink before installing. +# +pre_install() +{ + local root + root=$1 + echo "Processing pre-install commands..." + echo -n "Removing Busybox lsusb... " + rm -f $root/usr/bin/lsusb + status +} + +post_remove() +{ + ln -s /bin/busybox $1/usr/bin/lsusb +}