Browse Source

hplip-3.18.10-1

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@11877 ec354946-7b23-47d6-9f5a-488ba84defc7
tomop 5 years ago
parent
commit
858ba4dd51
1 changed files with 112 additions and 26 deletions
  1. 112 26
      h/hplip/hplip-vl.spec

+ 112 - 26
h/hplip/hplip-vl.spec

@@ -2,7 +2,7 @@
 Summary:	HP printer drivers & utilities for Linux
 Summary(ja): 	HP プリンタの Linux 向けドライバとユーティリティ
 Name:		hplip
-Version:	3.16.5
+Version:	3.18.10
 Release: 	1%{?_dist_release}
 
 License:	GPLv2+, MIT and BSD
@@ -12,6 +12,7 @@ URL:		http://hplip.sourceforge.net/
 Source0:	http://downloads.sourceforge.net/sourceforge/hplip/hplip-%{version}.tar.gz
 #Source1:	hpcups-update-ppds.sh
 Source2:	copy-deviceids.py
+Source3:	%{name}.appdata.xml
 Source1000:	hplip.desktop.vine
 
 Patch1:		hplip-pstotiff-is-rubbish.patch
@@ -36,11 +37,29 @@ Patch20:	hplip-dj990c-margin.patch
 Patch21:	hplip-strncpy.patch
 Patch22:	hplip-no-write-bytecode.patch
 Patch23:	hplip-silence-ioerror.patch
+Patch24: hplip-3165-sourceoption.patch
+Patch25: hplip-noernie.patch
+Patch26: hplip-appdata.patch
+Patch27: hplip-check-cups.patch
+Patch30: hplip-typo.patch
+# python3 - recent HP release removed encoding/decoding to utf-8 in fax/pmlfax.py -
+# that results in text string going into translate function in base/utils.py, which
+# expects binary string because of parameters. Remove this patch if base/utils.py
+# code gets fixed.
+Patch31: hplip-use-binary-str.patch
+# m278-m281 doesn't work correctly again
+Patch32: hplip-colorlaserjet-mfp-m278-m281.patch
+Patch33: hplip-error-print.patch
+Patch34: hplip-hpfax-importerror-print.patch
+Patch35: hplip-wifisetup.patch
 
 # Vine Patches
 Patch70:	hplip-3.11.5-gksu.patch
 Patch80:	hplip-3.16.5-hpijs.patch
 
+# drop dependence on closed-source libImageProcessor.so
+Patch100:	0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch
+
 BuildRoot:	%{_tmppath}/%{name}-%{version}-root
 Requires:	cups
 Requires:	dbus
@@ -235,9 +254,49 @@ done
 # Ignore IOError when logging output (bug #712537).
 %patch23 -p1 -b .silence-ioerror
 
+# [abrt] hplip: hp-scan:663:<module>:NameError: name 'source_option' is not defined (bug #1341304)
+%patch24 -p1 -b .sourceoption
+
+# hplip license problem (bug #1364711)
+%patch25 -p1 -b .no-ernie
+
+# hplip appdata
+%patch26 -p1 -b .appdata
+
+rm prnt/hpcups/ErnieFilter.{cpp,h} prnt/hpijs/ernieplatform.h
+
+# hp-check shows 'CUPS incompatible or not running' even if CUPS is running (bug #1456467)
+%patch27 -p1 -b .check-cups
+
+# hp-firmware:NameError: name 'INTERACTIVE_MODE4' is not defined (bug #1533869)
+%patch30 -p1 -b .typo
+
+%patch31 -p1 -b .use-binary-str
+%patch32 -p1 -b .colorlaserjet-mfp-m278-m281
+
+# TypeError: 'Error' object does not support indexing (bug #1564770)
+# upstream bug: https://bugs.launchpad.net/ubuntu/+source/hplip/+bug/1718129
+# in python2 it was possible to acces Exception message by index [0].
+# in python3 this is no longer possible and it causes TypeError.
+%patch33 -p1 -b .error-print-fix
+
+# TypeError: not all arguments converted during string formatting (bug #1566938)
+# upstream bug: https://bugs.launchpad.net/ubuntu/+source/hplip/+bug/616450
+# bug caused by more arguments than argument specifiers in formatted string
+%patch34 -p1 -b .hpfax-import-error-print
+
+# 'WifiSetupDialog' object has no attribute 'wifiobj' (bug #1626877)
+# upstream bug: https://bugs.launchpad.net/hplip/+bug/1752060
+# bug caused by typo in wifisetupdialog wifiObj property call
+%patch35 -p1 -b .wifisetup-bad-call-fix
+
+# vine
+
 %patch70 -p1 -b .gksu
 %patch80 -p1 -b .hpijs
 
