From 1b2f3407f0e85eec4d4628f6f36fd1ad88c31063 Mon Sep 17 00:00:00 2001 From: Patrick J Volkerding Date: Fri, 14 Sep 2018 23:06:26 +0000 Subject: Fri Sep 14 23:06:26 UTC 2018 ap/hplip-3.18.7-x86_64-3.txz: Rebuilt. Throw away the broken and ill-advised libImageProcessor closed-source blob. Thanks to Matteo Bernardini. ap/zsh-5.6.2-x86_64-1.txz: Upgraded. d/rust-1.29.0-x86_64-1.txz: Upgraded. l/lmdb-0.9.22-x86_64-1.txz: Added. This is a new dependency of Samba. n/php-7.2.10-x86_64-1.txz: Upgraded. This is a security release which also contains several minor bug fixes. For more information, see: https://php.net/ChangeLog-7.php#7.2.10 (* Security fix *) n/samba-4.9.0-x86_64-1.txz: Upgraded. x/xf86-video-amdgpu-18.1.0-x86_64-1.txz: Upgraded. x/xf86-video-ati-18.1.0-x86_64-1.txz: Upgraded. --- ...ImageProcessor-functionality-which-is-clo.patch | 114 +++++++++++++++++++++ source/ap/hplip/hplip.SlackBuild | 16 ++- 2 files changed, 127 insertions(+), 3 deletions(-) create mode 100644 source/ap/hplip/0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch (limited to 'source/ap/hplip') diff --git a/source/ap/hplip/0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch b/source/ap/hplip/0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch new file mode 100644 index 00000000..5bf43328 --- /dev/null +++ b/source/ap/hplip/0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch @@ -0,0 +1,114 @@ +From b78107ce36b7a8602479222f1ee806566727c8de Mon Sep 17 00:00:00 2001 +From: Didier Raboud +Date: Tue, 21 Aug 2018 18:18:10 +0200 +Subject: Remove all ImageProcessor functionality, which is closed-source + +--- + Makefile.am | 14 ++------------ + prnt/hpcups/HPCupsFilter.cpp | 21 --------------------- + 2 files changed, 2 insertions(+), 33 deletions(-) + +diff --git a/Makefile.am b/Makefile.am +index 7eb645149..cc7e89611 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -164,7 +164,7 @@ if !HPLIP_CLASS_DRIVER + dist_hplip_SCRIPTS = hpssd.py __init__.py hpdio.py + endif #HPLIP_CLASS_DRIVER + +-dist_noinst_DATA += prnt/drv/hpijs.drv.in.template prnt/drv/hpcups.drv.in.template prnt/hpcups/libImageProcessor-x86_64.so prnt/hpcups/libImageProcessor-x86_32.so ++dist_noinst_DATA += prnt/drv/hpijs.drv.in.template prnt/drv/hpcups.drv.in.template + dist_noinst_SCRIPTS += dat2drv.py install.py hplip-install init-suse-firewall init-iptables-firewall class_rpm_build.sh hplipclassdriver.spec createPPD.sh Makefile_dat2drv hpijs-drv + + if !HPLIP_CLASS_DRIVER +@@ -588,7 +588,7 @@ hpcups_SOURCES = prnt/hpcups/HPCupsFilter.cpp prnt/hpcups/HPCupsFilter.h prnt/hp + prnt/hpcups/ImageProcessor.h + + hpcups_CXXFLAGS = $(APDK_ENDIAN_FLAG) $(DBUS_CFLAGS) +-hpcups_LDADD = -L./prnt/hpcups/ -ljpeg -ldl -lImageProcessor -lcups -lcupsimage -lz $(DBUS_LIBS) ++hpcups_LDADD = -L./prnt/hpcups/ -ljpeg -ldl -lcups -lcupsimage -lz $(DBUS_LIBS) + + #else + #hpcupsdir = $(cupsfilterdir) +@@ -681,16 +681,6 @@ endif #HPLIP_CLASS_DRIVER + + install-data-hook: + if HPLIP_BUILD +- if [ \( "$(UNAME)" = "x86_64" -a -d "$(libdir)/" \) ]; then \ +- cp prnt/hpcups/libImageProcessor-x86_64.so $(libdir)/ ; \ +- chmod 775 $(libdir)/libImageProcessor-x86_64.so ; \ +- ln -sf $(libdir)/libImageProcessor-x86_64.so $(libdir)/libImageProcessor.so ; \ +- fi; \ +- if [ \( \( "$(UNAME)" = "i686" -o "$(UNAME)" = "i386" \) -a -d "$(libdir)/" \) ]; then \ +- cp prnt/hpcups/libImageProcessor-x86_32.so $(libdir)/ ; \ +- chmod 775 $(libdir)/libImageProcessor-x86_32.so ; \ +- ln -sf $(libdir)/libImageProcessor-x86_32.so $(libdir)/libImageProcessor.so ; \ +- fi + if !HPLIP_CLASS_DRIVER + # If scanner build, add hpaio entry to sane dll.conf. + if [ "$(scan_build)" = "yes" ]; then \ +diff --git a/prnt/hpcups/HPCupsFilter.cpp b/prnt/hpcups/HPCupsFilter.cpp +index 413daa3c5..7c1e8566c 100644 +--- a/prnt/hpcups/HPCupsFilter.cpp ++++ b/prnt/hpcups/HPCupsFilter.cpp +@@ -31,7 +31,6 @@ + \*****************************************************************************/ + + #include "HPCupsFilter.h" +-#include "ImageProcessor.h" + + #include + #include +@@ -637,17 +636,11 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster) + + + sprintf(hpPreProcessedRasterFile, "%s/hp_%s_cups_SwapedPagesXXXXXX",CUPS_TMP_DIR, m_JA.user_name); +- image_processor_t* imageProcessor = imageProcessorCreate(); + + while (cupsRasterReadHeader2(cups_raster, &cups_header)) + { + dbglog("DEBUG: SHIVA inside the while loop"); + +- IMAGE_PROCESSOR_ERROR result = imageProcessorStartPage(imageProcessor, &cups_header); +- if (result != IPE_SUCCESS){ +- dbglog("DEBUG: imageProcessorStartPage failed result = %d\n", result); +- } +- + current_page_number++; + + if (current_page_number == 1) { +@@ -746,12 +739,6 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster) + color_raster = rgbRaster; + black_raster = kRaster; + +- result = imageProcessorProcessLine(imageProcessor, m_pPrinterBuffer, cups_header.cupsBytesPerLine); +- if (result != IPE_SUCCESS){ +- dbglog("DEBUG: imageProcessorProcessLine failed result = %d\n", result); +- } +- +- + if ((y == 0) && !is_ljmono) { + //For ljmono, make sure that first line is not a blankRaster line.Otherwise printer + //may not skip blank lines before actual data +@@ -781,12 +768,6 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster) + } + } // for() loop end + +- result = imageProcessorEndPage(imageProcessor); +- if (result != IPE_SUCCESS){ +- dbglog("DEBUG: imageProcessorEndPage failed result = %d\n", result); +- } +- +- + m_Job.NewPage(); + if (err != NO_ERROR) { + break; +@@ -801,8 +782,6 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster) + rgbRaster = NULL; + } + +- imageProcessorDestroy(imageProcessor); +- + unlink(hpPreProcessedRasterFile); + return ret_status; + } diff --git a/source/ap/hplip/hplip.SlackBuild b/source/ap/hplip/hplip.SlackBuild index 05f9e26c..a83ac9e6 100755 --- a/source/ap/hplip/hplip.SlackBuild +++ b/source/ap/hplip/hplip.SlackBuild @@ -27,7 +27,7 @@ cd $(dirname $0) ; CWD=$(pwd) PKGNAM=hplip VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)} -BUILD=${BUILD:-2} +BUILD=${BUILD:-3} NUMJOBS=${NUMJOBS:-" -j7 "} @@ -96,8 +96,18 @@ sed -i.env-python -e 's,^#!/usr/bin/env python,#!/usr/bin/python3,' \ prnt/filters/hpps \ fax/filters/pstotiff -# libImageProcessor installation is fubar in 3.18.7: -zcat $CWD/hplip.libImageProcessor.diff.gz | patch -p1 -l --verbose || exit 1 +# COMMENTED OUT: We aren't going to need this patch since the one below it +# throws the blob into the bit bucket. +## libImageProcessor installation is fubar in 3.18.7: +#zcat $CWD/hplip.libImageProcessor.diff.gz | patch -p1 -l --verbose || exit 1 + +# Forget it folks - this ImageProcessor closed-source blob is broken, and there +# is no way to fix it. We will use this patch from Debian to remove it from +# hplip, reverting to the way things worked in the 3.18.6 release. If HP ever +# sees fit to make ImageProcessor mandatory, we'll likely stick with the last +# hplip release that can be made to work without it, and any HP printers that +# require a newer version of hplip will not be supported. +zcat $CWD/0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch.gz | patch -p1 -l --verbose || exit 1 CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ -- cgit v1.2.3