Merge pull request #10470 from Mathnerd314/unicode-coverage

Improve Unicode coverage
This commit is contained in:
Thomas Tuegel 2015-10-19 05:46:39 -05:00
commit 947fdd6b7e
12 changed files with 354 additions and 56 deletions

View File

@ -0,0 +1,57 @@
{stdenv, fetchurl, unzip, lib }:
let
fonts = {
aegean = { version = "8.00"; file = "Aegean.zip"; sha256 = "09pmazcpxhkx3l8h4gxiixihi1c49pli5gvlcm1b6sbf4xvf9kwm";
description = "Scripts and symbols of the Aegean world"; };
textfonts = { version = "6.00"; file = "Textfonts.zip"; sha256 = "10m6kpyj8cc0b4qxxi78akiyjxcbhxj2wmbicdcfh008jibbaxsz";
description = "Fonts based on early Greek editions"; };
symbola = { version = "8.00"; file = "Symbola.zip"; sha256 = "1lfs2j816332ysvpb5ibj2gwpmyqyispqdl7skkshf2gra18hmhd";
description = "Basic Latin, Greek, Cyrillic and many Symbol blocks of Unicode"; };
aegyptus = { version = "6.00"; file = "Aegyptus.zip"; sha256 = "092vci45wp9x0yky6dcfky4bs4avaxn6xpai3bs74gxskd2j9s3q";
description = "Egyptian Hieroglyphs, Coptic, Meroitic"; };
akkadian = { version = "7.13"; file = "Akkadian.zip"; sha256 = "1jd2fb6jnwpdwgkidsi2pnw0nk2cpya8k85299w591sqslfkxyij";
description = "Sumero-Akkadian Cuneiform"; };
anatolian = { version = "5.02"; file = "Anatolian.zip"; sha256 = "0arm58sijzk0bqmfb70k1sjvq79wgw16hx3j2g4l8qz4sv05bp8l";
description = "Anatolian Hieroglyphs"; };
maya = { version = "4.14"; file = "Maya.zip"; sha256 = "0l97racgncrhb96mfbsx8dr5n4j289iy0nnwhxf9b21ns58a9x4f";
description = "Maya Hieroglyphs"; };
unidings = { version = "8.00"; file = "Unidings.zip"; sha256 = "1i0z3mhgj4680188lqpmk7rx3yiz4l7yybb4wq6zk35j75l28irm";
description = "Glyphs and Icons for blocks of The Unicode Standard"; };
musica = { version = "3.12"; file = "Musica.zip"; sha256 = "079vyb0mpxvlcf81d5pqh9dijkcvidfbcyvpbgjpmgzzrrj0q210";
description = "Musical Notation"; };
analecta = { version = "5.00"; file = "Analecta.zip"; sha256 = "0rphylnz42fqm1zpx5jx60k294kax3sid8r2hx3cbxfdf8fnpb1f";
description = "Coptic, Gothic, Deseret"; };
};
mkpkg = name_: {version, file, sha256, description}:
stdenv.mkDerivation rec {
name = "${name_}-${version}";
src = fetchurl {
url = "http://users.teilar.gr/~g1951d/${file}";
inherit sha256;
};
buildInputs = [ unzip ];
sourceRoot = ".";
installPhase = ''
mkdir -p $out/share/fonts/truetype
cp -v *.ttf $out/share/fonts/truetype/
mkdir -p "$out/doc/${name}"
cp -v *.docx *.pdf *.xlsx "$out/doc/${name}/"
'';
meta = {
inherit description;
# In lieu of a license:
# Fonts in this site are offered free for any use;
# they may be installed, embedded, opened, edited, modified, regenerated, posted, packaged and redistributed.
license = stdenv.lib.licenses.free;
homepage = http://users.teilar.gr/~g1951d/;
};
};
in
lib.mapAttrs mkpkg fonts

View File

@ -0,0 +1,36 @@
{ stdenv, fetchurl, unzip }:
stdenv.mkDerivation rec {
name = "hanazono-${version}";
version = "20141012";
src = fetchurl {
url = "mirror://sourceforgejp/hanazono-font/62072/hanazono-20141012.zip";
sha256 = "020jhqnzm9jvkmfvvyk1my26ncwxbnb9yc8v7am252jwrifji9q6";
};
buildInputs = [ unzip ];
sourceRoot = ".";
installPhase = ''
mkdir -p $out/share/fonts/hanazono
cp *.ttf $out/share/fonts/hanazono
mkdir -p $out/share/doc/hanazono
cp *.txt $out/share/doc/hanazono
'';
meta = with stdenv.lib; {
description = "Free kanji font containing 96,327 characters";
homepage = http://fonts.jp/hanazono/;
# Dual-licensed under OFL and the following:
# This font is a free software.
# Unlimited permission is granted to use, copy, and distribute it, with
# or without modification, either commercially and noncommercially.
# THIS FONT IS PROVIDED "AS IS" WITHOUT WARRANTY.
license = [ licenses.ofl licenses.free ];
maintainers = with maintainers; [ mathnerd314 ];
platforms = platforms.all;
};
}

