summary refs log tree commit diff
path: root/gnu/packages/fonts.scm
diff options
context:
space:
mode:
authorEfraim Flashner <efraim@flashner.co.il>2019-03-27 21:57:58 +0200
committerEfraim Flashner <efraim@flashner.co.il>2019-03-27 22:25:13 +0200
commit8f4dccf75ddf9bd760371dcc4b2c90c1c0900738 (patch)
tree77f15037d03db460dfc57984f6dc607dcab35356 /gnu/packages/fonts.scm
parent3d17dc5d8f92b8312c5ca7fa8022a02cb29b66f1 (diff)
downloadguix-8f4dccf75ddf9bd760371dcc4b2c90c1c0900738.tar.gz
gnu: font-adobe-source-han-sans: Don't use unstable tarball.
* gnu/packages/fonts.scm (font-adobe-source-han-sans)[source]: Download
using git-fetch.
[native-inputs]: Remove gzip, tar.
[arguments]: Adjust build accordingly.
Diffstat (limited to 'gnu/packages/fonts.scm')
-rw-r--r--gnu/packages/fonts.scm27
1 files changed, 8 insertions, 19 deletions
diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm
index 6988443e94..362f92b4ff 100644
--- a/gnu/packages/fonts.scm
+++ b/gnu/packages/fonts.scm
@@ -384,14 +384,14 @@ for long periods of working with computers (8 or more hours per day).")
     (name "font-adobe-source-han-sans")
     (version "1.004")
     (source (origin
-              (method url-fetch)
-              (uri (string-append
-                    "https://github.com/adobe-fonts/source-han-sans/archive/"
-                    version "R.tar.gz"))
-              (file-name (string-append "source-han-sans-" version "R.tar.gz"))
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://github.com/adobe-fonts/source-han-sans.git")
+                     (commit (string-append version "R"))))
+              (file-name (git-file-name name version))
               (sha256
                (base32
-                "1ssx0fw90sy6mj8fv8fv4dgzszpqwbmwpjnlx16g4pvaqzdmybbz"))))
+                "0zm884d8fp5gvirq324050kqv7am9khyqhs9kk4r4rr3jzn61jpk"))))
     (outputs '("out"                 ; OpenType/CFF Collection (OTC), 121 MiB.
                "cn" "jp" "kr" "tw")) ; Region-specific Subset OpenType/CFF.
     (build-system trivial-build-system)
@@ -400,20 +400,12 @@ for long periods of working with computers (8 or more hours per day).")
        #:builder
        (begin
          (use-modules (guix build utils))
-         (let ((tar  (string-append (assoc-ref %build-inputs
-                                               "tar")
-                                    "/bin/tar"))
-               (PATH (string-append (assoc-ref %build-inputs
-                                               "gzip")
-                                    "/bin"))
-               (install-opentype-fonts
+         (let ((install-opentype-fonts
                 (lambda (fonts-dir out)
                   (copy-recursively fonts-dir
                                     (string-append (assoc-ref %outputs out)
                                                    "/share/fonts/opentype")))))
-           (setenv "PATH" PATH)
-           (invoke tar "xvf" (assoc-ref %build-inputs "source"))
-           (chdir (string-append "source-han-sans-" ,version "R"))
+           (chdir (assoc-ref %build-inputs "source"))
            (install-opentype-fonts "OTC" "out")
            (install-opentype-fonts "SubsetOTF/CN" "cn")
            (install-opentype-fonts "SubsetOTF/JP" "jp")
@@ -421,9 +413,6 @@ for long periods of working with computers (8 or more hours per day).")
            (install-opentype-fonts "SubsetOTF/TW" "tw")
            (for-each delete-file (find-files %output "\\.zip$"))
            #t))))
-    (native-inputs
-     `(("gzip" ,gzip)
-       ("tar" ,tar)))
     (home-page "https://github.com/adobe-fonts/source-han-sans")
     (synopsis "Pan-CJK fonts")
     (description