about summary refs log tree commit diff
path: root/nixpkgs/pkgs/data/fonts/twemoji-color-font/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/data/fonts/twemoji-color-font/default.nix')
-rw-r--r--nixpkgs/pkgs/data/fonts/twemoji-color-font/default.nix15
1 files changed, 14 insertions, 1 deletions
diff --git a/nixpkgs/pkgs/data/fonts/twemoji-color-font/default.nix b/nixpkgs/pkgs/data/fonts/twemoji-color-font/default.nix
index a9bf3720c071..23ae8e76b1d5 100644
--- a/nixpkgs/pkgs/data/fonts/twemoji-color-font/default.nix
+++ b/nixpkgs/pkgs/data/fonts/twemoji-color-font/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, inkscape, imagemagick, potrace, svgo, scfbuild }:
+{ stdenv, fetchFromGitHub, fetchpatch, inkscape, imagemagick, potrace, svgo, scfbuild }:
 
 stdenv.mkDerivation rec {
   pname = "twemoji-color-font";
@@ -10,6 +10,19 @@ stdenv.mkDerivation rec {
     sha256 = "00pbgqpkq21wl8fs0q1xp49xb10m48b9sz8cdc58flkd2vqfssw2";
   };
 
+  patches = [
+    # Fix build with Inkscape 1.0
+    # https://github.com/eosrei/twemoji-color-font/pull/82
+    (fetchpatch {
+      url = "https://github.com/eosrei/twemoji-color-font/commit/208ad63c2ceb38c528b5237abeb2b85ceedc1d37.patch";
+      sha256 = "TV8I++BEnVUQg7FNbnrEQ/MLV9n3drmspqjmDZgTGFI=";
+      postFetch = ''
+        substituteInPlace $out \
+          --replace "inkscape --without-gui" "inkscape --export-png"
+      '';
+    })
+  ];
+
   nativeBuildInputs = [ inkscape imagemagick potrace svgo scfbuild ];
   # silence inkscape errors about non-writable home
   preBuild = "export HOME=\"$NIX_BUILD_ROOT\"";