From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id IFW/Gx3eDWbQCgEAqHPOHw:P1 (envelope-from ) for ; Thu, 04 Apr 2024 00:54:21 +0200 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id IFW/Gx3eDWbQCgEAqHPOHw (envelope-from ) for ; Thu, 04 Apr 2024 00:54:21 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=none; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1712184861; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post; bh=wL2p1pqf0yInzXcNKX0OJTHX1v+o7SLcBmDpC3BUrUI=; b=EQ6lGNFbEsnxYA1J2GLCFmh9yvTZO8enhE0OS1emHQUstZXpr+N2EjcdkOrlwAjvNLSqTF KBquBdBSU+Mz8E/XzmiVGzjAlzG/r/D5zioQrYBYJpYK03alYiptGuyuj2l1maIEeev3W3 r2sYcC1QG78jDCdfz/JPqZ0FitG9LVgwW0oXoy+9lFbqEccknEOsDkzvbWgA3+w67PKQh/ 7Ay36z21T4mxyntU/FUBrO/CueG0rl5SQG4cgmwEzRlHWW1p2x61w/xOr07Xr0xFvoIdyf NqdLJ7uf7CSt8f5j0GRJklGA91BQkEEHeEDeFgimtYHwfsBVNa0v+k5Vr91Mpg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1712184861; a=rsa-sha256; cv=none; b=PFXOXBqLQkvspHVR43AWa+P/GHQ9qFLCIYRWToUt3N9cZPcBju/SDIFFVEg2YgKBPC/0QH nTdBRplB+xAjbRrVosdaV4+EjXUpV0rbXV/NMwr8L59D5mw1x5bI9ttAAuOtmhqsOBrBVP 8sFl5cFJuTMrGzAncJL2Kk9QRjMUBKcSjVUN73K0LTATas+oHqZjkgM2WWLCpnEK3mHad3 ZBg5B3VcQMpgqih9zNx2YGWFbHDH6zJLMbDFX7VCPIZUxTHcMamWHyloXurqtzzEWAZFy8 zV6okd3VzOb7N16ZLVPNNGpYO32naJL8iTIOWJ8Y5wo/lA0IGKf7/31EPUioSw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=none; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=none Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 29DC63759D for ; Thu, 4 Apr 2024 00:54:21 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rs9UY-00065t-7W; Wed, 03 Apr 2024 18:54:02 -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 1rs9UV-00065L-M7 for guix-patches@gnu.org; Wed, 03 Apr 2024 18:53:59 -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 1rs9UV-0004cR-Da for guix-patches@gnu.org; Wed, 03 Apr 2024 18:53:59 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rs9UZ-0001FV-Fy for guix-patches@gnu.org; Wed, 03 Apr 2024 18:54:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#56576] [PATCH v3 1/3] gnu: Add markdeep. References: <20220715145735.5752-1-antero@mailbox.org> In-Reply-To: <20220715145735.5752-1-antero@mailbox.org> Resent-From: Christina O'Donnell Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 03 Apr 2024 22:54:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 56576 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 56576@debbugs.gnu.org Cc: Maxime Devos , Christina O'Donnell , Steve George Received: via spool by 56576-submit@debbugs.gnu.org id=B56576.17121848134640 (code B ref 56576); Wed, 03 Apr 2024 22:54:03 +0000 Received: (at 56576) by debbugs.gnu.org; 3 Apr 2024 22:53:33 +0000 Received: from localhost ([127.0.0.1]:59909 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rs9U4-0001Cm-Sh for submit@debbugs.gnu.org; Wed, 03 Apr 2024 18:53:33 -0400 Received: from vmi993448.contaboserver.net ([194.163.141.236]:45548 helo=mutix.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rs9Ty-0001Bz-Ow for 56576@debbugs.gnu.org; Wed, 03 Apr 2024 18:53:29 -0400 Received: from [86.132.246.87] (host81-147-82-218.range81-147.btcentralplus.com [81.147.82.218]) (Authenticated sender: cdo) by mutix.org (Postfix) with ESMTPSA id 4B329A60825; Thu, 4 Apr 2024 00:53:20 +0200 (CEST) From: Christina O'Donnell Date: Wed, 3 Apr 2024 23:46:32 +0100 Message-ID: X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -3.86 X-Spam-Score: -3.86 X-Migadu-Queue-Id: 29DC63759D X-Migadu-Scanner: mx12.migadu.com X-TUID: s/iKcD97Z8c0 * gnu packages/documentation.scm (markdeep): New variable. Change-Id: I34303377f50740ba357c1bb299c9434079a6e23d --- gnu/packages/documentation.scm | 65 ++++++++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) Hi, I've gone through these patches, making the changes that Maxime listed and that came up from `guix lint`. I've added the additional package markdeep, which is a css/javascript rendering library needed for stddoc. I checked these very carefully, but I'm new to this so it's likely that I've made at least a few mistakes. Everything appears to be working as far as I've tested it. I had anything to test nuklear with, so I'm taking that part on faith. Let me know whether there's anything that I could change or do better for next time. Kind regards, Christina diff --git a/gnu/packages/documentation.scm b/gnu/packages/documentation.scm index 83c4313bd7..da930c7304 100644 --- a/gnu/packages/documentation.scm +++ b/gnu/packages/documentation.scm @@ -37,6 +37,7 @@ (define-module (gnu packages documentation) #:use-module (guix git-download) #:use-module (guix build-system gnu) #:use-module (guix build-system cmake) + #:use-module (guix build-system copy) #:use-module (guix build-system perl) #:use-module (guix build-system python) #:use-module (guix build-system qt) @@ -57,11 +58,13 @@ (define-module (gnu packages documentation) #:use-module (gnu packages graphviz) #:use-module (gnu packages gettext) #:use-module (gnu packages glib) + #:use-module (gnu packages javascript) #:use-module (gnu packages perl) #:use-module (gnu packages pkg-config) #:use-module (gnu packages qt) #:use-module (gnu packages sqlite) #:use-module (gnu packages sphinx) + #:use-module (gnu packages uglifyjs) #:use-module (gnu packages xml) #:use-module (gnu packages xorg)) @@ -453,3 +456,65 @@ (define-public zeal (description "Zeal is a simple offline documentation browser inspired by Dash.") (license license:gpl3+)))) + +(define-public markdeep + (package + (name "markdeep") + (version "1.16") + (home-page "https://casual-effects.com/markdeep/") + (source + (origin (method git-fetch) + (uri (git-reference + (url "https://github.com/morgan3d/markdeep") + (commit (string-append "v0" version)))) + (sha256 + (base32 "05bvw3993xh1260ckclwk4jw38hvgiff0b2940ryhbhz0p1k41l8")))) + (build-system copy-build-system) + (arguments + (list #:modules '((guix build utils) + (guix build copy-build-system) + (ice-9 popen)) + #:install-plan ''(("." "/share/markdeep/")) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-urls + (lambda _ + (for-each (lambda (filename) + + (substitute* filename + ;; Don't include a reference to the remote version. + (("") + "") + (("MATHJAX_URL = .*$") + ;; Use our local copy of mathjax + (string-append "MATHJAX_URL = 'file://" #$js-mathjax + "/share/javascript/es5/tex-mml-chtml.js'")))) + (find-files "." (lambda (file stat) + (string-suffix? ".js" file)))))) + (add-before 'install 'minify + (lambda _ + (for-each (lambda (filename) + (let ((minified-filename + (string-append (string-drop-right filename 3) + ".min.js"))) + (format #t "~a -> ~a~%" filename minified-filename) + (let ((minified (open-pipe* OPEN_READ "uglifyjs" filename))) + (call-with-output-file minified-filename + (lambda (port) + (dump-port minified port))) + + (let ((exit (close-pipe minified))) + (unless (zero? exit) + (error "uglifyjs failed" exit)))))) + (find-files "latest" + (lambda (path stat) + (and (string-suffix? ".js" path) + (not (string-suffix? ".min.js" path))))))))))) + (inputs (list js-mathjax)) + (native-inputs (list uglifyjs)) + (synopsis "Tool for displaying markdown documents in a web-browser") + (description "Markdeep is a technology for writing plain text documents that can +be displayed in any web browser, whether local or remote. It supports diagrams, +calendars, equations, and other features as extensions of Markdown syntax.") + (license license:bsd-2))) base-commit: 4d994f98a49e1a6e58b9b0b512a05efc1c431a50 -- 2.41.0