about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--lib/licenses.nix5
-rw-r--r--pkgs/data/fonts/garamond-libre/default.nix26
-rw-r--r--pkgs/top-level/all-packages.nix2
3 files changed, 33 insertions, 0 deletions
diff --git a/lib/licenses.nix b/lib/licenses.nix
index 612cfba6c7305..f54ab464357b3 100644
--- a/lib/licenses.nix
+++ b/lib/licenses.nix
@@ -969,6 +969,11 @@ in mkLicense lset) ({
     fullName = "wxWindows Library Licence, Version 3.1";
   };
 
+  x11 = {
+    spdxId = "X11";
+    fullName = "X11 License";
+  };
+
   xfig = {
     fullName = "xfig";
     url = "http://mcj.sourceforge.net/authors.html#xfig"; # https is broken
diff --git a/pkgs/data/fonts/garamond-libre/default.nix b/pkgs/data/fonts/garamond-libre/default.nix
new file mode 100644
index 0000000000000..202ae2ce41f1f
--- /dev/null
+++ b/pkgs/data/fonts/garamond-libre/default.nix
@@ -0,0 +1,26 @@
+{ lib, fetchzip }:
+
+fetchzip rec {
+  pname = "garamond-libre";
+  version = "1.4";
+
+  url = "https://github.com/dbenjaminmiller/garamond-libre/releases/download/${version}/garamond-libre_${version}.zip";
+  stripRoot = false;
+
+  postFetch = ''
+    install -Dm644 $out/*.otf -t $out/share/fonts/opentype
+    shopt -s extglob dotglob
+    rm -rf $out/!(share)
+    shopt -u extglob dotglob
+  '';
+
+  sha256 = "6WiuUe3CHXXL/0G7wURvSIgWPQ4isl50e3OBQ+ui0U4=";
+
+  meta = with lib; {
+    homepage = "https://github.com/dbenjaminmiller/garamond-libre";
+    description = "Garamond Libre font family";
+    maintainers = with maintainers; [ drupol ];
+    license = licenses.x11;
+    platforms = platforms.all;
+  };
+}
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index da56bca832033..de21ad3f8a711 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -26587,6 +26587,8 @@ with pkgs;
 
   freepats = callPackage ../data/misc/freepats { };
 
+  garamond-libre = callPackage ../data/fonts/garamond-libre { };
+
   g15daemon = callPackage ../os-specific/linux/g15daemon {};
 
   galatia-sil = callPackage ../data/fonts/galatia-sil { };