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