Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] New package: brother-hl5340d-cupswrapper-2.0.4
@ 2019-07-10  5:15 voidlinux-github
  2019-07-10  5:28 ` [PR PATCH] [Closed]: " voidlinux-github
  0 siblings, 1 reply; 3+ messages in thread
From: voidlinux-github @ 2019-07-10  5:15 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 359 bytes --]

There is a new pull request by Monkey-7-12 against master on the void-packages repository

https://github.com/Monkey-7-12/void-packages brother-hl5340d-cupswrapper
https://github.com/void-linux/void-packages/pull/12955

New package: brother-hl5340d-cupswrapper-2.0.4


A patch file from https://github.com/void-linux/void-packages/pull/12955.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-brother-hl5340d-cupswrapper-12955.patch --]
[-- Type: application/text/x-diff, Size: 7452 bytes --]

From 8d1d5ce4aadb043a2aefd74bb59821aa1f8b9105 Mon Sep 17 00:00:00 2001
From: Monkey 7 <monkeyseven@fblog.ch>
Date: Wed, 10 Jul 2019 07:08:21 +0200
Subject: [PATCH] New package: brother-hl5340d-cupswrapper-2.0.4

---
 srcpkgs/brother-hl5340d-cupswrapper/INSTALL   |   5 +
 srcpkgs/brother-hl5340d-cupswrapper/REMOVE    |   5 +
 .../patches/cupswrapperHL5340D.patch          | 125 ++++++++++++++++++
 srcpkgs/brother-hl5340d-cupswrapper/template  |  37 ++++++
 4 files changed, 172 insertions(+)
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/INSTALL
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/REMOVE
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/template

diff --git a/srcpkgs/brother-hl5340d-cupswrapper/INSTALL b/srcpkgs/brother-hl5340d-cupswrapper/INSTALL
new file mode 100644
index 00000000000..2825fd47a9f
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/INSTALL
@@ -0,0 +1,5 @@
+case "${ACTION}" in
+    post)
+        usr/lib/brother/cupswrapper/cupswrapperHL5340D-2.0.4 -i
+        ;;
+esac
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/REMOVE b/srcpkgs/brother-hl5340d-cupswrapper/REMOVE
new file mode 100644
index 00000000000..0e84f1023ea
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/REMOVE
@@ -0,0 +1,5 @@
+case ${ACTION} in
+    pre) 
+        usr/lib/brother/cupswrapper/cupswrapperHL5340D-2.0.4 -e
+        ;;
+esac
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch b/srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch
new file mode 100644
index 00000000000..73611570465
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch
@@ -0,0 +1,125 @@
+diff -ur orig/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4 new/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4
+--- orig/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4	2009-09-10 04:48:37.000000000 +0200
++++ new/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4	2019-07-09 10:08:23.763781987 +0200
+@@ -22,8 +22,7 @@
+   lpadmin -x HL5340D
+   rm -f /usr/share/cups/model/HL5340D.ppd
+   rm -f /usr/lib/cups/filter/brlpdwrapperHL5340D
+-  rm -f /usr/lib64/cups/filter/brlpdwrapperHL5340D
+-  rm -f /usr/local/Brother/cupswrapper/brcupsconfig3
++  rm -f /usr/lib/brother/cupswrapper/brcupsconfig3
+   if [ -f /usr/share/ppd/HL5340D.ppd ];then
+   rm -f /usr/share/ppd/HL5340D.ppd
+   fi
+@@ -38,11 +37,14 @@
+ if [ "$1" = "-r" ]; then
+   lpadmin -x HL5340D
+   if [ -e /etc/init.d/cups ]; then
+-    /etc/init.d/cups restart
++    sv restart cupsd restart
+   fi
+   if [ -e /etc/init.d/cupsys ]; then
+     /etc/init.d/cupsys restart
+   fi
++  if [ -e /usr/bin/sv -a -e /var/service/cupsd/run ]; then
++    /usr/bin/sv restart cupsd
++  fi
+   exit 0 
+ fi
+ if [ "$1" = "help" ] || [ "$1" = "-h" ]; then
+@@ -54,15 +56,18 @@
+ fi
+ mkdir -p /usr/lib/cups/filter
+ 
+-if [ -e "/usr/local/Brother/lpd/filterHL5340D" ]; then
++if [ -e "/usr/lib/brother/lpd/filterHL5340D" ]; then
+   :
+ else
+   echo "ERROR : Brother LPD filter is not installed."
+ fi
+ rm -f /usr/share/cups/model/HL5340D.ppd
+ ppd_file_name=/usr/share/cups/model/HL5340D.ppd
++#if [ ! -e /usr/share/cups/model ]; then
++#   ppd_file_name=/usr/share/ppd/HL5340D.ppd
++#fi
+ if [ ! -e /usr/share/cups/model ]; then
+-   ppd_file_name=/usr/share/ppd/HL5340D.ppd
++  mkdir -p /usr/share/cups/model
+ fi
+ 
+ cat <<ENDOFPPDFILE >$ppd_file_name
+@@ -372,20 +377,14 @@
+ ENDOFPPDFILE
+ 
+ chmod 755  $ppd_file_name
+-if [ -e '/usr/share/ppd' ];then
+-  if [ -e '/usr/share/cups/model' ];then
+-    cp  $ppd_file_name  /usr/share/ppd
+-  fi
+-fi
++#if [ -e '/usr/share/ppd' ];then
++#  if [ -e '/usr/share/cups/model' ];then
++#    cp  $ppd_file_name  /usr/share/ppd
++#  fi
++#fi
+ 
+ brotherlpdwrapper=/usr/lib/cups/filter/brlpdwrapperHL5340D
+-brotherlpdwrapper64=/usr/lib64/cups/filter/brlpdwrapperHL5340D
+ rm -f  $brotherlpdwrapper
+-if [ ! -e /usr/lib/cups/filter ];then
+-  if [ -e /usr/lib64/cups/filter ];then
+-    brotherlpdwrapper=/usr/lib64/cups/filter/brlpdwrapperHL5340D
+-  fi
+-fi
+ 
+ 
+ cat <<!ENDOFWFILTER! >$brotherlpdwrapper
+@@ -517,25 +516,25 @@
+ fi
+ 
+ 
+-if [ -e "/usr/local/Brother/lpd/filter\$PRINTER" ]; then
++if [ -e "/usr/lib/brother/lpd/filter\$PRINTER" ]; then
+        :
+ else
+-    echo "ERROR: /usr/local/Brother/lpd/filter\$PRINTER does not exist"   >>\$LOGFILE
++    echo "ERROR: /usr/lib/brother/lpd/filter\$PRINTER does not exist"   >>\$LOGFILE
+     errorcode=30
+     exit $errorcode
+ fi
+ 
+-if [ -e "/usr/local/Brother/cupswrapper/brcupsconfig3" ]; then
++if [ -e "/usr/lib/brother/cupswrapper/brcupsconfig3" ]; then
+   if [ \$DEBUG = 0 ]; then
+-     /usr/local/Brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD 0 "\$options" >> /dev/null
++     /usr/lib/brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD 0 "\$options" >> /dev/null
+   else
+-     /usr/local/Brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD \$LOGCLEVEL "\$options" >>\$LOGFILE
++     /usr/lib/brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD \$LOGCLEVEL "\$options" >>\$LOGFILE
+   fi
+ fi
+ 
+ 
+ if [ \$DEBUG -le 2 ]; then
+-    cat    \$INPUT_TEMP_PS | /usr/local/Brother/lpd/filter\$PRINTER
++    cat    \$INPUT_TEMP_PS | /usr/lib/brother/lpd/filter\$PRINTER
+ fi
+ 
+ if [ \$DEBUG -ge 2 ];  then
+@@ -553,14 +552,9 @@
+ 
+ 
+ chmod 755 $brotherlpdwrapper
+-if [ -e /usr/lib/cups/filter ]; then
+- if [ -e /usr/lib64/cups/filter ]; then
+-   cp $brotherlpdwrapper  $brotherlpdwrapper64
+- fi
+-fi
+ 
+-chmod a+w /usr/local/Brother/inf/brHL5340Drc
+-chmod a+w /usr/local/Brother/inf
++chmod a+w /usr/lib/brother/inf/brHL5340Drc
++chmod a+w /usr/lib/brother/inf
+ if [ -e /etc/init.d/lpd ]; then
+    /etc/init.d/lpd stop
+ fi
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/template b/srcpkgs/brother-hl5340d-cupswrapper/template
new file mode 100644
index 00000000000..65c97945ff3
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/template
@@ -0,0 +1,37 @@
+# Template file for 'brother-hl5340d-cupswrapper'
+pkgname=brother-hl5340d-cupswrapper
+_br_version=2.0.4
+_br_revision=1
+version=${_br_version}
+revision=1
+archs="i686 x86_64"
+create_wrksrc=yes
+depends="brother-hl5340d-lpr cups cups-filters"
+short_desc="CUPS wrapper driver for the brother HL5340D printer"
+maintainer="Monkey 7<monkeyseven@fblog.ch>"
+license="brother-eula GPL-2"
+homepage="http://support.brother.com"
+distfiles="http://www.brother.com/pub/bsc/linux/dlf/cupswrapperHL5340D-${version}-${_br_revision}.i386.deb
+	http://www.brother.com/pub/bsc/linux/dlf/BR5340_2_GPL.ppd.gz"
+checksum="a39c39e086904ec79d2ac0a9fe24bf2dd474ccd959adc11ad9d9b0b5d2649320
+ 	e8b8bb0688c2a181c9ebbb597ca7f467513262420bbf9a3c9bc1e2cf6e0bf9ee"
+nopie=yes
+patch_args="-Np1"
+
+do_extract() {
+	ar x ${XBPS_SRCDISTDIR}/${pkgname}-${version}/cupswrapperHL5340D-${version}-${_br_revision}.i386.deb
+	tar xzpvf data.tar.gz -C ${wrksrc}
+	# Brother HL-5340D BR-Script3
+	gunzip -c ${XBPS_SRCDISTDIR}/${pkgname}-${version}/BR5340_2_GPL.ppd.gz >${wrksrc}/BR5340_2_GPL.ppd
+}
+
+do_install() {
+	cp -a ${wrksrc}/usr ${DESTDIR}/
+	vmkdir usr/lib
+	mv ${DESTDIR}/usr/local/Brother ${DESTDIR}/usr/lib/brother
+	rm -rf ${DESTDIR}/usr/local
+	# Brother HL-5340D BR-Script3
+	vmkdir usr/share/cups/model
+	cp ${wrksrc}/BR5340_2_GPL.ppd ${DESTDIR}/usr/share/cups/model/BR5340_2_GPL.ppd
+}
+

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PR PATCH] [Closed]: New package: brother-hl5340d-cupswrapper-2.0.4
  2019-07-10  5:15 [PR PATCH] New package: brother-hl5340d-cupswrapper-2.0.4 voidlinux-github
@ 2019-07-10  5:28 ` voidlinux-github
  0 siblings, 0 replies; 3+ messages in thread
