From patchwork Thu Apr 11 22:10:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Steve George X-Patchwork-Id: 62934 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 7911A27BBEA; Thu, 11 Apr 2024 23:13:06 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 9D04827BBE2 for ; Thu, 11 Apr 2024 23:13:04 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rv2fB-0003nd-UY; Thu, 11 Apr 2024 18:12:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rv2fA-0003n5-AU for guix-patches@gnu.org; Thu, 11 Apr 2024 18:12:56 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rv2fA-0001Uh-21 for guix-patches@gnu.org; Thu, 11 Apr 2024 18:12:56 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rv2fI-0000cA-Rr for guix-patches@gnu.org; Thu, 11 Apr 2024 18:13:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#67549] [PATCH v2 2/2] gnu: Add latexml. Resent-From: Steve George Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 11 Apr 2024 22:13:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 67549 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 67549@debbugs.gnu.org Cc: steve@futurile.net X-Debbugs-Original-Cc: Steve George , Nicolas Graves via Guix-patches via Received: via spool by submit@debbugs.gnu.org id=B.17128735381998 (code B ref -1); Thu, 11 Apr 2024 22:13:04 +0000 Received: (at submit) by debbugs.gnu.org; 11 Apr 2024 22:12:18 +0000 Received: from localhost ([127.0.0.1]:57478 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rv2eU-0000VM-14 for submit@debbugs.gnu.org; Thu, 11 Apr 2024 18:12:17 -0400 Received: from lists.gnu.org ([2001:470:142::17]:38602) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rv2eK-0000Sa-Rx for submit@debbugs.gnu.org; Thu, 11 Apr 2024 18:12:07 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rv2e5-0003d1-1z for guix-patches@gnu.org; Thu, 11 Apr 2024 18:11:49 -0400 Received: from mailtransmit04.runbox.com ([2a0c:5a00:149::25]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rv2e0-0001Ap-Ff for guix-patches@gnu.org; Thu, 11 Apr 2024 18:11:48 -0400 Received: from mailtransmit03.runbox ([10.9.9.163] helo=aibo.runbox.com) by mailtransmit04.runbox.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from ) id 1rv2dv-002xwa-Oc; Fri, 12 Apr 2024 00:11:39 +0200 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=futurile.net; s=selector1; h=Content-Transfer-Encoding:Content-Type: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From; bh=/CIeiMo/bt2UNHGrweksUd3i8uKJzK2mePyH8zsxsHA=; b=B/QCd+9BXvgiU5e8fuEY7D298f nwkrq/9GV4pjD0xc0LkkIl9nar+UiZqjgCJkQhwjarxd25AVP17VYRkRC21aohAt3UQoFd5zAvEQ1 W4go6VPyuEoROrGAlQ7Wz/lLR2Mb7se+iR/nE52j6JhxvnH8AXwYl3Z8uTtPu/1UGf7/56EQYRe1R Euf5L4vAyU6iEmUoMd+ViCh1a0OhKFM868Jqtf0IF+iVZLVffFve3b7wuF6gu3L0ApPq2r9OMwZDq HGrvwQqAlVRaV8d1ngQXxi7GEVAzyLLRvkwknvbwY7qlWh/wTyUrJGpJJI+bVCgpNnUZn6NUhwDCG iQ1fonfA==; Received: from [10.9.9.72] (helo=submission01.runbox) by mailtransmit03.runbox with esmtp (Exim 4.86_2) (envelope-from ) id 1rv2dv-0004v1-GF; Fri, 12 Apr 2024 00:11:39 +0200 Received: by submission01.runbox with esmtpsa [Authenticated ID (641962)] (TLS1.2:ECDHE_SECP256R1__RSA_SHA256__AES_256_GCM:256) (Exim 4.93) id 1rv2da-00BsQv-CX; Fri, 12 Apr 2024 00:11:18 +0200 From: Steve George Date: Thu, 11 Apr 2024 23:10:40 +0100 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: References: <20231130171829.13457-1-ngraves@ngraves.fr> MIME-Version: 1.0 Received-SPF: permerror client-ip=2a0c:5a00:149::25; envelope-from=steve@futurile.net; helo=mailtransmit04.runbox.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, T_SPF_PERMERROR=0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches From: Nicolas Graves via Guix-patches via * gnu/packages/markup.scm (latexml): New variable. Reviewed-by: Steve George Change-Id: If7199a8b74b990ad29718adcb905a5ed31882cf5 --- gnu/packages/markup.scm | 117 +++++++++++++++++++++++++++++++++++++++- 1 file changed, 116 insertions(+), 1 deletion(-) diff --git a/gnu/packages/markup.scm b/gnu/packages/markup.scm index 6d891ee313..2cc3d0415d 100644 --- a/gnu/packages/markup.scm +++ b/gnu/packages/markup.scm @@ -12,6 +12,7 @@ ;;; Copyright © 2022 jgart ;;; Copyright © 2022, 2024 Vinicius Monego ;;; Copyright © 2023 Zheng Junjie <873216071@qq.com> +;;; Copyright © 2023 Nicolas Graves ;;; ;;; This file is part of GNU Guix. ;;; @@ -44,15 +45,21 @@ (define-module (gnu packages markup) #:use-module (guix gexp) #:use-module (gnu packages) #:use-module (gnu packages base) + #:use-module (gnu packages bash) #:use-module (gnu packages check) #:use-module (gnu packages compression) + #:use-module (gnu packages databases) #:use-module (gnu packages libffi) + #:use-module (gnu packages imagemagick) #:use-module (gnu packages perl) #:use-module (gnu packages perl-check) + #:use-module (gnu packages perl-compression) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) #:use-module (gnu packages python-xyz) - #:use-module (gnu packages web)) + #:use-module (gnu packages tex) + #:use-module (gnu packages web) + #:use-module (gnu packages xml)) (define-public hoedown (package @@ -126,6 +133,114 @@ (define-public markdown (license (license:non-copyleft "file://License.text" "See License.text in the distribution.")))) +(define-public latexml + (package + (name "latexml") + (version "0.8.8") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/brucemiller/LaTeXML") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0lppm66fxadsbn73xh0nfqdi4y6d9j6xph1slvlp6ynrfbnn5p6s")))) + (build-system perl-build-system) + (arguments + (let ((wraplibs + (list "perl-archive-zip" + "perl-common-sense" + "perl-db-file" + "perl-encode-locale" + "perl-file-which" + "perl-getopt-long" + "perl-http-date" + "perl-http-message" + "perl-image-magick" + "perl-image-size" + "perl-io-string" + "perl-json-xs" + "perl-libwww" + "perl-mime-base64" + "perl-parse-recdescent" + "perl-pod-parser" + "perl-text-unidecode" + "perl-time-hires" + "perl-try-tiny" + "perl-types-serialiser" + "perl-uri" + "perl-xml-libxml" + "perl-xml-libxslt" + "perl-xml-sax-base"))) + (list + ;; some tests skip due to missing dependencies + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'find-itself + ;; Fix run-time 'Can't locate [].pm in @INC' failure and remove + ;; need for extensive set of propagated inputs + (lambda* (#:key inputs outputs #:allow-other-keys) + (with-directory-excursion (string-append #$output "/bin") + (for-each + (lambda* (program) + (wrap-program program + `("PERL5LIB" ":" prefix + (,(string-append #$output "/lib/perl5/site_perl") + ,#$@(map (lambda (in) + (file-append + (this-package-input in) "/lib/perl5/site_perl")) + wraplibs))))) + (find-files "." ".*"))))))))) + (inputs + (list bash-minimal + libxml2 + libxslt + perl + perl-archive-zip + perl-common-sense + perl-db-file + perl-encode-locale + perl-file-which + perl-getopt-long + perl-http-date + perl-http-message + perl-image-magick + perl-image-size + perl-io-string + perl-json-xs + perl-libwww + perl-mime-base64 + perl-parse-recdescent + perl-pod-parser + perl-text-unidecode + perl-time-hires + perl-try-tiny + perl-types-serialiser + perl-uri + perl-xml-libxml + perl-xml-libxslt + perl-xml-sax-base)) + (native-inputs + (list texlive-bin + perl-test-more-utf8 + perl-extutils-manifest + perl-data-dumper + perl-ipc-run3 + perl-file-temp)) + (home-page "https://math.nist.gov/~BMiller/LaTeXML/") + (synopsis "LaTeX to XML, HTML, MathML, epub and Jats converter") + (description "This package provides a LaTeX converter, with the following goals: +@itemize +@item Faithful emulation of TEX’s behaviour; +@item Easily extensible; +@item Lossless, preserving both semantic and presentation cues; +@item Use an abstract LATEX-like, extensible, document type; +@item Infer the semantics of mathematical content +@end itemize") + (license license:cc0))) + (define-public lowdown (package (name "lowdown")