+%patch100 -p1 -b .libimageprocessor
+
 sed -i.duplex-constraints \
     -e 's,\(UIConstraints.* \*Duplex\),//\1,' \
     prnt/drv/hpcups.drv.in
@@ -246,13 +305,16 @@ sed -i.duplex-constraints \
 #find -name '*.py' -print0 | xargs -0 \
 #    sed -i.env-python -e 's,^#!/usr/bin/env python,#!%{__python3},'
 
+rm locatedriver
+
 %build
 touch NEWS README AUTHORS ChangeLog
 autoreconf -f -i
 %configure \
         --enable-scan-build --enable-gui-build --enable-fax-build \
         --disable-foomatic-rip-hplip-install --enable-pp-build \
-        --enable-qt4 --enable-hpcups-install --enable-cups-drv-install \
+        --enable-qt4 \
+        --enable-hpcups-install --enable-cups-drv-install \
         --enable-foomatic-drv-install --enable-dbus-build \
         --enable-hpijs-install \
 	--disable-policykit \
@@ -287,33 +349,50 @@ d /run/hplip 0775 root lp -
 EOF
 
 # remove unpacked files.
-rm -rf $RPM_BUILD_ROOT%{_sysconfdir}/sane.d \
-        $RPM_BUILD_ROOT%{_docdir} \
-        $RPM_BUILD_ROOT%{_datadir}/hal/fdi \
-        $RPM_BUILD_ROOT%{_datadir}/hplip/pkservice.py \
-        $RPM_BUILD_ROOT%{_bindir}/hp-pkservice
-rm -f   $RPM_BUILD_ROOT%{_bindir}/hp-logcapture \
-        $RPM_BUILD_ROOT%{_bindir}/hp-doctor \
-        $RPM_BUILD_ROOT%{_datadir}/hplip/logcapture.py \
-        $RPM_BUILD_ROOT%{_datadir}/hplip/doctor.py
-
-rm -f   $RPM_BUILD_ROOT%{_bindir}/foomatic-rip \
-        $RPM_BUILD_ROOT%{_libdir}/cups/filter/foomatic-rip \
-        $RPM_BUILD_ROOT%{_libdir}/*.la \
-        $RPM_BUILD_ROOT%{python_sitearch}/*.la \
-        $RPM_BUILD_ROOT%{_libdir}/libhpip.so \
-        $RPM_BUILD_ROOT%{_libdir}/sane/*.la \
-        $RPM_BUILD_ROOT%{_datadir}/cups/model/foomatic-ppds \
-        $RPM_BUILD_ROOT%{_datadir}/applications/hplip.desktop \
-        $RPM_BUILD_ROOT%{_datadir}/ppd/HP/*.ppd
-
+rm -rf  %{buildroot}%{_sysconfdir}/sane.d \
+        %{buildroot}%{_docdir} \
+        %{buildroot}%{_datadir}/hal/fdi \
+        %{buildroot}%{_datadir}/hplip/pkservice.py \
+        %{buildroot}%{_bindir}/hp-pkservice \
+        %{buildroot}%{_datadir}/hplip/locatedriver* \
+        %{buildroot}%{_datadir}/hplip/dat2drv*
+
+rm -f   %{buildroot}%{_bindir}/hp-logcapture \
+        %{buildroot}%{_bindir}/hp-doctor \
+        %{buildroot}%{_bindir}/hp-pqdiag \
+        %{buildroot}%{_datadir}/hplip/logcapture.py \
+        %{buildroot}%{_datadir}/hplip/doctor.py \
+        %{buildroot}%{_datadir}/hplip/pqdiag.py
+
+rm -f   %{buildroot}%{_bindir}/foomatic-rip \
+        %{buildroot}%{_libdir}/cups/filter/foomatic-rip \
+        %{buildroot}%{_libdir}/*.la \
+        %{buildroot}%{python3_sitearch}/*.la \
+        %{buildroot}%{_libdir}/libhpip.so \
+        %{buildroot}%{_libdir}/libhpipp.so \
+        %{buildroot}%{_libdir}/libhpdiscovery.so \
+        %{buildroot}%{_libdir}/sane/*.la \
+        %{buildroot}%{_datadir}/cups/model/foomatic-ppds \
+        %{buildroot}%{_datadir}/applications/hplip.desktop \
+        %{buildroot}%{_datadir}/ppd/HP/*.ppd
+
+mkdir -p %{buildroot}%{_datadir}/appdata
+cp %{SOURCE3} %{buildroot}%{_datadir}/appdata/
+
+mkdir -p %{buildroot}%{_datadir}/icons/hicolor/{16x16,32x32,64x64}/apps
+install -p -m644 %{buildroot}%{_datadir}/hplip/data/images/16x16/hp_logo.png \
+   %{buildroot}%{_datadir}/icons/hicolor/16x16/apps/hp_logo.png
+install -p -m644 %{buildroot}%{_datadir}/hplip/data/images/32x32/hp_logo.png \
+   %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/hp_logo.png
+install -p -m644 %{buildroot}%{_datadir}/hplip/data/images/64x64/hp_logo.png \
+   %{buildroot}%{_datadir}/icons/hicolor/64x64/apps/hp_logo.png
 
 cp -p %{SOURCE1000} hplip.desktop
 mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications
 sed -i -e '/^Categories=/d' hplip.desktop
 # Encoding key is deprecated
 sed -i -e '/^Encoding=/d' hplip.desktop
-desktop-file-install --vendor ""                                \
+desktop-file-install --vendor "HP"                                \
         --dir $RPM_BUILD_ROOT%{_datadir}/applications              \
         --add-category System                                   \
         --add-category Settings                                 \
@@ -381,7 +460,6 @@ rm -rf $RPM_BUILD_ROOT
 %{_bindir}/hp-makecopies
 %{_bindir}/hp-makeuri
 %{_bindir}/hp-plugin
-%{_bindir}/hp-pqdiag
 %{_bindir}/hp-printsettings
 %{_bindir}/hp-probe
 %{_bindir}/hp-query
@@ -422,7 +500,6 @@ rm -rf $RPM_BUILD_ROOT
 %{_datadir}/hplip/makecopies.py*
 %{_datadir}/hplip/makeuri.py*
 %{_datadir}/hplip/plugin.py*
-%{_datadir}/hplip/pqdiag.py*
 %{_datadir}/hplip/printsettings.py*
 %{_datadir}/hplip/probe.py*
 %{_datadir}/hplip/query.py*
@@ -477,22 +554,31 @@ rm -rf $RPM_BUILD_ROOT
 %{_bindir}/hp-print
 %{_bindir}/hp-systray
 %{_bindir}/hp-toolbox
+%{_bindir}/hp-uiscan
 %{_datadir}/applications/*.desktop
+%{_datadir}/appdata/hplip.appdata.xml
 # Files
+%{_datadir}/icons/hicolor/*/apps/*
 %{_datadir}/hplip/check.py*
 %{_datadir}/hplip/print.py*
 %{_datadir}/hplip/systray.py*
 %{_datadir}/hplip/toolbox.py*
+%{_datadir}/hplip/uiscan.py*
 # Directories
 %{_datadir}/hplip/data/images
 %{_datadir}/hplip/ui4
-
+%{_datadir}/hplip/uiscan.py*
 %files -n libsane-hpaio
 %defattr(-,root,root)
 %{_libdir}/sane/libsane-hpaio*
 %config(noreplace) %{_sysconfdir}/sane.d/dll.d/hpaio
 
 %changelog
+* Wed Nov 07 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.18.10-1
+- new upstream release.
+- updated Patch12.
+- imported Patche24-35 from rawhide.
+
 * Sat Jul 2 2016 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.16.5-1
 - new upstream release.
 - dropped all patches.