View File

@ -1,22 +1,58 @@
{ stdenv, fetchurl }:
stdenv.mkDerivation {
name = "lohit-fonts-20140220";
src = fetchurl {
url = https://fedorahosted.org/releases/l/o/lohit/lohit-ttf-20140220.tar.gz;
sha256 = "1rmgr445hw1n851ywy28csfvswz1i6hnc8mzp88qw2xk9j4dn32d";
{ stdenv, fetchurl, lib }:
let
fonts = {
assamese = { version = "2.91.3" ; sha256 = "0kbdvi8f7vbvsain9zmnj9h43a6bmdkhk5c2wzg15100w7wf6lpq"; };
bengali = { version = "2.91.3" ; sha256 = "1wdd2dkqaflf6nm5yc7llkfxin6g0zb2sbcd5g2xbrl0gwwcmkij"; };
devanagari = { version = "2.95.2" ; sha256 = "1ss0j0pcfrg1vsypnm0042y4bn7b84mi6lbfsvr6rs89lb5swvn2"; };
gujarati = { version = "2.92.2-and-4.2.2" ; sha256 = "1i27yjhn3x31a89x1hjs6rskdwp2kh0hibq1xiz3rgqil2m0jar6"; };
gurmukhi = { version = "2.91.0" ; sha256 = "0z8a30mnyhlfvqhnggfk0369hqg779ihqyhcmpxj0sf9dmb1i0mj"; }; # renamed from Punjabi
kannada = { version = "2.5.3" ; sha256 = "1x9fb5z1bwmfi0y1fdnzizzjxhbxp272wxznx36063kjf25bb9pi"; };
malayalam = { version = "2.92.0" ; sha256 = "1syv1irxh5xl0z0d5kwankhlmi7s2dg4wpp58nq0mkd3rhm5q8qw"; };
marathi = { version = "2.94.0" ; sha256 = "0y9sca6gbfbafv52v0n2r1xfs8rg6zmqs4vp9sjfc1c6yqhzagl4"; };
nepali = { version = "2.94.0" ; sha256 = "0c56141rpxc30581i3gisg8kfaadxhqjhgshni6g7a7rn6l4dx17"; };
odia = { version = "2.91.0" ; sha256 = "15iz9kdf9k5m8wcn2iqlqjm758ac3hvnk93va6kac06frxnhw9lp"; }; # renamed from Oriya
tamil-classical = { version = "2.5.3" ; sha256 = "0ci4gk8qhhysjza69nncgmqmal8s4n8829icamvlzbmjdd4s2pij"; };
tamil = { version = "2.91.1" ; sha256 = "1ir6kjl48apwk41xbpj0x458k108s7i61yzpkfhqcy1fkcr7cngj"; };
telugu = { version = "2.5.4" ; sha256 = "06gdba7690y20l7nsi8fnnimim5hlq7hik0mpk2fzw4w39hjybk9"; };
};
installPhase = ''
mkdir -p $out/share/fonts/truetype
cp *.ttf $out/share/fonts/truetype
'';
meta = with stdenv.lib; {
homepage = https://fedorahosted.org/lohit/;
description = "Fonts for 21 Indian languages";
license = licenses.ofl;
maintainers = [ maintainers.ttuegel ];
platforms = platforms.all;
gplfonts = {
# GPL fonts removed from later releases
kashmiri = { version = "2.4.3" ; sha256 = "0ax8xzv4pz17jnsjdklawncsm2qn7176wbxykswygpzdd5lr0gg9"; };
konkani = { version = "2.4.3" ; sha256 = "03zc27z26a60aaggrqx4d6l0jgggciq8p83v6vgg0k6l3apvcp45"; };
maithili = { version = "2.4.3" ; sha256 = "0aqwnhq1namvvb77f2vssahixqf4xay7ja4q8qc312wxkajdqh4a"; };
sindhi = { version = "2.4.3" ; sha256 = "00imfbn01yc2g5zdyydks9w3ndkawr66l9qk2idlvw3yz3sw2kf1"; };
};
}
mkpkg = license: name: {version, sha256}:
stdenv.mkDerivation {
name = "lohit-${name}-${version}";
src = fetchurl {
url = "https://fedorahosted.org/releases/l/o/lohit/lohit-${name}-ttf-${version}.tar.gz";
inherit sha256;
};
installPhase = ''
mkdir -p $out/share/fonts/truetype
cp -v *.ttf $out/share/fonts/truetype/
mkdir -p $out/etc/fonts/conf.d
cp -v *.conf $out/etc/fonts/conf.d
mkdir -p "$out/share/doc/lohit-${name}"
cp -v ChangeLog* COPYRIGHT* "$out/share/doc/lohit-${name}/"
'';
meta = {
inherit license;
homepage = https://fedorahosted.org/lohit/;
maintainers = [ lib.maintainers.mathnerd314 lib.maintainers.ttuegel ];
# Set a non-zero priority to allow easy overriding of the
# fontconfig configuration files.
priority = 5;
};
};
in
# Technically, GPLv2 with usage exceptions
lib.mapAttrs (mkpkg lib.licenses.gpl2) gplfonts //
lib.mapAttrs (mkpkg lib.licenses.ofl) fonts

View File

@ -0,0 +1,30 @@
{ stdenv, fetchurl, p7zip }:
stdenv.mkDerivation rec {
name = "marathi-cursive-${version}";
version = "1.2";
src = fetchurl {
url = "https://github.com/MihailJP/MarathiCursive/releases/download/${version}/MarathiCursive-${version}.7z";
sha256 = "0zhqkkfkz5mhfz8xv305s16h80p9v1iva829fznxd2c44ngyplmc";
};
buildInputs = [ p7zip ];
unpackCmd = "7z x $curSrc";
installPhase = ''
mkdir -p $out/share/fonts/marathi-cursive
cp -v *.otf *.ttf $out/share/fonts/marathi-cursive
mkdir -p $out/share/doc/${name}
cp -v README *.txt $out/share/doc/${name}
'';
meta = with stdenv.lib; {
homepage = https://github.com/MihailJP/marathi-cursive;
description = "Modi script font with Graphite and OpenType support";
maintainers = with maintainers; [ mathnerd314 ];
license = licenses.mit; # It's the M+ license, M+ is MIT(-ish)
platforms = platforms.all;
};
}

View File

@ -0,0 +1,20 @@
{ lib, runCommand, fetchurl }:
runCommand "mro-unicode-2013-05-25" {
src = fetchurl {
url = "https://github.com/phjamr/MroUnicode/raw/master/MroUnicode-Regular.ttf";
sha256 = "1za74ych0sh97ks6qp9iqq9jankgnkrq65s350wsbianwi72di45";
};
meta = with lib; {
homepage = https://github.com/phjamr/MroUnicode;
description = "Unicode-compliant Mro font";
maintainers = with maintainers; [ mathnerd314 ];
license = licenses.ofl;
platforms = platforms.all;
};
}
''
mkdir -p $out/share/fonts/truetype
cp $src $out/share/fonts/truetype/MroUnicode-Regular.ttf
''

View File

@ -0,0 +1,30 @@
{ stdenv, fetchurl, p7zip }:
stdenv.mkDerivation rec {
name = "oldsindhi-${version}";
version = "0.1";
src = fetchurl {
url = "https://github.com/MihailJP/oldsindhi/releases/download/0.1/OldSindhi-0.1.7z";
sha256 = "1sbmxyxi81k88hkfw7gnnpgd5vy2vyj5y5428cd6nz4zlaclgq8z";
};
buildInputs = [ p7zip ];
unpackCmd = "7z x $curSrc";
installPhase = ''
mkdir -p $out/share/fonts/truetype
mkdir -p $out/share/doc/${name}
cp -v *.ttf $out/share/fonts/truetype/
cp -v README *.txt $out/share/doc/${name}
'';
meta = with stdenv.lib; {
homepage = https://github.com/MihailJP/oldsindhi;
description = "Free Sindhi Khudabadi font";
maintainers = with maintainers; [ mathnerd314 ];
license = licenses.bsd2;
platforms = platforms.all;
};
}

View File

@ -0,0 +1,20 @@
{ lib, runCommand, fetchurl }:
runCommand "sampradaya-2015-05-26" {
src = fetchurl {
url = "https://bitbucket.org/OorNaattaan/sampradaya/raw/afa9f7c6ab17e14bd7dd74d0acaec2f75454dfda/Sampradaya.ttf";
sha256 = "0110k1yh5kz3f04wp72bfz59pxjc7p6jv7m5p0rqn1kqbf7g3pck";
};
meta = with lib; {
homepage = https://bitbucket.org/OorNaattaan/sampradaya/;
description = "Unicode-compliant Grantha font";
maintainers = with maintainers; [ mathnerd314 ];
license = licenses.ofl; # See font metadata
platforms = platforms.all;
};
}
''
mkdir -p $out/share/fonts/truetype
cp $src $out/share/fonts/truetype/Sampradaya.ttf
''

View File

@ -0,0 +1,28 @@
{ lib, runCommand, fetchurl }:
runCommand "signwriting-1.1.4" {
src1 = fetchurl {
url = "https://github.com/Slevinski/signwriting_2010_fonts/raw/61c8e7123a1168657b5d34d85266a637f67b9d2b/fonts/SignWriting%202010.ttf";
name = "SignWriting_2010.ttf";
sha256 = "1abjzykbjx2hal8mrxp51rvblv3q84akyn9qhjfaj20rwphkf5zj";
};
src2 = fetchurl {
url = "https://github.com/Slevinski/signwriting_2010_fonts/raw/61c8e7123a1168657b5d34d85266a637f67b9d2b/fonts/SignWriting%202010%20Filling.ttf";
name = "SignWriting_2010_Filling.ttf";
sha256 = "0am5wbf7jdy9szxkbsc5f3959cxvbj7mr0hy1ziqmkz02c6xjw2m";
};
meta = with lib; {
homepage = https://github.com/Slevinski/signwriting_2010_fonts;
description = "Typeface for written sign languages";
maintainers = with maintainers; [ mathnerd314 ];
license = licenses.ofl;
platforms = platforms.all;
};
}
''
mkdir -p $out/share/fonts/truetype
cp $src1 $out/share/fonts/truetype/SignWriting_2010.ttf
cp $src2 $out/share/fonts/truetype/SignWriting_2010_Filling.ttf
''

View File

@ -1,34 +0,0 @@
{stdenv, fetchurl, unzip }:
stdenv.mkDerivation rec {
name = "symbola-8.00";
src = fetchurl {
url = "http://users.teilar.gr/~g1951d/Symbola.zip";
sha256 = "1lfs2j816332ysvpb5ibj2gwpmyqyispqdl7skkshf2gra18hmhd";
};
buildInputs = [ unzip ];
phases = [ "installPhase" ];
installPhase = ''
unzip ${src}
mkdir -p $out/share/fonts/truetype
cp -v Symbola.ttf $out/share/fonts/truetype/
cp -v Symbola_hint.ttf $out/share/fonts/truetype/
mkdir -p "$out/doc/${name}"
cp -v Symbola.docx "$out/doc/${name}/"
cp -v Symbola.pdf "$out/doc/${name}/"
'';
meta = {
description = "Basic Latin, Greek, Cyrillic and many Symbol blocks of Unicode";
# In lieu of a license:
# Fonts in this site are offered free for any use;
# they may be installed, embedded, opened, edited, modified, regenerated, posted, packaged and redistributed.
license = stdenv.lib.licenses.free;
homepage = http://users.teilar.gr/~g1951d/;
};
}

View File

@ -0,0 +1,25 @@
{ lib, runCommand, fetchurl }:
{
tai-ahom = runCommand "tai-ahom-2015-07-06" {
src = fetchurl {
url = "https://github.com/enabling-languages/tai-languages/blob/b57a3ea4589af69bb8e87c6c4bb7cd367b52f0b7/ahom/.fonts/ttf/.original/AhomUnicode_FromMartin.ttf?raw=true";
sha256 = "0zpjsylm29qc3jdv5kv0689pcirai46j7xjp5dppi0fmzxaxqnsk";
};
meta = with lib; {
homepage = https://github.com/enabling-languages/tai-languages;
description = "Unicode-compliant Tai Ahom font";
maintainers = with maintainers; [ mathnerd314 ];
license = licenses.ofl; # See font metadata
platforms = platforms.all;
};
}
''
mkdir -p $out/share/fonts/truetype
cp $src $out/share/fonts/truetype/AhomUnicode.ttf
'';
# TODO: package others (Khamti Shan, Tai Aiton, Tai Phake, and/or Assam Tai)
}

View File

@ -0,0 +1,29 @@
{ stdenv, fetchurl }:
stdenv.mkDerivation rec {
name = "unifont_upper-${version}";
version = "8.0.01";
ttf = fetchurl {
url = "http://unifoundry.com/pub/unifont-8.0.01/font-builds/${name}.ttf";
sha256 = "0ffqm85bk345pnql1x0rbg0z31472y844xibb27njjg4avb21lga";
};
phases = "installPhase";
installPhase =
''
mkdir -p $out/share/fonts/truetype
cp -v ${ttf} $out/share/fonts/truetype/unifont_upper.ttf
'';
meta = with stdenv.lib; {
description = "Unicode font for glyphs above the Unicode Basic Multilingual Plane";
homepage = http://unifoundry.com/unifont.html;
# Basically GPL2+ with font exception.
license = http://unifoundry.com/LICENSE.txt;
maintainers = [ maintainers.mathnerd314 ];
platforms = platforms.all;
};
}

View File

@ -10550,6 +10550,8 @@ let
hicolor_icon_theme = callPackage ../data/icons/hicolor-icon-theme { };
hanazono = callPackage ../data/fonts/hanazono { };
inconsolata = callPackage ../data/fonts/inconsolata {};
inconsolata-lgc = callPackage ../data/fonts/inconsolata/lgc.nix {};
@ -10577,7 +10579,13 @@ let
lobster-two = callPackage ../data/fonts/lobster-two {};
lohit-fonts = callPackage ../data/fonts/lohit-fonts { };
# lohit-fonts.assamese lohit-fonts.bengali lohit-fonts.devanagari lohit-fonts.gujarati lohit-fonts.gurmukhi
# lohit-fonts.kannada lohit-fonts.malayalam lohit-fonts.marathi lohit-fonts.nepali lohit-fonts.odia
# lohit-fonts.tamil-classical lohit-fonts.tamil lohit-fonts.telugu
# lohit-fonts.kashmiri lohit-fonts.konkani lohit-fonts.maithili lohit-fonts.sindhi
lohit-fonts = recurseIntoAttrs ( callPackages ../data/fonts/lohit-fonts { } );
marathi-cursive = callPackage ../data/fonts/marathi-cursive { };
manpages = callPackage ../data/documentation/man-pages { };
@ -10593,6 +10601,8 @@ let
mplus-outline-fonts = callPackage ../data/fonts/mplus-outline-fonts { };
mro-unicode = callPackage ../data/fonts/mro-unicode { };
nafees = callPackage ../data/fonts/nafees { };
inherit (callPackages ../data/fonts/noto-fonts {})
@ -10604,6 +10614,8 @@ let
oldstandard = callPackage ../data/fonts/oldstandard { };
oldsindhi = callPackage ../data/fonts/oldsindhi { };
open-dyslexic = callPackage ../data/fonts/open-dyslexic { };
opensans-ttf = callPackage ../data/fonts/opensans-ttf { };
@ -10626,15 +10638,20 @@ let
perl = perl516; # syntax error at troffprepro line 49, near "do subst("
};
sampradaya = callPackage ../data/fonts/sampradaya { };
shared_mime_info = callPackage ../data/misc/shared-mime-info { };
shared_desktop_ontologies = callPackage ../data/misc/shared-desktop-ontologies { };
signwriting = callPackage ../data/fonts/signwriting { };
stdmanpages = callPackage ../data/documentation/std-man-pages { };
stix-otf = callPackage ../data/fonts/stix-otf { };
symbola = callPackage ../data/fonts/symbola { };
inherit (callPackages ../data/fonts/gdouros { })
aegean textfonts symbola aegyptus akkadian anatolian maya unidings musica analecta;
iana_etc = callPackage ../data/misc/iana-etc { };
@ -10666,6 +10683,8 @@ let
source-han-sans-simplified-chinese = sourceHanSansPackages.simplified-chinese;
source-han-sans-traditional-chinese = sourceHanSansPackages.traditional-chinese;
inherit (callPackages ../data/fonts/tai-languages { }) tai-ahom;
tango-icon-theme = callPackage ../data/icons/tango-icon-theme { };
themes = name: callPackage (../data/misc/themes + ("/" + name + ".nix")) {};
@ -10690,6 +10709,8 @@ let
unifont = callPackage ../data/fonts/unifont { };
unifont_upper = callPackage ../data/fonts/unifont_upper { };
vistafonts = callPackage ../data/fonts/vista-fonts { };
wqy_microhei = callPackage ../data/fonts/wqy-microhei { };