1 # Contributor: Adam Hani Schakaki (krzd) <krzd@krzd.net>
2 pkgname=brother-mfc5490cn-lpr
6 pkgdesc="LPR driver for Brother MFC-5490CN multifunction network printer"
8 url="http://welcome.solutions.brother.com/bsc/public_s/id/linux/en/index.html"
9 license=('custom:Brother_Software_Open_License_Agreement')
11 makedepends=('binutils')
12 optdepends=("brother-$_printer-cupswrapper: For printing via CUPS.")
13 provides=("$pkgname=${pkgver%_*}")
14 conflicts=("$pkgname")
16 source=("http://www.brother.com/pub/bsc/linux/dlf/${_printer}lpr-${pkgver/_/-}.i386.deb"
18 md5sums=('749880e5ae19dee6aea51457d15f3887'
19 'aa36745fb35ddff6343bed3ae8dae5eb')
23 ar x ${_printer}lpr-${pkgver/_/-}.i386.deb || return 1
25 tar -xzvf data.tar.gz -C data || return 1
26 # Fix directory structure. Moves /usr/local/Brother to /usr/share/brother and fix links
27 mv data/usr/local/Brother data/usr/local/brother
28 mv data/usr/local data/usr/share
29 sed -i 's|/usr/local/Brother|/usr/share/brother|g' $(grep -lr '/usr/local/Brother' data/) || return 1
30 cp -r data/usr $pkgdir || return 1
32 install -D -m644 license.txt $pkgdir/usr/share/licenses/$pkgname/license.txt || return 1