Subject: bug#63707: closed (Re: [bug#63707] [PATCH] gnu: Add font-ipa.)

From: [email-masked] (GNU bug Tracking System)
Date: Sat, 01 Jul 2023 10:24:01 +0000

Your bug report

#63707: [PATCH] gnu: Add font-ipa.

which was filed against the guix-patches package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
63707: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=63707
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: [bug#63707] [PATCH] gnu: Add font-ipa.
From: Nicolas Goaziou <[email-masked]>
To: Wolf <[email-masked]>
Cc: [email-masked], Zhu Zihao <[email-masked]>,宋文武 <[email-masked]>
Date: Sat, 01 Jul 2023 12:23:34 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

Hello,

Wolf <[email-masked]> writes:

> * gnu/packages/fonts.scm (font-ipa): New variable.

Applied with the changes below. Thank you.
> ---
> +    (build-system font-build-system)
> +    (arguments
> +     (list #:phases #~(modify-phases %standard-phases
> +                        (add-after 'unpack 'make-read-only

I fixed indentation, which consumes way too much horizontal space here.

> +                        (add-after 'install 'install-doc
> +                          (lambda* (#:key outputs #:allow-other-keys)

outputs argument is not necessary when using G-expressions. You don't
use it either in your phases.

> +    (description "Japanese outline fonts by Information-technology Promotion
> +Agency, Japan (IPA)")

The description should consist of full sentences:

  "These package provides Japanese outline fonts..."

Regards,
-- 
Nicolas Goaziou

Subject: [PATCH] gnu: Add font-ipa.
From: Wolf <[email-masked]>
To: [email-masked]
Cc: Wolf <[email-masked]>
Date: Wed, 24 May 2023 23:22:53 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

* gnu/packages/fonts.scm (font-ipa): New variable.
---
 gnu/packages/fonts.scm | 46 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 46 insertions(+)

diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm
index 12c6b04bd7..b159eb7ab0 100644
--- a/gnu/packages/fonts.scm
+++ b/gnu/packages/fonts.scm
@@ -2515,6 +2515,52 @@ (define-public font-meera-inimai
 characteristic so that they sit smoothly with the Tamil glyphs.")
     (license license:silofl1.1)))
 
+(define-public font-ipa
+  (package
+    (name "font-ipa")
+    (version "003.03")
+    (source (origin
+              (method url-fetch/zipbomb)
+              (uri (string-append
+                    "https://moji.or.jp/wp-content/ipafont/IPAfont/" "IPAfont"
+                    (string-join (string-split version #\.) "") ".zip"))
+              (sha256
+               (base32
+                "1rbgfq14ld0cwas6bx5h7pwyv2hkfa8ihnphsaz1brxqliwysmgp"))))
+    (build-system font-build-system)
+    (arguments
+     (list #:phases #~(modify-phases %standard-phases
+                        (add-after 'unpack 'make-read-only
+                          (lambda _
+                            ;; Otherwise the files have the executable bit set.
+                            (for-each (lambda (file)
+                                        (chmod file #o444))
+                                      (find-files "."
+                                                  #:directories? #f))))
+                        (add-after 'install 'install-doc
+                          (lambda* (#:key outputs #:allow-other-keys)
+                            (let ((font+version #$(string-append "IPAfont"
+                                                                 (string-join (string-split
+                                                                               version
+                                                                               #\.)
+                                                                  "")))
+                                  (doc-dir (string-append #$output
+                                                          "/share/doc/"
+                                                          #$name)))
+                              (with-directory-excursion font+version
+                                (mkdir-p doc-dir)
+                                (copy-file (string-append "Readme_"
+                                                          font+version ".txt")
+                                           (string-append doc-dir "/README"))
+                                (copy-file
+                                 "IPA_Font_License_Agreement_v1.0.txt"
+                                 (string-append doc-dir "/LICENSE")))))))))
+    (home-page "https://moji.or.jp/ipafont/")
+    (synopsis "Japanese font from the Information-technology Promotion Agency")
+    (description "Japanese outline fonts by Information-technology Promotion
+Agency, Japan (IPA)")
+    (license license:ipa)))
+
 (define-public font-ipa-ex
   (package
     (name "font-ipa-ex")

base-commit: 6d0571215d661d21cac2150ca45906e77a79a5fb
-- 
2.40.1