desktop/usb-modeswitch/PKGBUILD
2015-11-30 19:29:22 +01:00

44 lines
1.3 KiB
Bash

pkgname=usb-modeswitch
_pkgname=usb_modeswitch
pkgver=2.2.6
pkgrel=1
_pkgdata=20151101
pkgdesc="Activating switchable USB devices on Linux."
arch=('x86_64')
url="http://www.draisberghof.de/usb_modeswitch/"
license=('GPL3')
depends=('libusb' 'tcl')
makedepends=('gcc' 'make')
conflicts=(usb_modeswitch)
replaces=(usb_modeswitch)
categories=('system')
backup=("etc/$_pkgname.conf")
source=("http://www.draisberghof.de/$_pkgname/$pkgname-$pkgver.tar.bz2"
"http://www.draisberghof.de/$_pkgname/$pkgname-data-$_pkgdata.tar.bz2"
"usb-modeswitch-${pkgver}-device_reference.txt::http://www.draisberghof.de/$_pkgname/device_reference.txt")
sha256sums=('7ee42be2fe26dde20c58f54bf678fb136d2706250e4aa74f06fc97268a46e90f'
'584d362bc0060c02016edaac7b05ebd6558d5dcbdf14f1ae6d0ec9630265a982'
'07d32333eda6b8c19572490e01ab6e7b6912fb07a4b2f0f491ddb80ad7eceed3')
build() {
cd $srcdir/usb-modeswitch-$pkgver/
make clean
make
}
package() {
cd $srcdir/usb-modeswitch-$pkgver/
mkdir -p $pkgdir/usr/lib/udev
mkdir -p $pkgdir/etc
mkdir -p $pkgdir/usr/share/man/man1
make DESTDIR=${pkgdir} UDEVDIR=${pkgdir}/usr/lib/udev install
cp $srcdir/usb-modeswitch-${pkgver}-device_reference.txt $pkgdir/etc/usb_modeswitch.setup
cd $srcdir/usb-modeswitch-data-${_pkgdata}
make DESTDIR=$pkgdir install RULESDIR=${pkgdir}/usr/lib/udev/rules.d
}