Subject: [bug#71787] [PATCH 01/12] gnu: Add lcms2mt.

From: David Elsing <[email-masked]>
Date: Wed, 26 Jun 2024 19:26:54 +0000

* gnu/packages/ghostscript.scm (lcms2mt): New variable.
---
 gnu/packages/ghostscript.scm | 23 ++++++++++++++++++++++-
 1 file changed, 22 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/ghostscript.scm b/gnu/packages/ghostscript.scm
index 502b41bb99..5f0e2cf3c4 100644
--- a/gnu/packages/ghostscript.scm
+++ b/gnu/packages/ghostscript.scm
@@ -10,7 +10,8 @@
 ;;; Copyright © 2018, 2020, 2022 Marius Bakke <[email-masked]>
 ;;; Copyright © 2019 Mathieu Othacehe <[email-masked]>
 ;;; Copyright © 2020, 2023 Janneke Nieuwenhuizen <[email-masked]>
-;;;
+;;; Copyright © 2024 David Elsing <[email-masked]>
+;;
 ;;; This file is part of GNU Guix.
 ;;;
 ;;; GNU Guix is free software; you can redistribute it and/or modify it
@@ -43,6 +44,7 @@ (define-module (gnu packages ghostscript)
   #:use-module (guix packages)
   #:use-module (guix download)
   #:use-module (guix gexp)
+  #:use-module (guix git-download)
   #:use-module (guix utils)
   #:use-module (guix build-system gnu)
   #:use-module (srfi srfi-1))
@@ -73,6 +75,25 @@ (define-public lcms
     (home-page "https://www.littlecms.com/")
     (properties '((cpe-name . "little_cms_color_engine")))))
 
+;; Fork of LCMS 2 for Ghostscript and MuPDF
+(define-public lcms2mt
+  (package
+    (inherit lcms)
+    (name "lcms2mt")
+    (version "2.16")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "git://git.ghostscript.com/thirdparty-lcms2")
+             (commit (string-append "lcms" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "0dxpq59r1w3r1391fngpvka51r16505zmr32zjs2azjlrz49k3x4"))))
+    (synopsis "Little CMS, a small-footprint colour management engine
+(GhostScript fork)")
+    (home-page "https://www.ghostscript.com/")))
+
 (define-public libpaper
   (package
     (name "libpaper")
-- 
2.45.1