summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorandrew2015-11-30 22:11:34 -0800
committerandrew2015-11-30 22:11:34 -0800
commit0d5f15e748455dcf78a2ebe64d8a0d3772661ee2 (patch)
treef5b8a5da453a04db58fc6374b28b5748477ba255
downloadaur-0d5f15e748455dcf78a2ebe64d8a0d3772661ee2.tar.gz
Initial commit
-rw-r--r--.SRCINFO17
-rw-r--r--PKGBUILD26
-rw-r--r--brother-hl-l2380dw.install34
3 files changed, 77 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..386dd750689
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,17 @@
+pkgbase = brother-hl-l2380dw
+ pkgdesc = Brother HL-L2380DW CUPS driver
+ pkgver = 3.2.0
+ pkgrel = 1
+ url = http://www.brother.com
+ install = brother-hl-l2380dw.install
+ arch = i686
+ arch = x86_64
+ license = GPL
+ source = http://download.brother.com/welcome/dlf101770/hll2380dwcupswrapper-3.2.0-1.i386.rpm
+ source = http://download.brother.com/welcome/dlf101769/hll2380dwlpr-3.2.0-1.i386.rpm
+ sha256sums = a4e51f131e4cb7e9337af161e4be275c1a2628c75be04addff0569ff262185ee
+ sha256sums = c93037bdcc1ce5d63451ed701637aa0476898ed88a9eb5f6fbef735ccb1d83fc
+ depends_x86_64 = lib32-glibc
+
+pkgname = brother-hl-l2380dw
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..fe87966532c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,26 @@
+# Maintainer: apaugh (andrew [dot] paugh [at] gmail [dot] com
+
+pkgname="brother-hl-l2380dw"
+pkgver="3.2.0"
+pkgrel="1"
+pkgdesc="Brother HL-L2380DW CUPS driver"
+url="http://www.brother.com"
+license=('GPL')
+install="brother-hl-l2380dw.install"
+arch=('i686' 'x86_64')
+depends_x86_64=('lib32-glibc')
+
+sha256sums=('a4e51f131e4cb7e9337af161e4be275c1a2628c75be04addff0569ff262185ee'
+ 'c93037bdcc1ce5d63451ed701637aa0476898ed88a9eb5f6fbef735ccb1d83fc')
+
+source=(
+ http://download.brother.com/welcome/dlf101770/hll2380dwcupswrapper-$pkgver-1.i386.rpm
+ http://download.brother.com/welcome/dlf101769/hll2380dwlpr-$pkgver-1.i386.rpm
+)
+
+package() {
+ mkdir -p "$pkgdir/usr/share"
+ install -D -m 644 "$srcdir/opt/brother/Printers/HLL2380DW/cupswrapper/brother_lpdwrapper_HLL2380DW" "$pkgdir/usr/lib/cups/filter/brother_lpdwrapper_HLL2380DW"
+ install -D -m 644 "$srcdir/opt/brother/Printers/HLL2380DW/cupswrapper/brother-HLL2380DW-cups-en.ppd" "$pkgdir/usr/share/cups/model/HLL2380DW.ppd"
+}
+
diff --git a/brother-hl-l2380dw.install b/brother-hl-l2380dw.install
new file mode 100644
index 00000000000..adc0b0ae77e
--- /dev/null
+++ b/brother-hl-l2380dw.install
@@ -0,0 +1,34 @@
+post_install() {
+ __port2=`lpinfo -v | grep -i 'usb://Brother/HLL2380DW' | head -1`
+ if [ "$__port2" = '' ];then
+ __port2=`lpinfo -v | grep 'usb://' | head -1`
+ fi
+ __port=`echo $__port2| sed s/direct//g`
+ if [ "$__port" = '' ];then
+ __port="usb:/dev/usb/lp0"
+ fi
+
+ lpadmin -p HLL2380DW -E -v $__port -P /usr/share/cups/model/HLL2380DW.ppd
+ echo "If CUPS is not running now, start it after installation"
+ echo "and type command:"
+ echo " lpadmin -p HLL2380DW -E -v URL -P /usr/share/cups/model/HLL2380DW.ppd"
+ echo "where URL can be found using command:"
+ echo " lpinfo -v | grep -i 'Brother'"
+ echo "You can also register new printer using web interface at:"
+ echo " http://localhost:631/"
+}
+
+post_upgrade() {
+ /bin/true
+}
+
+pre_remove() {
+ lpadmin -x HLL2380DW
+}
+
+
+op=$1
+shift
+
+$op "$@"
+