From 8f4dccf75ddf9bd760371dcc4b2c90c1c0900738 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Wed, 27 Mar 2019 21:57:58 +0200 Subject: 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. --- gnu/packages/fonts.scm | 27 ++++++++------------------- 1 file changed, 8 insertions(+), 19 deletions(-) (limited to 'gnu') 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 -- cgit v1.2.3