mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-27 22:03:54 +03:00
twitter-color-emoji: 12.1.5 → 13.0.1
This commit is contained in:
parent
0cfc9f47ce
commit
fe3d667a0f
@ -3,9 +3,8 @@
|
||||
|
||||
{ stdenv
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, cairo
|
||||
, graphicsmagick
|
||||
, imagemagick
|
||||
, pkg-config
|
||||
, pngquant
|
||||
, python3
|
||||
@ -15,7 +14,7 @@
|
||||
}:
|
||||
|
||||
let
|
||||
version = "12.1.5";
|
||||
version = "13.0.1";
|
||||
|
||||
twemojiSrc = fetchFromGitHub {
|
||||
name = "twemoji";
|
||||
@ -25,6 +24,9 @@ let
|
||||
sha256 = "0acinlv2l3s1jga2i9wh16mvgkxw4ipzgvjx8c80zd104lpdpgd9";
|
||||
};
|
||||
|
||||
pythonEnv =
|
||||
python3.withPackages (p: [ p.fonttools p.nototools ]);
|
||||
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "twitter-color-emoji";
|
||||
@ -44,23 +46,14 @@ stdenv.mkDerivation rec {
|
||||
|
||||
nativeBuildInputs = [
|
||||
cairo
|
||||
graphicsmagick
|
||||
imagemagick
|
||||
pkg-config
|
||||
pngquant
|
||||
python3
|
||||
python3.pkgs.nototools
|
||||
pythonEnv
|
||||
which
|
||||
zopfli
|
||||
];
|
||||
|
||||
patches = [
|
||||
# ImageMagick -> GraphicsMagick
|
||||
(fetchpatch {
|
||||
url = "https://src.fedoraproject.org/rpms/twitter-twemoji-fonts/raw/07778605d50696f6aa929020e82611a01d254c90/f/noto-emoji-use-gm.patch";
|
||||
sha256 = "06vg16z79s5adyjy8r3mr8fd391b1hi4xkqvbzkmnjwaai7p08lk";
|
||||
})
|
||||
];
|
||||
|
||||
postPatch = let
|
||||
templateSubstitutions = stdenv.lib.concatStringsSep "; " [
|
||||
''s#Noto Color Emoji#Twitter Color Emoji#''
|
||||
@ -74,7 +67,7 @@ stdenv.mkDerivation rec {
|
||||
''s#http://scripts.sil.org/OFL#http://creativecommons.org/licenses/by/4.0/#''
|
||||
];
|
||||
in ''
|
||||
patchShebangs ./flag_glyph_name.py
|
||||
${noto-fonts-emoji.postPatch}
|
||||
|
||||
sed '${templateSubstitutions}' NotoColorEmoji.tmpl.ttx.tmpl > TwitterColorEmoji.tmpl.ttx.tmpl
|
||||
pushd ${twemojiSrc.name}/assets/72x72/
|
||||
@ -88,6 +81,8 @@ stdenv.mkDerivation rec {
|
||||
"EMOJI=TwitterColorEmoji"
|
||||
"EMOJI_SRC_DIR=${twemojiSrc.name}/assets/72x72"
|
||||
"BODY_DIMENSIONS=76x72"
|
||||
# twemoji contains some codepoints noto doesn't like
|
||||
"BYPASS_SEQUENCE_CHECK=True"
|
||||
];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
Loading…
Reference in New Issue
Block a user