summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorAnders Blenstrup-Pedersen2022-07-18 17:20:02 +0900
committerAnders Blenstrup-Pedersen2022-07-18 17:20:02 +0900
commit8e1f659e1e83c7964697c7ef03e343af08ce477d (patch)
treedd31d083cd18e091eadd71ace2d0936c23871244 /PKGBUILD
downloadaur-8e1f659e1e83c7964697c7ef03e343af08ce477d.tar.gz
Initial commit of Japanese mfc6580cdw printer
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD39
1 files changed, 39 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..771c7b68cf1a
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,39 @@
+model="6580cdw"
+pkgname="brother-mfc-$model-jpn"
+pkgver="20220218"
+pkgrel=1
+lprver="1.0.1-0"
+cwver="1.0.1-0"
+pkgdesc="LPR and CUPS drivers for Brother MFC-6580CDW (Japan)"
+url="http://support.brother.com/g/s/id/linux/en/index.html"
+arch=('i686' 'x86_64')
+license=('unknown')
+depends=('perl' 'a2ps' 'lib32-libcups' 'libcups')
+optdepends=('brscan5: Scanner support')
+source=("https://download.brother.com/welcome/dlf103148/mfcj${model}cupswrapper-1.0.1-0.i386.deb" "https://download.brother.com/welcome/dlf103146/mfcj${model}lpr-1.0.1-0.i386.deb")
+sha256sums=("aedcecaab10ec45f9a164607aa3c3c161d519e4132608ac15411e4d48db07359" "6557d708c0518216c32712bf5665a295f287a5858e79d6e99b09ca31c0ff72e8")
+
+package() {
+ ar x mfcj${model}lpr-${lprver}.i386.deb && tar xzvf data.tar.gz
+ ar x mfcj${model}cupswrapper-${cwver}.i386.deb && tar xzvf data.tar.gz
+
+ cd opt/brother/Printers/mfcj${model}
+ perl -i -pe 's#/etc/init.d#/etc/rc.d#g' ./cupswrapper/cupswrappermfcj${model}
+ perl -i -pe 's#printcap\.local#printcap#g' ./inf/setupPrintcapij
+
+ cp -rf $srcdir/usr/ $pkgdir/
+ cp -rf $srcdir/opt/ $pkgdir/
+}
+
+post_install() {
+ post_upgrade;
+}
+
+post_upgrade() {
+ /opt/brother/Printers/mfc${model}/cupswrapper/cupswrappermfc${model} >/dev/null
+ if [ "$?" -eq 0 ]; then
+ printf "\033[1m\033[32m\x3d\x3d\x3e\033\1330m Done. The printer should be visible now via the CUPS-webinterface (http://localhost:631)\n"
+ else
+ printf "\033[1m\032[32m\x3d\x3d\x3e\033\1330m Something went wrong...\n"
+ fi
+}