aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/patches/hplip-remove-imageprocessor.patch
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/patches/hplip-remove-imageprocessor.patch')
-rw-r--r--gnu/packages/patches/hplip-remove-imageprocessor.patch41
1 files changed, 27 insertions, 14 deletions
diff --git a/gnu/packages/patches/hplip-remove-imageprocessor.patch b/gnu/packages/patches/hplip-remove-imageprocessor.patch
index cde3ecba2d..c9d27a4d1d 100644
--- a/gnu/packages/patches/hplip-remove-imageprocessor.patch
+++ b/gnu/packages/patches/hplip-remove-imageprocessor.patch
@@ -1,4 +1,5 @@
-This patch is based heavily on the Debian patch.
+This patch is based heavily on the Debian patch, but was updated to
+apply to subsequent upstream changes not yet in Debian.
https://salsa.debian.org/printing-team/hplip/raw/debian/3.18.10+dfsg0-1/debian/patches/0025-Remove-all-ImageProcessor-functionality-which-is-clo.patch
@@ -175,55 +176,67 @@ index 5b282d8..0bacfaf 100644
#include <signal.h>
#include <sys/wait.h>
-@@ -637,16 +636,10 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster)
-
+@@ -651,21 +650,8 @@
sprintf(hpPreProcessedRasterFile, "%s/hp_%s_cups_SwapedPagesXXXXXX",CUPS_TMP_DIR, m_JA.user_name);
-- image_processor_t* imageProcessor = imageProcessorCreate();
-
+
+- image_processor_t* imageProcessor=NULL;
+- IMAGE_PROCESSOR_ERROR result;
+- //added if condition to check if pinter language is "ljzjstream"
+- //If so, then bypass imageprocessing functions while running HPCUPS filter.
+- if(strncmp(m_JA.printer_platform, "ljzjstream",10) == 0){
+- imageProcessor = imageProcessorCreate();
+- }
while (cupsRasterReadHeader2(cups_raster, &cups_header))
{
-
-- IMAGE_PROCESSOR_ERROR result = imageProcessorStartPage(imageProcessor, &cups_header);
+- if(strncmp(m_JA.printer_platform, "ljzjstream",10) == 0){
+- 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) {
-@@ -745,12 +738,6 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster)
+@@ -764,14 +750,6 @@
color_raster = rgbRaster;
black_raster = kRaster;
+- if(strncmp(m_JA.printer_platform, "ljzjstream",10) == 0)
+- {
- 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
-@@ -780,12 +767,6 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster)
+@@ -801,14 +779,6 @@
}
} // for() loop end
+- if(strncmp(m_JA.printer_platform, "ljzjstream",10) == 0)
+- {
- result = imageProcessorEndPage(imageProcessor);
- if (result != IPE_SUCCESS){
- dbglog("DEBUG: imageProcessorEndPage failed result = %d\n", result);
- }
--
+- }
-
m_Job.NewPage();
if (err != NO_ERROR) {
break;
-@@ -800,8 +781,6 @@ int HPCupsFilter::processRasterData(cups_raster_t *cups_raster)
+@@ -823,11 +793,6 @@
rgbRaster = NULL;
}
+-
+- if(strncmp(m_JA.printer_platform, "ljzjstream",10) == 0)
+- {
- imageProcessorDestroy(imageProcessor);
--
+- }
unlink(hpPreProcessedRasterFile);
return ret_status;
}
uix/commit/tests/store.scm?id=2725f0463421dfb446bce393b87a13139922f1cc'>store: Remove 'references/substitutes'.Ludovic Courtès This procedure lost its only user in commit 710854304b1ab29332edcb76f3de532e0724c197. * guix/store.scm (references/substitutes): Remove. * tests/store.scm ("references/substitutes missing reference info") ("references/substitutes with substitute info"): Remove. 2021-03-18tests: Make the STORE test more robust in a "pure" environment.Leo Famulari Otherwise, the test crashes (not fails) when run in `guix environment --pure guix`. Fixes <https://bugs.gnu.org/46445>. * tests/store.scm (%shell): Fallback to "/bin/sh". 2021-01-22store: Add 'find-roots' RPC.Ludovic Courtès * guix/serialization.scm (read-string-pairs): New procedure. * guix/store.scm (read-arg): Add support for 'string-pairs'. (find-roots): New procedure. * tests/store.scm ("add-indirect-root and find-roots"): New test. 2020-12-19tests: Make sure substituted items are deduplicated.Ludovic Courtès * tests/store.scm ("substitute, deduplication"): New test. 2020-12-19tests: Check the mtime and permissions of substituted items.Ludovic Courtès * tests/store.scm ("substitute") ("substitute + build-things with output path") ("substitute + build-things with specific output"): Call 'canonical-file?'. * tests/substitute.scm ("substitute, authorized key"): Check the mtime and permissions of "substitute-retrieved". 2020-12-19tests: Check the build trace for hash mismatches on substitutes.Ludovic Courtès * tests/store.scm ("substitute, corrupt output hash, build trace"): New test. 2020-09-14tests: Remove one 'delete-paths' call in 'tests/store.scm'.Ludovic Courtès This makes the test slightly less expensive. * tests/store.scm ("add-text-to-store vs. delete-paths") ("add-to-store vs. delete-paths"): Delete and merge into... ("add-text-to-store/add-to-store vs. delete-paths"): ... this test. 2020-09-14daemon: Spawn 'guix authenticate' once for all.Ludovic Courtès Previously, we'd spawn 'guix authenticate' once for each item that has to be signed (when exporting) or authenticated (when importing). Now, we spawn it once for all and then follow a request/reply protocol. This reduces the wall-clock time of: guix archive --export -r $(guix build coreutils -d) from 30s to 2s. * guix/scripts/authenticate.scm (sign-with-key): Return the signature instead of displaying it. Raise a &formatted-message instead of calling 'leave'. (validate-signature): Likewise. (read-command): New procedure. (define-enumerate-type, reply-code): New macros. (guix-authenticate)[send-reply]: New procedure. Change to read commands from current-input-port. * nix/libstore/local-store.cc (runAuthenticationProgram): Remove. (authenticationAgent, readInteger, readAuthenticateReply): New functions. (signHash, verifySignature): Rewrite in terms of the agent. * tests/store.scm ("import not signed"): Remove 'pk' call. ("import signed by unauthorized key"): Check the error message of C. * tests/guix-authenticate.sh: Rewrite using the new protocol. fixlet 2020-09-11store: Test 'import-paths' with unauthorized and unsigned nar bundles.Ludovic Courtès * tests/store.scm ("import not signed") ("import signed by unauthorized key"): New tests. 2020-08-28store: 'with-store' returns as many values as its body.Ludovic Courtès Fixes <https://bugs.gnu.org/42912>. Reported by Ricardo Wurmus <rekado@elephly.net>. * guix/store.scm (call-with-store)[thunk]: Wrap call to PROC in 'call-with-values'. * tests/store.scm ("with-store, multiple values"): New test. 2020-06-27daemon: Recognize SHA3 and BLAKE2s.Ludovic Courtès * nix/libutil/hash.hh (HashType): Add htSHA3_256, htSHA3_512, and htBLAKE2s_256. * nix/libutil/hash.cc (parseHashType, printHashType): Recognize them. * tests/store.scm ("add-to-store"): Test these algorithms. 2020-05-22packages: Introduce <content-hash> and use it in <origin>.Ludovic Courtès * guix/packages.scm (<content-hash>): New record type. (define-content-hash-constructor, build-content-hash) (content-hash): New macros. (print-content-hash): New procedure. (<origin>): Rename constructor to '%origin'. [sha256]: Remove field. [hash]: New field. Adjust users. (origin-compatibility-helper, origin): New macros. (origin-sha256): New deprecated procedure. (origin->derivation): Adjust accordingly. * tests/packages.scm ("package-source-derivation, origin, sha512"): New test. * guix/tests.scm: Hide (gcrypt hash) 'sha256' for proper syntax matching. * tests/challenge.scm: Add #:prefix for (gcrypt hash) and adjust users. * tests/derivations.scm: Likewise. * tests/store.scm: Likewise. * tests/graph.scm ("bag DAG, including origins"): Provide 'sha256' field with the right length. * gnu/packages/aspell.scm (aspell-dictionary) (aspell-dict-ca, aspell-dict-it): Use 'hash' and 'content-hash' for proper syntax matching. * gnu/packages/bash.scm (bash-patch): Rename 'sha256' to 'sha256-bv'. * gnu/packages/bootstrap.scm (bootstrap-executable): Rename 'sha256' to 'bv'. * gnu/packages/readline.scm (readline-patch): Likewise. * gnu/packages/virtualization.scm (qemu-patch): Rename 'sha256' to 'sha256-bv'. * guix/import/utils.scm: Hide (gcrypt hash) 'sha256'. 2020-05-22tests: Test 'add-to-store' with several hash algorithms.Ludovic Courtès * tests/store.scm ("add-to-store"): New test. 2020-05-14store: 'mapm/accumulate-builds' preserves '%current-target-system'.Ludovic Courtès Fixes <https://bugs.gnu.org/41182>. * guix/store.scm (mapm/accumulate-builds): Pass #:system and #:target to 'run-with-store'. * tests/store.scm ("mapm/accumulate-builds, %current-target-system"): New test. * tests/guix-pack.sh: Add 'guix pack -d --target' test. 2020-04-04store: 'with-store' doesn't close the store upon abort.Ludovic Courtès Fixes <https://bugs.gnu.org/40428>. Reported by Marius Bakke <mbakke@fastmail.com> and 白い熊. Regression introduced with the first uses of 'with-build-handler' in commit 62195b9a8fd6846117c5d7698842748300d13e31 and subsequent. * guix/store.scm (call-with-store): Use 'catch #t' instead of 'dynamic-wind'. This ensures STORE remains open when a non-local exit other than an exception occurs, such as an abort to the build handler prompt. * tests/store.scm ("with-build-handler + with-store"): New test. 2020-03-29store: Add 'map/accumulate-builds'.Ludovic Courtès * guix/store.scm (<unresolved>): New record type. (build-accumulator, map/accumulate-builds, mapm/accumulate-builds): New procedures. * tests/store.scm ("map/accumulate-builds", "mapm/accumulate-builds"): New tests. 2020-03-22store: Add 'with-build-handler'.Ludovic Courtès * guix/store.scm (current-build-prompt): New variable. (call-with-build-handler, invoke-build-handler): New procedures. (with-build-handler): New macro. * tests/store.scm ("with-build-handler"): New test.