From: voidlinux-github @ 2019-07-10  5:28 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 179 bytes --]

There's a closed pull request on the void-packages repository

New package: brother-hl5340d-cupswrapper-2.0.4
https://github.com/void-linux/void-packages/pull/12955
Description: 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PR PATCH]  New package: brother-hl5340d-cupswrapper-2.0.4
@ 2019-07-10  6:00 voidlinux-github
  0 siblings, 0 replies; 3+ messages in thread
From: voidlinux-github @ 2019-07-10  6:00 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 360 bytes --]

There is a new pull request by Monkey-7-12 against master on the void-packages repository

https://github.com/Monkey-7-12/void-packages brother-hl5340d-cupswrapper
https://github.com/void-linux/void-packages/pull/12957

 New package: brother-hl5340d-cupswrapper-2.0.4


A patch file from https://github.com/void-linux/void-packages/pull/12957.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-brother-hl5340d-cupswrapper-12957.patch --]
[-- Type: application/text/x-diff, Size: 15255 bytes --]

From 4a63415235c9d5b01e3c421c690951338eb9f84b Mon Sep 17 00:00:00 2001
From: Monkey 7 <monkeyseven@fblog.ch>
Date: Wed, 10 Jul 2019 07:02:55 +0200
Subject: [PATCH 1/2] New package: brother-hl5340d-lpr-2.0.3

