Gentoo Archives: gentoo-commits

From: "Daniel Pielmeier (billie)" <billie@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-print/hplip: hplip-3.12.2-r2.ebuild ChangeLog hplip-3.11.12-r2.ebuild hplip-3.12.2.ebuild
Date: Tue, 28 Feb 2012 17:56:20
Message-Id: 20120228175609.596922004C@flycatcher.gentoo.org
1 billie 12/02/28 17:56:09
2
3 Modified: ChangeLog
4 Added: hplip-3.12.2-r2.ebuild
5 Removed: hplip-3.11.12-r2.ebuild hplip-3.12.2.ebuild
6 Log:
7 Revision bump. Fix bug #406135. Thanks to Martin Mokrejš for the report. Remove old.
8
9 (Portage version: 2.1.10.44/cvs/Linux i686)
10
11 Revision Changes Path
12 1.214 net-print/hplip/ChangeLog
13
14 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-print/hplip/ChangeLog?rev=1.214&view=markup
15 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-print/hplip/ChangeLog?rev=1.214&content-type=text/plain
16 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-print/hplip/ChangeLog?r1=1.213&r2=1.214
17
18 Index: ChangeLog
19 ===================================================================
20 RCS file: /var/cvsroot/gentoo-x86/net-print/hplip/ChangeLog,v
21 retrieving revision 1.213
22 retrieving revision 1.214
23 diff -u -r1.213 -r1.214
24 --- ChangeLog 21 Feb 2012 18:15:23 -0000 1.213
25 +++ ChangeLog 28 Feb 2012 17:56:09 -0000 1.214
26 @@ -1,6 +1,14 @@
27 # ChangeLog for net-print/hplip
28 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
29 -# $Header: /var/cvsroot/gentoo-x86/net-print/hplip/ChangeLog,v 1.213 2012/02/21 18:15:23 billie Exp $
30 +# $Header: /var/cvsroot/gentoo-x86/net-print/hplip/ChangeLog,v 1.214 2012/02/28 17:56:09 billie Exp $
31 +
32 +*hplip-3.12.2-r2 (28 Feb 2012)
33 +
34 + 28 Feb 2012; Daniel Pielmeier <billie@g.o> -hplip-3.11.12-r2.ebuild,
35 + -hplip-3.12.2.ebuild, +hplip-3.12.2-r2.ebuild,
36 + +files/hplip-3.12.2-sane.patch:
37 + Revision bump. Fix bug #406135. Thanks to Martin Mokrejš for the report.
38 + Remove old.
39
40 21 Feb 2012; Daniel Pielmeier <billie@g.o>
41 files/hplip-3.11.12-fast-pp.patch:
42
43
44
45 1.1 net-print/hplip/hplip-3.12.2-r2.ebuild
46
47 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-print/hplip/hplip-3.12.2-r2.ebuild?rev=1.1&view=markup
48 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-print/hplip/hplip-3.12.2-r2.ebuild?rev=1.1&content-type=text/plain
49
50 Index: hplip-3.12.2-r2.ebuild
51 ===================================================================
52 # Copyright 1999-2012 Gentoo Foundation
53 # Distributed under the terms of the GNU General Public License v2
54 # $Header: /var/cvsroot/gentoo-x86/net-print/hplip/hplip-3.12.2-r2.ebuild,v 1.1 2012/02/28 17:56:09 billie Exp $
55
56 EAPI=4
57
58 PYTHON_DEPEND="!minimal? 2"
59 PYTHON_USE_WITH="threads xml"
60 PYTHON_USE_WITH_OPT="!minimal"
61
62 inherit fdo-mime linux-info python autotools
63
64 DESCRIPTION="HP Linux Imaging and Printing. Includes printer, scanner, fax drivers and service tools."
65 HOMEPAGE="http://hplipopensource.com/hplip-web/index.html"
66 SRC_URI="mirror://sourceforge/hplip/${P}.tar.gz"
67
68 LICENSE="GPL-2"
69 SLOT="0"
70 KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86"
71
72 # zeroconf does not work properly with >=cups-1.4.
73 # Thus support for it is also disabled in hplip.
74 IUSE="doc fax +hpcups hpijs kde libnotify minimal parport policykit qt4 scanner snmp static-ppds -acl X"
75
76 REQUIRED_USE="|| ( hpijs hpcups )"
77
78 COMMON_DEPEND="
79 virtual/jpeg
80 hpijs? ( >=net-print/foomatic-filters-3.0.20080507[cups] )
81 acl? ( || ( >=sys-fs/udev-171[acl] >=sys-fs/udev-145[extras] ) )
82 !minimal? (
83 >=net-print/cups-1.4.0
84 virtual/libusb:0
85 scanner? ( >=media-gfx/sane-backends-1.0.19-r1 )
86 fax? ( sys-apps/dbus )
87 snmp? (
88 net-analyzer/net-snmp
89 dev-libs/openssl
90 )
91 )"
92
93 DEPEND="${COMMON_DEPEND}
94 dev-util/pkgconfig"
95
96 RDEPEND="${COMMON_DEPEND}
97 >=app-text/ghostscript-gpl-8.71-r3
98 policykit? (
99 sys-auth/polkit
100 )
101 !minimal? (
102 dev-python/pygobject:2
103 kernel_linux? ( >=sys-fs/udev-114 )
104 scanner? (
105 dev-python/imaging
106 X? ( || (
107 kde? ( kde-misc/skanlite )
108 media-gfx/xsane
109 media-gfx/sane-frontends
110 ) )
111 )
112 fax? (
113 dev-python/reportlab
114 dev-python/dbus-python
115 )
116 qt4? (
117 dev-python/PyQt4[dbus,X]
118 libnotify? (
119 dev-python/notify-python
120 )
121 )
122 )"
123
124 CONFIG_CHECK="~PARPORT ~PPDEV"
125 ERROR_PARPORT="Please make sure kernel parallel port support is enabled (PARPORT and PPDEV)."
126
127 pkg_setup() {
128 if ! use minimal; then
129 python_set_active_version 2
130 python_pkg_setup
131 fi
132
133 ! use qt4 && ewarn "You need USE=qt4 for the hplip GUI."
134
135 use scanner && ! use X && ewarn "You need USE=X for the scanner GUI."
136
137 if use minimal ; then
138 ewarn "Installing driver portions only, make sure you know what you are doing."
139 ewarn "Depending on the USE flags set for hpcups or hpijs the appropiate driver"
140 ewarn "is installed. If both USE flags are set hpijs overrides hpcups."
141 else
142 use parport && linux-info_pkg_setup
143 fi
144 }
145
146 src_prepare() {
147 use !minimal && python_convert_shebangs -q -r 2 .
148
149 # Fix for Gentoo bug #345725
150 sed -i -e "s|/etc/udev/rules.d|/lib/udev/rules.d|" \
151 $(find ./ -type f -exec grep -l '/etc/udev/rules.d' '{}' '+') \
152 || die
153
154 # Do not install desktop files if there is no gui
155 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/452113
156 epatch "${FILESDIR}"/${PN}-3.11.1-desktop.patch
157
158 # Browser detection through xdg-open
159 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/482674
160 epatch "${FILESDIR}"/${PN}-3.9.10-browser.patch
161
162 # Use cups-config when checking for cupsddk
163 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/483136
164 epatch "${FILESDIR}"/${PN}-3.9.12-cupsddk.patch
165
166 # Htmldocs are not installed under docdir/html so enable htmldir configure
167 # switch
168 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/483217
169 epatch "${FILESDIR}"/${PN}-3.11.1-htmldir.patch
170
171 # Let 56-hpmud_support.rules call hp-mkuri to make it work with newer udev
172 # Upstream bug: None
173 epatch "${FILESDIR}"/${PN}-3.11.12-udev-rules.patch
174
175 # CVE-2010-4267 SNMP Response Processing Buffer Overflow Vulnerability
176 # http://secunia.com/advisories/42956/
177 # https://bugzilla.redhat.com/show_bug.cgi?id=662740
178 epatch "${FILESDIR}"/${PN}-3.10.9-cve-2010-4267.patch
179
180 # Fix black stripes on pcl5c printouts
181 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/561264
182 epatch "${FILESDIR}"/${PN}-3.11.12-black-stripes-pcl5c.patch
183
184 # Fix parallel port cpu usage
185 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/750796
186 epatch "${FILESDIR}"/${PN}-3.11.12-fast-pp.patch
187
188 # Fix minmal/hpijs_only/hpcups_only install
189 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/932918
190 epatch "${FILESDIR}"/${P}-minimal.patch
191
192 # Fix Option parsing in sane/scan.py
193 # Upstream bug: https://bugs.launchpad.net/hplip/+bug/927708
194 epatch "${FILESDIR}"/${P}-sane.patch
195
196 # Force recognition of Gentoo distro by hp-check
197 sed -i \
198 -e "s:file('/etc/issue', 'r').read():'Gentoo':" \
199 installer/core_install.py || die
200
201 # Use system foomatic-rip for hpijs driver instead of foomatic-rip-hplip
202 # The hpcups driver does not use foomatic-rip
203 local i
204 for i in ppd/hpijs/*.ppd.gz ; do
205 rm -f ${i}.temp
206 gunzip -c ${i} | sed 's/foomatic-rip-hplip/foomatic-rip/g' | \
207 gzip > ${i}.temp || die
208 mv ${i}.temp ${i}
209 done
210
211 eautoreconf
212 }
213
214 src_configure() {
215 local myconf drv_build minimal_build
216
217 if use fax || use qt4 ; then
218 myconf="${myconf} --enable-dbus-build"
219 else
220 myconf="${myconf} --disable-dbus-build"
221 fi
222
223 if use hpcups ; then
224 drv_build="$(use_enable hpcups hpcups-install)"
225 if use static-ppds ; then
226 drv_build="${drv_build} --enable-cups-ppd-install"
227 drv_build="${drv_build} --disable-cups-drv-install"
228 else
229 drv_build="${drv_build} --enable-cups-drv-install"
230 drv_build="${drv_build} --disable-cups-ppd-install"
231 fi
232 else
233 drv_build="--disable-hpcups-install"
234 drv_build="${drv_build} --disable-cups-drv-install"
235 drv_build="${drv_build} --disable-cups-ppd-install"
236 fi
237
238 if use hpijs ; then
239 drv_build="${drv_build} $(use_enable hpijs hpijs-install)"
240 if use static-ppds ; then
241 drv_build="${drv_build} --enable-foomatic-ppd-install"
242 drv_build="${drv_build} --disable-foomatic-drv-install"
243 else
244 drv_build="${drv_build} --enable-foomatic-drv-install"
245 drv_build="${drv_build} --disable-foomatic-ppd-install"
246 fi
247 else
248 drv_build="${drv_build} --disable-hpijs-install"
249 drv_build="${drv_build} --disable-foomatic-drv-install"
250 drv_build="${drv_build} --disable-foomatic-ppd-install"
251 fi
252
253 if use minimal ; then
254 if use hpijs ; then
255 minimal_build="--enable-hpijs-only-build"
256 else
257 minimal_build="--disable-hpijs-only-build"
258 fi
259 if use hpcups ; then
260 minimal_build="${minimal_build} --enable-hpcups-only-build"
261 else
262 minimal_build="${minimal_build} --disable-hpcups-only-build"
263 fi
264 fi
265
266 econf \
267 --disable-cups11-build \
268 --disable-lite-build \
269 --disable-foomatic-rip-hplip-install \
270 --disable-shadow-build \
271 --disable-qt3 \
272 --with-cupsbackenddir=$(cups-config --serverbin)/backend \
273 --with-cupsfilterdir=$(cups-config --serverbin)/filter \
274 --with-docdir=/usr/share/doc/${PF} \
275 --with-htmldir=/usr/share/doc/${PF}/html \
276 ${myconf} \
277 ${drv_build} \
278 ${minimal_build} \
279 $(use_enable doc doc-build) \
280 $(use_enable fax fax-build) \
281 $(use_enable parport pp-build) \
282 $(use_enable scanner scan-build) \
283 $(use_enable snmp network-build) \
284 $(use_enable acl udev-acl-rules) \
285 $(use_enable qt4 gui-build) \
286 $(use_enable qt4) \
287 $(use_enable policykit)
288 }
289
290 src_install() {
291 default
292
293 # Installed by sane-backends
294 # Gentoo Bug: #201023
295 rm -f "${D}"/etc/sane.d/dll.conf || die
296
297 rm -f "${D}"/usr/share/doc/${PF}/{copyright,README_LIBJPG,COPYING} || die
298 rmdir --ignore-fail-on-non-empty "${D}"/usr/share/doc/${PF}/ || die
299
300 # Remove hal fdi files
301 rm -rf "${D}"/usr/share/hal || die
302
303 find "${D}" -name '*.la' -exec rm -rf '{}' '+' || die
304 }
305
306 pkg_postinst() {
307 use !minimal && python_mod_optimize /usr/share/${PN}
308 fdo-mime_desktop_database_update
309
310 elog "For more information on setting up your printer please take"
311 elog "a look at the hplip section of the gentoo printing guide:"
312 elog "http://www.gentoo.org/doc/en/printing-howto.xml"
313 }
314
315 pkg_postrm() {
316 use !minimal && python_mod_cleanup /usr/share/${PN}
317 fdo-mime_desktop_database_update
318 }