Summary: HP Linux Imaging and Printing Project Name: hplip Version: 1.7.4a Release: 1%{?dist} License: GPL/MIT/BSD Group: System Environment/Daemons Conflicts: system-config-printer < 0.6.132 Obsoletes: hpoj <= 0.91 Obsoletes: xojpanel <= 0.91 # Need selinux-policy to know about new port numbers (bug #201357). Conflicts: selinux-policy < 2.4.6-52 Url: http://hplip.sourceforge.net/ Source: http://kent.dl.sourceforge.net/sourceforge/hplip/%{name}-%{version}.tar.gz Patch1: hplip-desktop.patch Patch2: hplip-guest.patch Patch3: hplip-quiet.patch Patch4: hplip-cups-backend.patch Patch5: hplip-libm.patch Patch6: hplip-ipv6.patch Patch8: hplip-libsane.patch Patch9: hplip-media-empty.patch Patch11: hplip-unload-traceback.patch Patch12: hplip-no-root-config.patch Patch13: hplip-ui-optional.patch BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot Requires(post): /sbin/service Requires(post): /sbin/chkconfig Requires(preun): /sbin/service Requires(preun): /sbin/chkconfig %define hpijs_epoch 1 Requires: hpijs = %{hpijs_epoch}:%{version}-%{release} BuildRequires: net-snmp-devel BuildRequires: cups-devel BuildRequires: python-devel BuildRequires: libjpeg-devel BuildRequires: desktop-file-utils BuildRequires: libusb-devel BuildRequires: autoconf BuildRequires: sane-backends-devel %description The Hewlett-Packard Linux Imaging and Printing Project provides drivers for HP printers and multi-function peripherals. %package gui Summary: HPLIP graphical tools Group: Applications/System License: BSD Requires: PyQt Requires(post): desktop-file-utils >= 0.2.92 Requires(postun): desktop-file-utils >= 0.2.92 Requires: %{name} = %{version}-%{release} %description gui HPLIP graphical tools. %package -n hpijs Summary: HP Printer Drivers Group: Applications/Publishing License: BSD Epoch: %{hpijs_epoch} %description -n hpijs hpijs is a collection of optimized drivers for HP printers. hpijs supports the DeskJet 350C, 600C, 600C Photo, 630C, Apollo 2000, Apollo 2100, Apollo 2560, DeskJet 800C, DeskJet 825, DeskJet 900, PhotoSmart, DeskJet 990C, and PhotoSmart 100 series. %package -n libsane-hpaio Summary: SANE driver for scanners in HP's multi-function devices Group: System Environment/Daemons License: GPL Obsoletes: libsane-hpoj <= 0.91 Requires: sane-backends ExcludeArch: s390 s390x %description -n libsane-hpaio SANE driver for scanners in HP's multi-function devices (from HPOJ). %prep rm -rf $RPM_BUILD_DIR/%{name}-%{version} %setup -q # Use /usr/share/applications for putting desktop files in. %patch1 -p1 -b .desktop # Quieten hpssd on startup. %patch3 -p1 -b .quiet # Always use /usr/lib/cups/backend. %patch4 -p1 -b .cups-backend # libhpip should link against libm (bug #197599). %patch5 -p1 -b .libm # IPv6 support (bug #198377). %patch6 -p1 -b .ipv6 # Link libsane-hpaio against libsane (bug #234813). %patch8 -p1 -b .libsane # Clear the media-empty-error printer state. %patch9 -p1 -b .media-empty # Prevent a traceback when unloading a photo card (bug #238617). %patch11 -p1 -b .unload-traceback # Prevent SELinux audit message from the CUPS backends (bug #241776) %patch12 -p1 -b .no-root-config # Make utils.checkPyQtImport() look for the gui sub-package (bug #243273). %patch13 -p1 -b .ui-optional autoconf # for patch4 %build %configure --disable-foomatic-install --disable-cups-install make hpppddir=%{_datadir}/foomatic/db/source/PPD/HP %install rm -rf %{buildroot} mkdir -p %{buildroot}%{_bindir} make install DESTDIR=%{buildroot} \ hpppddir=%{_datadir}/foomatic/db/source/PPD/HP # Move SANE backend into correct directory mkdir -p %{buildroot}%{_libdir}/sane mv %{buildroot}%{_libdir}/libsane-*.so* %{buildroot}%{_libdir}/sane # Remove unpackaged files rm -rf %{buildroot}%{_sysconfdir}/sane.d \ %{buildroot}%{_docdir} rm -f %{buildroot}%{_bindir}/foomatic-rip \ %{buildroot}%{_libdir}/cups/filter/foomatic-rip \ %{buildroot}%{_libdir}/*.la \ %{buildroot}%{_libdir}/*.so \ %{buildroot}%{_datadir}/cups/model/foomatic-ppds \ %{buildroot}%{_datadir}/applications/hplip.desktop mkdir -p %{buildroot}%{_datadir}/applications echo 'NoDisplay=true' >> %{buildroot}%{_datadir}/hplip/data/hplip.desktop sed -i -e '/^Categories=/d' %{buildroot}%{_datadir}/hplip/data/hplip.desktop desktop-file-install --vendor HP \ --dir %{buildroot}%{_datadir}/applications \ --add-category X-Red-Hat-Extra \ --add-category System \ --add-category Application \ %{buildroot}%{_datadir}/hplip/data/hplip.desktop # Move initscript mkdir -p %{buildroot}%{_sysconfdir}/rc.d/init.d mv %{buildroot}%{_sysconfdir}/{init.d,rc.d/init.d}/hplip # Remove files we don't want to package. rm -f %{buildroot}%{_datadir}/hplip/COPYING rm -f %{buildroot}%{_datadir}/hplip/hplip rm -f %{buildroot}%{_datadir}/hplip/hplip.conf rm -f %{buildroot}%{_datadir}/hplip/hplip_overview.png rm -f %{buildroot}%{_datadir}/hplip/hplip_readme.html rm -f %{buildroot}%{_datadir}/hplip/hplip.sh rm -f %{buildroot}%{_datadir}/hplip/data/hplip.desktop rm -f %{buildroot}%{_bindir}/hp-check rm -f %{buildroot}%{_datadir}/hplip/check rm -f %{buildroot}%{_datadir}/hplip/hplip-install rm -rf %{buildroot}%{_datadir}/hplip/install* rm -f %{buildroot}%{_datadir}/hplip/hpaio.desc rm -rf %{buildroot}%{_datadir}/hplip/fax/ppd rm -rf %{buildroot}%{_datadir}/hplip/fax/backend %clean rm -rf %{buildroot} %files %defattr(-,root,root) %doc COPYING doc/* %dir %{_sysconfdir}/hp %config(noreplace) %{_sysconfdir}/hp/hplip.conf %config(noreplace) %{_sysconfdir}/rc.d/init.d/hplip %{_bindir}/hp-align %{_bindir}/hp-clean %{_bindir}/hp-colorcal %{_bindir}/hp-fab %{_bindir}/hp-firmware %{_bindir}/hp-info %{_bindir}/hp-levels %{_bindir}/hp-makecopies %{_bindir}/hp-makeuri %{_bindir}/hp-probe %{_bindir}/hp-sendfax %{_bindir}/hp-setup %{_bindir}/hp-testpage %{_bindir}/hp-timedate %{_bindir}/hp-unload %{_sbindir}/hpiod # Note: this must be /usr/lib not %{_libdir}, since that's the # CUPS serverbin directory. /usr/lib/cups/backend/hp /usr/lib/cups/backend/hpfax %{_libdir}/python*/site-packages/* %dir %{_datadir}/hplip # Files %{_datadir}/hplip/align %{_datadir}/hplip/clean %{_datadir}/hplip/colorcal %{_datadir}/hplip/fab %{_datadir}/hplip/fax %{_datadir}/hplip/firmware %{_datadir}/hplip/hpssd* %{_datadir}/hplip/info %{_datadir}/hplip/__init__* %{_datadir}/hplip/levels %{_datadir}/hplip/makecopies %{_datadir}/hplip/makeuri %{_datadir}/hplip/probe %{_datadir}/hplip/sendfax %{_datadir}/hplip/setup %{_datadir}/hplip/testpage %{_datadir}/hplip/timedate %{_datadir}/hplip/unload # Directories %{_datadir}/hplip/base %{_datadir}/hplip/copier %dir %{_datadir}/hplip/data %{_datadir}/hplip/data/firmware %{_datadir}/hplip/data/ldl %{_datadir}/hplip/data/models %{_datadir}/hplip/data/pcl %{_datadir}/hplip/data/ps %{_datadir}/hplip/pcard %{_datadir}/hplip/prnt %{_datadir}/hplip/scan %files gui %{_bindir}/hp-print %{_bindir}/hp-toolbox # Files %{_datadir}/hplip/data/images %{_datadir}/hplip/print %{_datadir}/hplip/toolbox # Directories %{_datadir}/hplip/ui %{_datadir}/hplip/plugins %{_datadir}/applications/*.desktop %files -n hpijs %defattr(-,root,root) %doc prnt/hpijs/COPYING %{_libdir}/libhpip.so* %{_bindir}/hpijs %{_datadir}/foomatic/db/source/PPD/HP #%{_bindir}/hppgsz %files -n libsane-hpaio %defattr(-,root,root) %{_libdir}/sane/libsane-*.so* %post /sbin/chkconfig --add hplip || : if [ "$1" -ge "1" ]; then /sbin/service hplip condrestart >/dev/null 2>&1 || : fi exit 0 %preun if [ "$1" == "0" ]; then /sbin/service hplip stop >/dev/null 2>&1 || : /sbin/chkconfig --del hplip fi exit 0 %post gui /usr/bin/update-desktop-database &>/dev/null ||: %postun gui /usr/bin/update-desktop-database &>/dev/null ||: %post -n libsane-hpaio /sbin/ldconfig if [ -f /etc/sane.d/dll.conf ] && \ ! grep ^hpaio /etc/sane.d/dll.conf >/dev/null 2>/dev/null ; then \ echo hpaio >> /etc/sane.d/dll.conf; \ fi exit 0 %changelog * Wed Jun 13 2007 Tim Waugh 1.7.4a-1 - 1.7.4a. No longer need marker-supply or faxing-with-low-supplies patches. Cheetah and cherrypy directories no longer shipped in source tarball. * Mon Jun 11 2007 Tim Waugh - Don't ship hp-check (bug #243273). - Moved hp-setup back to the base package, and put code in utils.checkPyQtImport() to check for the gui sub-package as well as PyQt (bug #243273). * Fri Jun 8 2007 Tim Waugh - Moved hp-setup to the ui package (bug #243273). - Prevent SELinux audit message from the CUPS backends (bug #241776) * Thu May 10 2007 Tim Waugh 1.7.2-10 - Prevent a traceback when unloading a photo card (bug #238617). * Fri May 4 2007 Tim Waugh 1.7.2-9 - When faxing, low ink/paper is not a problem (bug #238664). * Tue Apr 17 2007 Tim Waugh 1.7.2-8 - Update desktop database on %%postun as well (bug #236163). * Mon Apr 16 2007 Tim Waugh 1.7.2-7 - Some parts can run without GUI support after all (bug #236161). - Added /sbin/service and /sbin/chkconfig requirements for the scriptlets (bug #236445). - Fixed %%post scriptlet's condrestart logic (bug #236445). * Fri Apr 13 2007 Tim Waugh 1.7.2-6 - Fixed dangling symlinks (bug #236156). - Move all fax bits to the gui package (bug #236161). - Don't ship fax PPD and backend twice (bug #236092). - Run update-desktop-database in the gui package's %%post scriptlet (bug #236163). - Moved desktop-file-utils requirement to gui package (bug #236163). - Bumped selinux-policy conflict version (bug #236092). * Thu Apr 5 2007 Tim Waugh 1.7.2-5 - Better media-empty-error state handling: always set the state. * Wed Apr 4 2007 Tim Waugh 1.7.2-4 - Clear the media-empty-error printer state. * Wed Apr 4 2007 Tim Waugh 1.7.2-3 - Fixed typo in marker-supply-low patch. * Wed Apr 4 2007 Tim Waugh 1.7.2-2 - Split out a gui sub-package (bug #193661). - Build requires sane-backends-devel (bug #234813). * Tue Apr 3 2007 Tim Waugh - Change 'Hidden' to 'NoDisplay' in the desktop file, and use the System category instead of Utility (bug #170762). - Link libsane-hpaio against libsane (bug #234813). * Fri Mar 30 2007 Tim Waugh - Use marker-supply-low IPP message. * Wed Mar 1 2007 Tim Waugh 1.7.2-1 - 1.7.2. * Wed Feb 14 2007 Tim Waugh 1.7.1-1 - 1.7.1. * Wed Jan 10 2007 Tim Waugh 1.6.12-1 - 1.6.12. No longer need broken-conf, loop, out-of-paper or sane-debug patches. * Thu Dec 7 2006 Jeremy Katz - 1.6.10-7 - rebuild against python 2.5 * Wed Dec 6 2006 Tim Waugh - Minor state fixes for out-of-paper patch. * Thu Nov 23 2006 Tim Waugh 1.6.10-6 - Report out-of-paper and offline conditions in CUPS backend (bug #216477). * Wed Nov 1 2006 Tim Waugh 1.6.10-5 - Fixed debugging patch. * Wed Nov 1 2006 Tim Waugh 1.6.10-4 - Allow debugging of the SANE backend. * Mon Oct 30 2006 Tim Waugh 1.6.10-3 - IPv6 support (bug #198377). Local-only sockets are IPv4, and ought to be changed to unix domain sockets in future. * Fri Oct 27 2006 Tim Waugh 1.6.10-2 - 1.6.10. No longer need compile patch. - Fixed default config file (bug #211072). - Moved libhpip to hpijs sub-package (bug #212531). * Fri Sep 29 2006 Tim Waugh 1.6.7-4 - Don't wake up every half a second (bug #204725). * Mon Sep 25 2006 Tim Waugh - Fixed package URL. * Mon Aug 21 2006 Tim Waugh 1.6.7-3 - Don't look up username in PWDB in the fax backend (removed redundant code). * Mon Aug 7 2006 Tim Waugh 1.6.7-2 - 1.6.7. - Conflict with selinux-policy < 2.3.4 to make sure new port numbers are known about (bug #201357). * Wed Jul 12 2006 Jesse Keating - (none):1.6.6a-3.1 - rebuild * Tue Jul 4 2006 Tim Waugh 1.6.6a-3 - libhpip should link against libm (bug #197599). * Wed Jun 28 2006 Tim Waugh 1.6.6a-2 - 1.6.6a. * Mon Jun 26 2006 Tim Waugh - Patchlevel 1. - Fixed libsane-hpaio %%post scriptlet (bug #196663). * Fri Jun 16 2006 Tim Waugh 1.6.6-2 - 1.6.6. * Mon Jun 12 2006 Tim Waugh 0.9.11-6 - Build requires autoconf (bug #194682). * Fri May 26 2006 Tim Waugh 0.9.11-5 - Include doc files (bug #192790). * Mon May 15 2006 Tim Waugh 0.9.11-4 - Patchlevel 2. * Wed May 10 2006 Tim Waugh 0.9.11-3 - Move hpijs to 0.9.11 too. * Wed May 10 2006 Tim Waugh 0.9.11-2 - 0.9.11. - Keep hpijs at 0.9.8 for now. * Fri Apr 21 2006 Tim Waugh 0.9.10-6 - Patchlevel 2. * Wed Apr 19 2006 Tim Waugh - Don't package COPYING twice (bug #189162). * Tue Apr 18 2006 Tim Waugh 0.9.10-5 - Patchlevel 1. - Fixed another case-sensitive match. - Require hpijs sub-package (bug #189140). - Don't package unneeded files (bug #189162). - Put fax PPD in the right place (bug #186213). * Tue Apr 4 2006 Tim Waugh 0.9.10-4 - Use case-insensitive matching. 0.9.8 gave all-uppercase in some situations. - Last known working hpijs comes from 0.9.8, so use that. * Tue Mar 28 2006 Tim Waugh 0.9.10-3 - Always use /usr/lib/cups/backend. * Tue Mar 28 2006 Tim Waugh 0.9.10-2 - 0.9.10. - Ship PPDs. * Fri Mar 24 2006 Tim Waugh 0.9.9-7 - Include hpfax. - Build requires libusb-devel. * Thu Mar 23 2006 Tim Waugh 0.9.9-6 - CUPS backend directory is always in /usr/lib. * Mon Mar 13 2006 Tim Waugh 0.9.9-4 - Quieten hpssd on startup. * Sat Mar 11 2006 Tim Waugh 0.9.9-3 - Patchlevel 1. * Thu Mar 9 2006 Tim Waugh 0.9.9-2 - 0.9.9. No longer need quiet or 0.9.8-4 patches. * Wed Mar 01 2006 Karsten Hopp 0.9.8-6 - Buildrequires: desktop-file-utils * Mon Feb 27 2006 Tim Waugh 0.9.8-5 - Patchlevel 4. * Tue Feb 14 2006 Tim Waugh 0.9.8-4 - Added Obsoletes: hpoj tags back in (bug #181476). * Fri Feb 10 2006 Jesse Keating - (none):0.9.8-3.1 - bump again for double-long bug on ppc(64) * Tue Feb 7 2006 Tim Waugh 0.9.8-3 - Patchlevel 3. * Fri Feb 3 2006 Tim Waugh 0.9.8-2 - Patchlevel 2. * Thu Feb 2 2006 Tim Waugh 0.9.8-1 - 0.9.8. - No longer need initscript patch. - Don't package hpfax yet. * Wed Jan 18 2006 Tim Waugh 0.9.7-8 - Don't package PPD files. * Thu Jan 5 2006 Tim Waugh 0.9.7-7 - Fix initscript (bug #176966). * Mon Jan 2 2006 Tim Waugh 0.9.7-6 - Rebuild. * Fri Dec 23 2005 Tim Waugh 0.9.7-5 - Rebuild. * Wed Dec 21 2005 Tim Waugh 0.9.7-4 - Build requires python-devel, libjpeg-devel (bug #176317). * Fri Dec 09 2005 Jesse Keating - rebuilt * Wed Dec 7 2005 Tim Waugh 0.9.7-3 - Use upstream patch 0.9.7-2. - No longer need lpgetstatus or compile patches. * Fri Nov 25 2005 Tim Waugh 0.9.7-2 - Prevent LPGETSTATUS overrunning format buffer. * Thu Nov 24 2005 Tim Waugh 0.9.7-1 - 0.9.7. * Fri Nov 18 2005 Tim Waugh 0.9.6-7 - Fix compilation. * Wed Nov 9 2005 Tomas Mraz 0.9.6-6 - rebuilt against new openssl * Mon Nov 7 2005 Tim Waugh 0.9.6-5 - Rebuilt. * Wed Oct 26 2005 Tim Waugh 0.9.6-4 - Ship initscript in %%{_sysconfdir}/rc.d/init.d. * Fri Oct 14 2005 Tim Waugh - Install the desktop file with Hidden=True (bug #170762). * Fri Oct 14 2005 Tim Waugh 0.9.6-3 - Don't install desktop file (bug #170762). - Quieten the hpssd daemon at startup (bug #170762). * Wed Oct 12 2005 Tim Waugh 0.9.6-2 - 0.9.6. * Tue Sep 20 2005 Tim Waugh 0.9.5-3 - Apply upstream patch to fix scanning in LaserJets and parallel InkJets. * Mon Sep 19 2005 Tim Waugh 0.9.5-2 - 0.9.5. - No longer need condrestart patch. - Fix compile errors. * Tue Jul 26 2005 Tim Waugh 0.9.4-3 - Fix condrestart in the initscript. * Mon Jul 25 2005 Tim Waugh 0.9.4-2 - Use 'condrestart' not 'restart' in %%post scriptlet. * Fri Jul 22 2005 Tim Waugh 0.9.4-1 - forward-decl patch not needed. - 0.9.4. * Fri Jul 1 2005 Tim Waugh 0.9.3-8 - Removed Obsoletes: hpoj tags (bug #162222). * Thu Jun 30 2005 Tim Waugh 0.9.3-7 - Rebuild to get Python modules precompiled. * Wed Jun 22 2005 Tim Waugh 0.9.3-6 - For libsane-hpaio ExcludeArch: s390 s390x, because it requires sane-backends. * Wed Jun 15 2005 Tim Waugh 0.9.3-5 - Use static IP ports (for SELinux policy). * Tue Jun 14 2005 Tim Waugh 0.9.3-4 - Conflicts: hpijs from before this package provided it. - Conflicts: system-config-printer < 0.6.132 (i.e. before HPLIP support was added) * Thu Jun 9 2005 Tim Waugh 0.9.3-3 - Added Obsoletes: for xojpanel and hpoj-devel (but we don't actually package devel files yet). * Thu Jun 9 2005 Tim Waugh 0.9.3-2 - Add 'hpaio' to SANE config file, not 'hpoj' (bug #159954). * Thu Jun 9 2005 Tim Waugh 0.9.3-1 - Use /usr/share/applications for putting desktop files in (bug #159932). - Requires PyQt (bug #159932). * Tue Jun 7 2005 Tim Waugh 0.9.3-0.1 - Initial package, based on Mandriva spec file.