summary refs log tree commit diff
path: root/gnu
diff options
context:
space:
mode:
authorMarius Bakke <marius@gnu.org>2020-12-06 16:35:07 +0100
committerMarius Bakke <marius@gnu.org>2020-12-06 18:30:12 +0100
commit25e08f32c1ae1da779fe49f35a816e265367feda (patch)
treea04a84943a94a3f2e1ebcd952022ee84393c5160 /gnu
parent0d59aecf633bc33088948b0a0efb00913c8cf87f (diff)
downloadguix-25e08f32c1ae1da779fe49f35a816e265367feda.tar.gz
gnu: Add fcft.
* gnu/packages/fontutils.scm (fcft): New public variable.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/fontutils.scm49
1 files changed, 49 insertions, 0 deletions
diff --git a/gnu/packages/fontutils.scm b/gnu/packages/fontutils.scm
index 5c763ff1d7..ed2e960938 100644
--- a/gnu/packages/fontutils.scm
+++ b/gnu/packages/fontutils.scm
@@ -32,12 +32,15 @@
   #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages bison)
+  #:use-module (gnu packages build-tools)   ;for meson-0.55
   #:use-module (gnu packages check)
   #:use-module (gnu packages compression)
+  #:use-module (gnu packages datastructures)
   #:use-module (gnu packages flex)
   #:use-module (gnu packages fonts)
   #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages fribidi)
+  #:use-module (gnu packages gcc)
   #:use-module (gnu packages gettext)
   #:use-module (gnu packages ghostscript)
   #:use-module (gnu packages glib)
@@ -46,11 +49,13 @@
   #:use-module (gnu packages gtk)
   #:use-module (gnu packages image)
   #:use-module (gnu packages linux)
+  #:use-module (gnu packages man)
   #:use-module (gnu packages perl)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages python)
   #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages sqlite)
+  #:use-module (gnu packages xdisorg)
   #:use-module (gnu packages xml)
   #:use-module (gnu packages xorg)
   #:use-module ((guix licenses) #:prefix license:)
@@ -828,6 +833,50 @@ maintain the Noto Fonts project.")
                     "file://sample_texts/attributions.txt"
                     "See sample_texts/attributions.txt in the distribution.")))))
 
+(define-public fcft
+  (package
+    (name "fcft")
+    (version "2.3.1")
+    (home-page "https://codeberg.org/dnkl/fcft")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference (url home-page) (commit version)))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1ddzdfq6y9db50zimxfsr955zkpr8y6fk4nrblsl0j0vliywlg8l"))))
+    (build-system meson-build-system)
+    (arguments
+     `(#:meson ,meson-0.55))
+    (native-inputs
+     `(("check" ,check)
+       ("gcc" ,gcc-10)    ;TODO: Remove when the default compiler is > GCC 7.
+       ("pkg-config" ,pkg-config)
+       ("scdoc" ,scdoc)))
+    (propagated-inputs
+     `(;; Required by fcft.pc.
+       ("fontconfig" ,fontconfig)
+       ("freetype" ,freetype)
+       ("harfbuzz" ,harfbuzz)
+       ("pixman" ,pixman)
+       ("tllist" ,tllist)))
+    (synopsis "Font loading and glyph rasterization library")
+    (description
+     "@code{fcft} is a small font loading and glyph rasterization library
+built on-top of FontConfig, FreeType2 and pixman.
+
+It can load and cache fonts from a fontconfig-formatted name string, e.g.
+@code{Monospace:size=12}, optionally with user configured fallback fonts.
+
+After a font has been loaded, you can rasterize glyphs.  When doing so, the
+primary font is first considered.  If it does not have the requested glyph,
+the user configured fallback fonts (if any) are considered.  If none of the
+user configured fallback fonts has the requested glyph, the FontConfig
+generated list of fallback fonts are checked.")
+    ;; The code is distributed under the Expat license, but embeds Unicode
+    ;; data files carrying the Unicode license.
+    (license (list license:expat license:unicode))))
+
 (define-public fontmanager
   (package
    (name "fontmanager")