diff options
-rw-r--r-- | .SRCINFO | 24 | ||||
-rw-r--r-- | PKGBUILD | 33 | ||||
-rw-r--r-- | brother-dcpj785dw.install | 27 | ||||
-rw-r--r-- | fix_lp.patch | 11 |
4 files changed, 95 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..ac66b6a28ca0 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,24 @@ +pkgbase = brother-dcpj785dw + pkgdesc = Driver for the Brother DCP-J785DW wifi/usb multifunctional printer + pkgver = 1.0.0_0 + pkgrel = 1 + url = http://support.brother.com/g/s/id/linux/en/index.html + install = brother-dcpj785dw.install + arch = i686 + arch = x86_64 + license = custom:brother + depends = a2ps + depends = cups + depends = psutils + optdepends = sane: scanning support + optdepends = brscan4: making dcpj785dw available to sane + optdepends = brscan-skey: scankey support if connected via usb + source = fix_lp.patch + source = http://download.brother.com/welcome/dlf102772/dcpj785dwlpr-1.0.0-0.i386.rpm + source = http://download.brother.com/welcome/dlf102773/dcpj785dwcupswrapper-1.0.0-0.i386.rpm + md5sums = c6f0ef15fcec11b5572b930498efcb8b + md5sums = cbebb71277c5ce5f47ad4645cdcaf429 + md5sums = c9483470f70d7926850883f9c1b6e5a7 + +pkgname = brother-dcpj785dw + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..38805078984e --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,33 @@ +# Maintainer: Dirk Salewski <dirk salewski at mailbox dot org> +# Based on the DCP-J552DW PKGBUILD by Marius Rejdak and on the +# DCP-J562DW build by Daniel Dietrich +pkgname=brother-dcpj785dw +pkgver=1.0.0_0 +pkgrel=1 +pkgdesc="Driver for the Brother DCP-J785DW wifi/usb multifunctional printer" +arch=('i686' 'x86_64') +url="http://support.brother.com/g/s/id/linux/en/index.html" +license=('custom:brother') +depends=('a2ps' 'cups' 'psutils') +optdepends=('sane: scanning support' + 'brscan4: making dcpj785dw available to sane' + 'brscan-skey: scankey support if connected via usb') +install='brother-dcpj785dw.install' +source=("fix_lp.patch" \ + "http://download.brother.com/welcome/dlf102772/dcpj785dwlpr-${pkgver//_/-}.i386.rpm" \ + "http://download.brother.com/welcome/dlf102773/dcpj785dwcupswrapper-${pkgver//_/-}.i386.rpm") +md5sums=('c6f0ef15fcec11b5572b930498efcb8b' + 'cbebb71277c5ce5f47ad4645cdcaf429' + 'c9483470f70d7926850883f9c1b6e5a7') + +build() { + cd "$srcdir" + patch -Np0 < fix_lp.patch +} + +package() { + install -d "$pkgdir"/usr/bin + install -d "$pkgdir"/var/spool/lpd + install -Dm755 "$srcdir"/usr/bin/brprintconf_dcpj785dw "$pkgdir"/usr/bin/ + cp -R "$srcdir"/opt "$pkgdir"/opt +} diff --git a/brother-dcpj785dw.install b/brother-dcpj785dw.install new file mode 100644 index 000000000000..6f515c0adaa1 --- /dev/null +++ b/brother-dcpj785dw.install @@ -0,0 +1,27 @@ +post_install() { + # lpr + /opt/brother/Printers/dcpj785dw/inf/setupPrintcapij dcpj785dw -i + + # cupswrapper + /opt/brother/Printers/dcpj785dw/cupswrapper/cupswrapperdcpj785dw + + systemctl restart org.cups.cupsd +} + +post_upgrade() { + /bin/true +} + +pre_remove() { + # lpr + /opt/brother/Printers/dcpj785dw/inf/setupPrintcapij dcpj785dw -e + + # cupswrapper + /opt/brother/Printers/dcpj785dw/cupswrapper/cupswrapperdcpj785dw -e +} + +op=$1 +shift + +$op "$@" + diff --git a/fix_lp.patch b/fix_lp.patch new file mode 100644 index 000000000000..9300cc1e23dd --- /dev/null +++ b/fix_lp.patch @@ -0,0 +1,11 @@ +--- opt/brother/Printers/dcpj785dw/inf/setupPrintcapij.old 2008-09-15 22:01:07.000000000 +0200 ++++ opt/brother/Printers/dcpj785dw/inf/setupPrintcapij 2008-09-15 22:01:26.000000000 +0200 +@@ -34,7 +34,7 @@ + if [ ! -d $SPOOLER_NAME ]; then + mkdir $SPOOLER_NAME + fi +- chown lp $SPOOLER_NAME ++ chown root $SPOOLER_NAME + chgrp lp $SPOOLER_NAME + chmod 700 $SPOOLER_NAME + |