commit: add3a3d60a9ff540029c4c82b4655c74bd87857f Author: Ulrich Müller <ulm <AT> gentoo <DOT> org> AuthorDate: Sun Dec 9 09:40:06 2018 +0000 Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org> CommitDate: Sun Dec 9 09:41:24 2018 +0000 URL: https://gitweb.gentoo.org/repo/dev/ulm.git/commit/?id=add3a3d6
net-print/brother-dcpj572dw: Initial import. Ebuild contributed by me. Package-Manager: Portage-2.3.52, Repoman-2.3.12 Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org> net-print/brother-dcpj572dw/Manifest | 1 + .../brother-dcpj572dw-20180807.ebuild | 59 ++++++++++++++++++++++ net-print/brother-dcpj572dw/metadata.xml | 10 ++++ 3 files changed, 70 insertions(+) diff --git a/net-print/brother-dcpj572dw/Manifest b/net-print/brother-dcpj572dw/Manifest new file mode 100644 index 0000000..fd3b37a --- /dev/null +++ b/net-print/brother-dcpj572dw/Manifest @@ -0,0 +1 @@ +DIST dcpj572dwpdrv-1.0.5-0.i386.rpm 3511958 BLAKE2B 77b7fc64deb7ed10969ede63e2c3058047e21e01f2f4e4245ffa94f30feebc16af544ec434c7586d2f703dcf72552da985f579da4e2d9287cbfe2e1ecdca5e17 SHA512 fd04623b798c1a4260e1f64e52ebc54e5db384afc20d5983e39e46551d4534d1770316ff7ca541ff5ac150cf56386b2ef4f84ced6fbbc6f88d7272fff8e1fc69 diff --git a/net-print/brother-dcpj572dw/brother-dcpj572dw-20180807.ebuild b/net-print/brother-dcpj572dw/brother-dcpj572dw-20180807.ebuild new file mode 100644 index 0000000..6e8f6ea --- /dev/null +++ b/net-print/brother-dcpj572dw/brother-dcpj572dw-20180807.ebuild @@ -0,0 +1,59 @@ +# Copyright 1999-2018 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit rpm + +MODEL="${PN#*-}" +PV_LPR="1.0.5-0" + +DESCRIPTION="Brother printer driver for DCP-J572DW" +HOMEPAGE="http://www.brother.com/" +SRC_URI="https://download.brother.com/welcome/dlf103778/${MODEL}pdrv-${PV_LPR}.i386.rpm" + +LICENSE="GPL-2+ Brother-lpr no-source-code" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="metric" +RESTRICT="strip" + +RDEPEND="net-print/cups" + +S="${WORKDIR}/opt/brother/Printers/${MODEL}" + +src_prepare() { + eapply_user + if use metric; then + sed -i "/^PaperType/s/Letter/A4/" inf/br${MODEL}rc || die + fi +} + +src_install() { + local dest=/opt/brother/Printers/${MODEL} + + cd "${S}"/lpd || die + exeinto ${dest}/lpd + doexe br${MODEL}filter filter_${MODEL} + dosym ../../../..${dest}/lpd/filter_${MODEL} \ + /usr/libexec/cups/filter/brother_lpdwrapper_${MODEL} + + cd "${S}"/inf || die + insinto ${dest}/inf + doins br${MODEL}func ImagingArea PaperDimension paperinfij2 + doins -r lut + insinto /etc${dest}/inf + doins br${MODEL}rc # config file + dosym ../../../../../etc${dest}/inf/br${MODEL}rc ${dest}/inf/br${MODEL}rc + + cd "${S}"/cupswrapper || die + insinto ${dest}/cupswrapper + doins brother_${MODEL}_printer_en.ppd + dosym ../../../../..${dest}/cupswrapper/brother_${MODEL}_printer_en.ppd \ + /usr/share/cups/model/Brother/brother_${MODEL}_printer_en.ppd + + # The brprintconf utility is very broken and mangles the path + # of the function list file. Therefore, don't install it. + #exeinto ${dest}/bin + #doexe "${WORKDIR}"/usr/bin/brprintconf_${MODEL} +} diff --git a/net-print/brother-dcpj572dw/metadata.xml b/net-print/brother-dcpj572dw/metadata.xml new file mode 100644 index 0000000..9a3c73e --- /dev/null +++ b/net-print/brother-dcpj572dw/metadata.xml @@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer type="person"> + <email>u...@gentoo.org</email> +</maintainer> +<use> + <flag name='metric'>Default to A4 paper size</flag> +</use> +</pkgmetadata>