---
 srcpkgs/brother-hl5340d-lpr/template | 40 ++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)
 create mode 100644 srcpkgs/brother-hl5340d-lpr/template

diff --git a/srcpkgs/brother-hl5340d-lpr/template b/srcpkgs/brother-hl5340d-lpr/template
new file mode 100644
index 00000000000..f8287b2238b
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-lpr/template
@@ -0,0 +1,40 @@
+# Template file for 'brother-hl5340d-lpr'
+pkgname=brother-hl5340d-lpr
+_br_version=2.0.3
+_br_revision=1
+version=${_br_version}
+revision=1
+archs="i686 x86_64"
+create_wrksrc=yes
+make_dirs="/var/spool/lpd 0775 root lp"
+depends="a2ps ghostscript"
+short_desc="LPR driver for the brother HL5340D printer"
+maintainer="Monkey 7<monkeyseven@fblog.ch>"
+license="brother-eula GPL-2"
+homepage="http://support.brother.com"
+distfiles="http://www.brother.com/pub/bsc/linux/dlf/hl5340dlpr-${version}-${_br_revision}.i386.deb"
+checksum="32f2d3e0297bbbcc4aab70f911fab3ba3cc6a0eb98c3569dfcb22beef6e32c19"
+nopie=yes
+patch_args="-Np1"
+
+
+if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
+	depends+=" glibc-32bit"
+fi
+
+do_extract() {
+	ar x ${XBPS_SRCDISTDIR}/${pkgname}-${version}/hl5340dlpr-${_br_version}-${_br_revision}.i386.deb
+	tar xzpvf data.tar.gz -C ${wrksrc}
+}
+
+do_install() {
+	mkdir -p ${DESTDIR}
+	cp -a ${wrksrc}/usr ${DESTDIR}/
+	if [ "$XBPS_TARGET_MACHINE" = "x86_64" ]; then
+	  mkdir -p ${DESTDIR}/usr/lib32/
+ 	  mv ${DESTDIR}/usr/lib/* ${DESTDIR}/usr/lib32/
+	fi
+	mv ${DESTDIR}/usr/local/Brother ${DESTDIR}/usr/lib/brother
+	rm -rf ${DESTDIR}/usr/local
+}
+

From 6d73a45d4c5d77641a6b7804a512a1f57d4ee5e0 Mon Sep 17 00:00:00 2001
From: Monkey 7 <monkeyseven@fblog.ch>
Date: Wed, 10 Jul 2019 07:56:40 +0200
Subject: [PATCH 2/2] New package: brother-hl5340d-cupswrapper-2.0.4

---
 srcpkgs/brother-hl5340d-cupswrapper/INSTALL   |   5 +
 srcpkgs/brother-hl5340d-cupswrapper/REMOVE    |   5 +
 .../cupswrapperHL5340D-2.0.4.patch.old        |  84 ++++++++++++
 .../brother-hl5340d-cupswrapper/files/LICENSE |   9 ++
 .../patches/cupswrapperHL5340D.patch          | 125 ++++++++++++++++++
 srcpkgs/brother-hl5340d-cupswrapper/template  |  37 ++++++
 6 files changed, 265 insertions(+)
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/INSTALL
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/REMOVE
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/cupswrapperHL5340D-2.0.4.patch.old
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/files/LICENSE
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch
 create mode 100644 srcpkgs/brother-hl5340d-cupswrapper/template

diff --git a/srcpkgs/brother-hl5340d-cupswrapper/INSTALL b/srcpkgs/brother-hl5340d-cupswrapper/INSTALL
new file mode 100644
index 00000000000..2825fd47a9f
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/INSTALL
@@ -0,0 +1,5 @@
+case "${ACTION}" in
+    post)
+        usr/lib/brother/cupswrapper/cupswrapperHL5340D-2.0.4 -i
+        ;;
+esac
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/REMOVE b/srcpkgs/brother-hl5340d-cupswrapper/REMOVE
new file mode 100644
index 00000000000..0e84f1023ea
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/REMOVE
@@ -0,0 +1,5 @@
+case ${ACTION} in
+    pre) 
+        usr/lib/brother/cupswrapper/cupswrapperHL5340D-2.0.4 -e
+        ;;
+esac
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/cupswrapperHL5340D-2.0.4.patch.old b/srcpkgs/brother-hl5340d-cupswrapper/cupswrapperHL5340D-2.0.4.patch.old
new file mode 100644
index 00000000000..b3c4568e9bb
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/cupswrapperHL5340D-2.0.4.patch.old
@@ -0,0 +1,84 @@
+--- orig/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4	2009-09-10 04:48:37.000000000 +0200
++++ new/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4	2019-07-08 07:22:00.207543000 +0200
+@@ -22,8 +22,7 @@
+   lpadmin -x HL5340D
+   rm -f /usr/share/cups/model/HL5340D.ppd
+   rm -f /usr/lib/cups/filter/brlpdwrapperHL5340D
+-  rm -f /usr/lib64/cups/filter/brlpdwrapperHL5340D
+-  rm -f /usr/local/Brother/cupswrapper/brcupsconfig3
++  rm -f /usr/lib/brother/cupswrapper/brcupsconfig3
+   if [ -f /usr/share/ppd/HL5340D.ppd ];then
+   rm -f /usr/share/ppd/HL5340D.ppd
+   fi
+@@ -54,7 +53,7 @@
+ fi
+ mkdir -p /usr/lib/cups/filter
+ 
+-if [ -e "/usr/local/Brother/lpd/filterHL5340D" ]; then
++if [ -e "/usr/lib/brother/lpd/filterHL5340D" ]; then
+   :
+ else
+   echo "ERROR : Brother LPD filter is not installed."
+@@ -379,13 +378,7 @@
+ fi
+ 
+ brotherlpdwrapper=/usr/lib/cups/filter/brlpdwrapperHL5340D
+-brotherlpdwrapper64=/usr/lib64/cups/filter/brlpdwrapperHL5340D
+ rm -f  $brotherlpdwrapper
+-if [ ! -e /usr/lib/cups/filter ];then
+-  if [ -e /usr/lib64/cups/filter ];then
+-    brotherlpdwrapper=/usr/lib64/cups/filter/brlpdwrapperHL5340D
+-  fi
+-fi
+ 
+ 
+ cat <<!ENDOFWFILTER! >$brotherlpdwrapper
+@@ -517,25 +510,25 @@
+ fi
+ 
+ 
+-if [ -e "/usr/local/Brother/lpd/filter\$PRINTER" ]; then
++if [ -e "/usr/lib/brother/lpd/filter\$PRINTER" ]; then
+        :
+ else
+-    echo "ERROR: /usr/local/Brother/lpd/filter\$PRINTER does not exist"   >>\$LOGFILE
++    echo "ERROR: /usr/lib/brother/lpd/filter\$PRINTER does not exist"   >>\$LOGFILE
+     errorcode=30
+     exit $errorcode
+ fi
+ 
+-if [ -e "/usr/local/Brother/cupswrapper/brcupsconfig3" ]; then
++if [ -e "/usr/lib/brother/cupswrapper/brcupsconfig3" ]; then
+   if [ \$DEBUG = 0 ]; then
+-     /usr/local/Brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD 0 "\$options" >> /dev/null
++     /usr/lib/brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD 0 "\$options" >> /dev/null
+   else
+-     /usr/local/Brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD \$LOGCLEVEL "\$options" >>\$LOGFILE
++     /usr/lib/brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD \$LOGCLEVEL "\$options" >>\$LOGFILE
+   fi
+ fi
+ 
+ 
+ if [ \$DEBUG -le 2 ]; then
+-    cat    \$INPUT_TEMP_PS | /usr/local/Brother/lpd/filter\$PRINTER
++    cat    \$INPUT_TEMP_PS | /usr/lib/brother/lpd/filter\$PRINTER
+ fi
+ 
+ if [ \$DEBUG -ge 2 ];  then
+@@ -553,14 +546,9 @@
+ 
+ 
+ chmod 755 $brotherlpdwrapper
+-if [ -e /usr/lib/cups/filter ]; then
+- if [ -e /usr/lib64/cups/filter ]; then
+-   cp $brotherlpdwrapper  $brotherlpdwrapper64
+- fi
+-fi
+ 
+-chmod a+w /usr/local/Brother/inf/brHL5340Drc
+-chmod a+w /usr/local/Brother/inf
++chmod a+w /usr/lib/brother/inf/brHL5340Drc
++chmod a+w /usr/lib/brother/inf
+ if [ -e /etc/init.d/lpd ]; then
+    /etc/init.d/lpd stop
+ fi
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/files/LICENSE b/srcpkgs/brother-hl5340d-cupswrapper/files/LICENSE
new file mode 100644
index 00000000000..a3d7fdf8754
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/files/LICENSE
@@ -0,0 +1,9 @@
+License Agreement
+
+This Agreement provides terms and conditions for license grant from Brother Industries, Ltd ("Brother"). Brother, who owns all copyrights to the software that is distributed with this Agreement ("Software") to recipients thereof ("User"), for use of the Software. User shall have the right to use the Software only in accordance with the terms and conditions of this Agreement. Any use by User of the Software shall be deemed as its agreement hereto.
+
+Brother retains any and all copyrights to the Software. In no case this Agreement shall be construed to assign or otherwise transfer from Brother to User any copyrights or other intellectual property rights to whole or any part of the Software.
+
+Brother grants User a non-exclusive license: to reproduce and/or distribute (via Internet or in any other manner) the Software. Further, Brother grants User a non-exclusive license to modify, alter, translate or otherwise prepare derivative works of the Software and to reproduce and distribute (via Internet or in any other manner) such modification, alteration, translation or other derivative works for any purpose.
+
+The license of the Software from Brother hereunder is granted "AS IS." BROTHER HEREBY DISCLAIMS ANY WARRANTIES WITH RESPECT TO THE SOFTWARE, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO WARRANTY FOR THE QUALITY, MERCHANTABILITY, FITNESS FOR PARTICULAR PURPOSE OR NON-INFRINGEMENT. Brother shall have no liability in contract, tort (including negligence or breach of statutory duty) or otherwise for any interruption of use, loss of data, or for any indirect, incidental, punitive or consequential loss or damage, or for any loss of profit, revenue, data, goodwill or anticipated savings that arises under, out of, or in contemplation of this Agreement or otherwise arises due to any error, inaccuracy or defect in the Software even if Brother has been advised of the possibility of such loss or damage. Further, Brother shall have no liability to disclose and/or distribute the source code of the Software to User under any circumstances. In no case shall the above license by Brother to modify, alter, translate or otherwise prepare derivative works of the Software be construed as Brother's implied agreement or undertakings to disclose and/or distribute the source code of the Software. 
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch b/srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch
new file mode 100644
index 00000000000..73611570465
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/patches/cupswrapperHL5340D.patch
@@ -0,0 +1,125 @@
+diff -ur orig/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4 new/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4
+--- orig/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4	2009-09-10 04:48:37.000000000 +0200
++++ new/usr/local/Brother/cupswrapper/cupswrapperHL5340D-2.0.4	2019-07-09 10:08:23.763781987 +0200
+@@ -22,8 +22,7 @@
+   lpadmin -x HL5340D
+   rm -f /usr/share/cups/model/HL5340D.ppd
+   rm -f /usr/lib/cups/filter/brlpdwrapperHL5340D
+-  rm -f /usr/lib64/cups/filter/brlpdwrapperHL5340D
+-  rm -f /usr/local/Brother/cupswrapper/brcupsconfig3
++  rm -f /usr/lib/brother/cupswrapper/brcupsconfig3
+   if [ -f /usr/share/ppd/HL5340D.ppd ];then
+   rm -f /usr/share/ppd/HL5340D.ppd
+   fi
+@@ -38,11 +37,14 @@
+ if [ "$1" = "-r" ]; then
+   lpadmin -x HL5340D
+   if [ -e /etc/init.d/cups ]; then
+-    /etc/init.d/cups restart
++    sv restart cupsd restart
+   fi
+   if [ -e /etc/init.d/cupsys ]; then
+     /etc/init.d/cupsys restart
+   fi
++  if [ -e /usr/bin/sv -a -e /var/service/cupsd/run ]; then
++    /usr/bin/sv restart cupsd
++  fi
+   exit 0 
+ fi
+ if [ "$1" = "help" ] || [ "$1" = "-h" ]; then
+@@ -54,15 +56,18 @@
+ fi
+ mkdir -p /usr/lib/cups/filter
+ 
+-if [ -e "/usr/local/Brother/lpd/filterHL5340D" ]; then
++if [ -e "/usr/lib/brother/lpd/filterHL5340D" ]; then
+   :
+ else
+   echo "ERROR : Brother LPD filter is not installed."
+ fi
+ rm -f /usr/share/cups/model/HL5340D.ppd
+ ppd_file_name=/usr/share/cups/model/HL5340D.ppd
++#if [ ! -e /usr/share/cups/model ]; then
++#   ppd_file_name=/usr/share/ppd/HL5340D.ppd
++#fi
+ if [ ! -e /usr/share/cups/model ]; then
+-   ppd_file_name=/usr/share/ppd/HL5340D.ppd
++  mkdir -p /usr/share/cups/model
+ fi
+ 
+ cat <<ENDOFPPDFILE >$ppd_file_name
+@@ -372,20 +377,14 @@
+ ENDOFPPDFILE
+ 
+ chmod 755  $ppd_file_name
+-if [ -e '/usr/share/ppd' ];then
+-  if [ -e '/usr/share/cups/model' ];then
+-    cp  $ppd_file_name  /usr/share/ppd
+-  fi
+-fi
++#if [ -e '/usr/share/ppd' ];then
++#  if [ -e '/usr/share/cups/model' ];then
++#    cp  $ppd_file_name  /usr/share/ppd
++#  fi
++#fi
+ 
+ brotherlpdwrapper=/usr/lib/cups/filter/brlpdwrapperHL5340D
+-brotherlpdwrapper64=/usr/lib64/cups/filter/brlpdwrapperHL5340D
+ rm -f  $brotherlpdwrapper
+-if [ ! -e /usr/lib/cups/filter ];then
+-  if [ -e /usr/lib64/cups/filter ];then
+-    brotherlpdwrapper=/usr/lib64/cups/filter/brlpdwrapperHL5340D
+-  fi
+-fi
+ 
+ 
+ cat <<!ENDOFWFILTER! >$brotherlpdwrapper
+@@ -517,25 +516,25 @@
+ fi
+ 
+ 
+-if [ -e "/usr/local/Brother/lpd/filter\$PRINTER" ]; then
++if [ -e "/usr/lib/brother/lpd/filter\$PRINTER" ]; then
+        :
+ else
+-    echo "ERROR: /usr/local/Brother/lpd/filter\$PRINTER does not exist"   >>\$LOGFILE
++    echo "ERROR: /usr/lib/brother/lpd/filter\$PRINTER does not exist"   >>\$LOGFILE
+     errorcode=30
+     exit $errorcode
+ fi
+ 
+-if [ -e "/usr/local/Brother/cupswrapper/brcupsconfig3" ]; then
++if [ -e "/usr/lib/brother/cupswrapper/brcupsconfig3" ]; then
+   if [ \$DEBUG = 0 ]; then
+-     /usr/local/Brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD 0 "\$options" >> /dev/null
++     /usr/lib/brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD 0 "\$options" >> /dev/null
+   else
+-     /usr/local/Brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD \$LOGCLEVEL "\$options" >>\$LOGFILE
++     /usr/lib/brother/cupswrapper/brcupsconfig3  \$PRINTER  \$PPD \$LOGCLEVEL "\$options" >>\$LOGFILE
+   fi
+ fi
+ 
+ 
+ if [ \$DEBUG -le 2 ]; then
+-    cat    \$INPUT_TEMP_PS | /usr/local/Brother/lpd/filter\$PRINTER
++    cat    \$INPUT_TEMP_PS | /usr/lib/brother/lpd/filter\$PRINTER
+ fi
+ 
+ if [ \$DEBUG -ge 2 ];  then
+@@ -553,14 +552,9 @@
+ 
+ 
+ chmod 755 $brotherlpdwrapper
+-if [ -e /usr/lib/cups/filter ]; then
+- if [ -e /usr/lib64/cups/filter ]; then
+-   cp $brotherlpdwrapper  $brotherlpdwrapper64
+- fi
+-fi
+ 
+-chmod a+w /usr/local/Brother/inf/brHL5340Drc
+-chmod a+w /usr/local/Brother/inf
++chmod a+w /usr/lib/brother/inf/brHL5340Drc
++chmod a+w /usr/lib/brother/inf
+ if [ -e /etc/init.d/lpd ]; then
+    /etc/init.d/lpd stop
+ fi
diff --git a/srcpkgs/brother-hl5340d-cupswrapper/template b/srcpkgs/brother-hl5340d-cupswrapper/template
new file mode 100644
index 00000000000..65c97945ff3
--- /dev/null
+++ b/srcpkgs/brother-hl5340d-cupswrapper/template
@@ -0,0 +1,37 @@
+# Template file for 'brother-hl5340d-cupswrapper'
+pkgname=brother-hl5340d-cupswrapper
+_br_version=2.0.4
+_br_revision=1
+version=${_br_version}
+revision=1
+archs="i686 x86_64"
+create_wrksrc=yes
+depends="brother-hl5340d-lpr cups cups-filters"
+short_desc="CUPS wrapper driver for the brother HL5340D printer"
+maintainer="Monkey 7<monkeyseven@fblog.ch>"
+license="brother-eula GPL-2"
+homepage="http://support.brother.com"
+distfiles="http://www.brother.com/pub/bsc/linux/dlf/cupswrapperHL5340D-${version}-${_br_revision}.i386.deb
+	http://www.brother.com/pub/bsc/linux/dlf/BR5340_2_GPL.ppd.gz"
+checksum="a39c39e086904ec79d2ac0a9fe24bf2dd474ccd959adc11ad9d9b0b5d2649320
+ 	e8b8bb0688c2a181c9ebbb597ca7f467513262420bbf9a3c9bc1e2cf6e0bf9ee"
+nopie=yes
+patch_args="-Np1"
+
+do_extract() {
+	ar x ${XBPS_SRCDISTDIR}/${pkgname}-${version}/cupswrapperHL5340D-${version}-${_br_revision}.i386.deb
+	tar xzpvf data.tar.gz -C ${wrksrc}
+	# Brother HL-5340D BR-Script3
+	gunzip -c ${XBPS_SRCDISTDIR}/${pkgname}-${version}/BR5340_2_GPL.ppd.gz >${wrksrc}/BR5340_2_GPL.ppd
+}
+
+do_install() {
+	cp -a ${wrksrc}/usr ${DESTDIR}/
+	vmkdir usr/lib
+	mv ${DESTDIR}/usr/local/Brother ${DESTDIR}/usr/lib/brother
+	rm -rf ${DESTDIR}/usr/local
+	# Brother HL-5340D BR-Script3
+	vmkdir usr/share/cups/model
+	cp ${wrksrc}/BR5340_2_GPL.ppd ${DESTDIR}/usr/share/cups/model/BR5340_2_GPL.ppd
+}
+

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-07-10  6:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-10  5:15 [PR PATCH] New package: brother-hl5340d-cupswrapper-2.0.4 voidlinux-github
2019-07-10  5:28 ` [PR PATCH] [Closed]: " voidlinux-github
2019-07-10  6:00 [PR PATCH] " voidlinux-github

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).