[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
01/14: build-system: font: Handle multiple outputs in the install phase.
From: |
guix-commits |
Subject: |
01/14: build-system: font: Handle multiple outputs in the install phase. |
Date: |
Wed, 18 Sep 2024 05:49:24 -0400 (EDT) |
andreas pushed a commit to branch fonts-split-outputs
in repository guix.
commit 03c091693b6843c349a59ba9e04dcf7a7f026469
Author: 宋文武 <iyzsong@member.fsf.org>
AuthorDate: Sun Apr 21 11:19:22 2024 +0800
build-system: font: Handle multiple outputs in the install phase.
* guix/build/font-build-system.scm (install): Prefer install files into
their
specified outputs (ttf, otf, woff, otb, bdf, pcf, psf).
Change-Id: I2ecd126fe31ce4fc65c59106938e37523b0cc3d2
---
guix/build/font-build-system.scm | 32 +++++++++++++++++++++++++++-----
1 file changed, 27 insertions(+), 5 deletions(-)
diff --git a/guix/build/font-build-system.scm b/guix/build/font-build-system.scm
index 0b1542394a..ad81d07b7b 100644
--- a/guix/build/font-build-system.scm
+++ b/guix/build/font-build-system.scm
@@ -1,6 +1,7 @@
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2017, 2022 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2017 Alex Griffin <a@ajgrf.com>
+;;; Copyright © 2024 宋文武 <iyzsong@envs.net>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -49,13 +50,34 @@ archive, or a font file."
"Install the package contents."
(let* ((out (assoc-ref outputs "out"))
(source (getcwd))
- (fonts (string-append out "/share/fonts")))
- (for-each (cut install-file <> (string-append fonts "/truetype"))
+ (truetype-dir (string-append (or (assoc-ref outputs "ttf") out)
+ "/share/fonts/truetype"))
+ (opentype-dir (string-append (or (assoc-ref outputs "otf") out)
+ "/share/fonts/opentype"))
+ (web-dir (string-append (or (assoc-ref outputs "woff") out)
+ "/share/fonts/web"))
+ (otb-dir (string-append (or (assoc-ref outputs "otb") out)
+ "/share/fonts/misc"))
+ (bdf-dir (string-append (or (assoc-ref outputs "bdf") out)
+ "/share/fonts/misc"))
+ (pcf-dir (string-append (or (assoc-ref outputs "pcf") out)
+ "/share/fonts/misc"))
+ (psf-dir (string-append (or (assoc-ref outputs "psf") out)
+ "/share/consolefonts")))
+ (for-each (cut install-file <> truetype-dir)
(find-files source "\\.(ttf|ttc)$"))
- (for-each (cut install-file <> (string-append fonts "/opentype"))
+ (for-each (cut install-file <> opentype-dir)
(find-files source "\\.(otf|otc)$"))
- (for-each (cut install-file <> (string-append fonts "/web"))
- (find-files source "\\.(woff|woff2)$"))))
+ (for-each (cut install-file <> web-dir)
+ (find-files source "\\.(woff|woff2)$"))
+ (for-each (cut install-file <> otb-dir)
+ (find-files source "\\.otb$"))
+ (for-each (cut install-file <> bdf-dir)
+ (find-files source "\\.bdf$"))
+ (for-each (cut install-file <> pcf-dir)
+ (find-files source "\\.pcf$"))
+ (for-each (cut install-file <> psf-dir)
+ (find-files source "\\.psfu$"))))
(define %license-file-regexp
;; Regexp matching license files commonly found in font packages.
- branch fonts-split-outputs created (now 139d664631), guix-commits, 2024/09/18
- 04/14: gnu: font-ibm-plex: Update to 6.4.0., guix-commits, 2024/09/18
- 01/14: build-system: font: Handle multiple outputs in the install phase.,
guix-commits <=
- 02/14: gnu: font-artifika: Split outputs., guix-commits, 2024/09/18
- 05/14: gnu: font-ibm-plex: Split outputs., guix-commits, 2024/09/18
- 08/14: gnu: font-linuxlibertine: Split outputs., guix-commits, 2024/09/18
- 11/14: gnu: font-orbitron: Split outputs., guix-commits, 2024/09/18
- 07/14: gnu: font-canada1500: Split outputs., guix-commits, 2024/09/18
- 03/14: gnu: font-chivo: Split outputs., guix-commits, 2024/09/18
- 09/14: gnu: font-libertinus: Split outputs., guix-commits, 2024/09/18
- 10/14: gnu: font-recursive: Split outputs., guix-commits, 2024/09/18
- 12/14: gnu: font-spleen: Remove unnecessary custom install phase., guix-commits, 2024/09/18
- 14/14: gnu: font-cormorant: Split outputs., guix-commits, 2024/09/18