#!/bin/sh # Set initial variables: PKGNAM=usbutils VERSION=${VERSION:-0.73} BUILD=${BUILD:-2} . /etc/pkghelpers pkghelpers_env rm -rf $PKG mkdir -p $PKG cd $TMP rm -rf usbutils-$VERSION tar xjvf $CWD/usbutils-$VERSION.tar.bz2 cd usbutils-$VERSION pkghelpers_permissions # Fetch the latest usb.ids: rm -f usb.ids* sh ./update-usbids.sh # Patch update-usbids.sh to update the file in /usr/share: zcat $CWD/usbutils.ids.dest.gz | patch -p1 --verbose || exit 1 ./configure \ --prefix=/usr \ --sbindir=/sbin make -j5 || exit 1 make install DESTDIR=$PKG || exit 1 # HAL needs this to be an uncompressed file: if [ -r $PKG/usr/share/usb.ids.gz ]; then gzip -d --force $PKG/usr/share/usb.ids.gz fi mkdir -p $PKG/usr/sbin cat update-usbids.sh > $PKG/usr/sbin/update-usbids chmod 755 $PKG/usr/sbin/update-usbids mkdir -p $PKG/usr/doc/usbutils-$VERSION cp -a \ AUTHORS COPYING ChangeLog NEWS README \ $PKG/usr/doc/usbutils-$VERSION mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc # Build the package: cd $PKG pkghelpers_fixup pkghelpers_makepkg