3
0
Fork 0
forked from mirrors/nixpkgs

twemoji-color-font: fix build with Inkscape 1

This commit is contained in:
Jan Tojnar 2020-09-12 23:22:37 +02:00
parent f355352177
commit 24a6d1152d
No known key found for this signature in database
GPG key ID: 7FAB2A15F7A607A4

View file

@ -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\"";