diff options
author | andy <andy@ndyk.de> | 2016-01-10 17:56:09 +0100 |
---|---|---|
committer | andy <andy@ndyk.de> | 2016-01-10 17:56:09 +0100 |
commit | 745b38aa557685109789024535721f4651f2a3ea (patch) | |
tree | 8d6a4f9666033f6a691f8ec136627302fe5a5c1d /net-print/brother-mfcj480dw/brother-mfcj480dw-20150110.ebuild | |
parent | fixed manifest (diff) | |
download | andy-745b38aa557685109789024535721f4651f2a3ea.tar.gz andy-745b38aa557685109789024535721f4651f2a3ea.tar.bz2 andy-745b38aa557685109789024535721f4651f2a3ea.zip |
added brother mfcj480dw ebuild
Diffstat (limited to 'net-print/brother-mfcj480dw/brother-mfcj480dw-20150110.ebuild')
-rw-r--r-- | net-print/brother-mfcj480dw/brother-mfcj480dw-20150110.ebuild | 78 |
1 files changed, 78 insertions, 0 deletions
diff --git a/net-print/brother-mfcj480dw/brother-mfcj480dw-20150110.ebuild b/net-print/brother-mfcj480dw/brother-mfcj480dw-20150110.ebuild new file mode 100644 index 0000000..8379b05 --- /dev/null +++ b/net-print/brother-mfcj480dw/brother-mfcj480dw-20150110.ebuild @@ -0,0 +1,78 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ +EAPI=5 + +inherit rpm multilib + +MODEL="${PN#*-}" +PV_LPR="1.0.0-0" +PV_CUPSWRAPPER="1.0.0-0" + +DESCRIPTION="Brother MFC-J480DW LPR+cupswrapper drivers" +HOMEPAGE="http://support.brother.com/g/b/downloadtop.aspx?c=us&lang=en&prod=mfcj480dw_us_eu_as" +SRC_URI="http://download.brother.com/welcome/dlf102091/${MODEL}lpr-${PV_LPR}.i386.rpm + http://download.brother.com/welcome/dlf102092/${MODEL}cupswrapper-${PV_CUPSWRAPPER}.i386.rpm" + +LICENSE="GPL-2+ Brother-lpr no-source-code" +SLOT="0" +KEYWORDS="~x86 ~amd64" +IUSE="metric" +RESTRICT="strip" + +DEPEND="net-print/cups" +RDEPEND="${DEPEND}" + +S="${WORKDIR}/opt/brother/Printers/${MODEL}" + +src_unpack() { + rpm_unpack ${A} +} + +src_prepare() { + if use metric; then + sed -i "/^PaperType/s/Letter/A4/" inf/br${MODEL}rc || die + fi +} + +src_install() { + has_multilib_profile && ABI=x86 + + local dest=/opt/brother/Printers/${MODEL} + cd "${S}"/lpd || die + exeinto ${dest}/lpd + doexe br${MODEL}filter filter${MODEL} psconvertij2 + + 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} +} + +pkg_postinst () { + elog "You may use brprintconf_${MODEL} to change printer options" + elog + elog "Set 'Fast Normal' quality:" + elog " ${dest}/bin/brprintconf_${MODEL} -reso 300x300dpi" + elog + elog "For more options just execute brprintconf_${MODEL} as root" + elog "You can check current settings in:" + elog " /opt/brother/Printers/${MODEL}/inf/br${MODEL}rc" +} |