GNU bug report logs -
#27049
[PATCH] gnu: Add mathjax.
Previous Next
Reported by: Arun Isaac <arunisaac <at> systemreboot.net>
Date: Tue, 23 May 2017 21:44:01 UTC
Severity: normal
Tags: patch
Done: Arun Isaac <arunisaac <at> systemreboot.net>
Bug is archived. No further changes may be made.
Full log
Message #53 received at 27049 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/fonts.scm (font-mathjax): New variable.
---
gnu/packages/fonts.scm | 44 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 44 insertions(+)
diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm
index 73d76a461..15f70dddd 100644
--- a/gnu/packages/fonts.scm
+++ b/gnu/packages/fonts.scm
@@ -19,6 +19,7 @@
;;; Copyright © 2017 Alex Griffin <a <at> ajgrf.com>
;;; Copyright © 2017 Clément Lassieur <clement <at> lassieur.org>
;;; Copyright © 2017 Brendan Tildesley <brendan.tildesley <at> openmailbox.org>
+;;; Copyright © 2017 Arun Isaac <arunisaac <at> systemreboot.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -1227,3 +1228,46 @@ Ensuring readability and clarity at both large and small sizes, these icons
have been optimized for beautiful display on all common platforms and display
resolutions.")
(license license:asl2.0)))
+
+(define-public font-mathjax
+ (package
+ (name "font-mathjax")
+ (version "2.7.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append
+ "https://github.com/mathjax/MathJax/archive/"
+ version ".tar.gz"))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "0sbib5lk0jrvbq6s72ag6ss3wjlz5wnk07ddxij1kp96yg3c1d1b"))))
+ (build-system trivial-build-system)
+ (arguments
+ `(#:modules ((guix build utils))
+ #:builder
+ (begin
+ (use-modules (guix build utils)
+ (ice-9 match))
+ (setenv "PATH" (string-join (map (match-lambda
+ ((_ . input-path)
+ (string-append input-path "/bin")))
+ %build-inputs)
+ ":"))
+ (let ((install-directory (string-append %output "/share/fonts/mathjax")))
+ (mkdir-p install-directory)
+ (zero? (system* "tar" "-C" install-directory "-xvf"
+ (assoc-ref %build-inputs "source")
+ "MathJax-2.7.1/fonts" "--strip" "2"))))))
+ (native-inputs
+ `(("gzip" ,gzip)
+ ("tar" ,tar)))
+ (home-page "https://www.mathjax.org/")
+ (synopsis "JavaScript display engine for LaTeX, MathML, and AsciiMath")
+ (description "MathJax is a JavaScript display engine for LaTeX, MathML,
+and AsciiMath notation that works in all modern browsers. It requires no
+plugins or software to be installed on the browser. So the page author can
+write web documents that include mathematics and be confident that readers will
+be able to view it naturally and easily.")
+ (license license:asl2.0)))
--
2.12.2
This bug report was last modified 7 years and 355 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.