3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/data/fonts/ricty/default.nix
Marcial Gaißert bc09bf4d71 ricty: change mirror and homepage url
The old mirror and homepage at www.rs.tus.ac.jp return a 403
Forbidden.
2019-10-20 16:47:30 +02:00

38 lines
1,011 B
Nix

{ stdenv, fetchurl, google-fonts, migu, fontforge, which }:
stdenv.mkDerivation rec {
pname = "ricty";
version = "4.1.1";
src = fetchurl {
url = "http://www.yusa.lab.uec.ac.jp/~yusa/ricty/ricty_generator-${version}.sh";
sha256 = "03fngb8f5hl7ifigdm5yljhs4z2x80cq8y8kna86d07ghknhzgw6";
};
unpackPhase = ''
install -m 0770 $src ricty_generator.sh
'';
patchPhase = ''
sed -i 's/fonts_directories=".*"/fonts_directories="$inconsolata $migu"/' ricty_generator.sh
'';
buildInputs = [ google-fonts migu fontforge which ];
buildPhase = ''
inconsolata=${google-fonts} migu=${migu} ./ricty_generator.sh auto
'';
installPhase = ''
install -m644 --target $out/share/fonts/truetype/ricty -D Ricty-*.ttf
'';
meta = with stdenv.lib; {
description = "A high-quality Japanese font based on Inconsolata and Migu 1M";
homepage = http://www.yusa.lab.uec.ac.jp/~yusa/ricty.html;
license = licenses.unfree;
maintainers = [ maintainers.mikoim ];
};
}