summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e47ab1a4bb4a065e81be5d3ec9054feb3a5b8727 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
pkgname=brother-hll3240cdw-bin
pkgver=3.5.1
pkgrel=1
pkgdesc="LPR driver for Brother HL-L3240CDW printer"
arch=("i686" "x86_64")
url="https://support.brother.com/g/b/producttop.aspx?c=gb&lang=en&prod=hll3240cdw_us_eu_as"
license=("GPL2")
depends=("cups" "perl")
source=("https://download.brother.com/welcome/dlf105734/hll3240cdwpdrv-$pkgver-1.i386.deb")
b2sums=('5203cf2dddba65e152842aa4ddf13602d1c303da5f07e97071f059e7c9bae481600ebb7697643d6d77b1bb815f85b07f62b5da4a6aff5f7587a8c137c0da1951')

prepare() {
  tar -xf data.tar.gz -C "$srcdir"
}

package() {
  cp -R "$srcdir/opt" "$pkgdir/opt"

  # symlink for lpdwrapper
  install -d "$pkgdir/usr/lib/cups/filter/"
  ln -s "/opt/brother/Printers/hll3240cdw/cupswrapper/brother_lpdwrapper_hll3240cdw" "$pkgdir/usr/lib/cups/filter/"

  # symlink for the PPD
  install -d "$pkgdir/opt/cups/model/"
  ln -s "/opt/brother/Printers/hll3240cdw/cupswrapper/brother_hll3240cdw_printer_en.ppd" "$pkgdir/opt/cups/model/"

  # architecture-specific symlinks
  ln -s "/opt/brother/Printers/hll3240cdw/lpd/$CARCH/brhll3240cdwfilter" "$pkgdir/opt/brother/Printers/hll3240cdw/lpd/"
  ln -s "/opt/brother/Printers/hll3240cdw/lpd/$CARCH/brprintconf_hll3240cdw" "$pkgdir/opt/brother/Printers/hll3240cdw/lpd/"
}