git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #170618 from barinov274/fontmake

python39Packages.fontmake: init at 3.3.0

commitfe8daa36b6264508d6a7c04927c8dc2902227d9f authorSandro <sandro.jaeckel@gmail.com> dateWed 4 May 2022, 15:04 (5 years ago) parenta96011d1eaa0f5
8 files changed+195−5
pkgs/development/python-modules/fontmake/default.nix+42 pkgs/development/python-modules/fonttools/default.nix+7−3 pkgs/development/python-modules/glyphslib/default.nix+59 pkgs/development/python-modules/openstep-plist/default.nix+31 pkgs/development/python-modules/skia-pathops/default.nix+43 pkgs/development/python-modules/ufo2ft/default.nix+2−2 pkgs/development/python-modules/ufoLib2/default.nix+3 pkgs/top-level/python-packages.nix+8
pkgs/development/python-modules/fontmake/default.nixnew file+42
@@ -0,0 +1,42 @@
1+{ lib
2+, buildPythonPackage
3+, fetchPypi
4+, glyphslib
5+, setuptools-scm
6+, ufo2ft
7+, fonttools
8+, fontmath
9+, lxml
10+, setuptools
11+}:
12+
13+buildPythonPackage rec {
14+ pname = "fontmake";
15+ version = "3.3.0";
16+
17+ src = fetchPypi {
18+ inherit pname version;
19+ sha256 = "sha256-lD7MvZdr9CeWdoZtD3+8stVJTeQN5/AQ4miA/I2TFoE=";
20+ extension = "zip";
21+ };
22+
23+ nativeBuildInputs = [ setuptools-scm ];
24+
25+ propagatedBuildInputs = [
26+ glyphslib
27+ ufo2ft
28+ fonttools
29+ fontmath
30+ lxml
31+ setuptools
32+ ];
33+
34+ pythonImportsCheck = [ "fontmake" ];
35+
36+ meta = {
37+ description = "Compiles fonts from various sources (.glyphs, .ufo, designspace) into binaries formats (.otf, .ttf)";
38+ homepage = "https://github.com/googlefonts/fontmake";
39+ license = lib.licenses.asl20;
40+ maintainers = [ lib.maintainers.BarinovMaxim ];
41+ };
42+}
pkgs/development/python-modules/fonttools/default.nix+7−3
@@ -13,11 +13,12 @@
1313, sphinx
1414, pytestCheckHook
1515, glibcLocales
16+, setuptools-scm
1617}:
1718
1819buildPythonPackage rec {
1920 pname = "fonttools";
20− version = "4.30.0";
21+ version = "4.33.3";
2122
2223 disabled = pythonOlder "3.7";
2324
@@ -25,9 +26,11 @@ buildPythonPackage rec {
2526 owner = pname;
2627 repo = pname;
2728 rev = version;
28− sha256 = "1y9f071bdl66rsx42j16j5v53h85xra5qlg860rz3m054s2rmin9";
29+ sha256 = "MUIZGnYwlfTat9655AOYgK5r6AvHj/xXghUvOZR8HIM=";
2930 };
3031
32+ nativeBuildInputs = [ setuptools-scm ];
33+
3134 # all dependencies are optional, but
3235 # we run the checks with them
3336
@@ -51,6 +54,8 @@ buildPythonPackage rec {
5154 unicodedata2
5255 ];
5356
57+ pythonImportsCheck = [ "fontTools" ];
58+
5459 preCheck = ''
5560 # tests want to execute the "fonttools" executable from $PATH
5661 export PATH="$out/bin:$PATH"
@@ -72,7 +77,6 @@ buildPythonPackage rec {
7277 "Tests/ufoLib"
7378 ];
7479
75−
7680 meta = with lib; {
7781 homepage = "https://github.com/fonttools/fonttools";
7882 description = "A library to manipulate font files from Python";
pkgs/development/python-modules/glyphslib/default.nixnew file+59
@@ -0,0 +1,59 @@
1+{ lib
2+, buildPythonPackage
3+, fetchPypi
4+, fonttools
5+, openstep-plist
6+, ufoLib2
7+, pytestCheckHook
8+, unicodedata2
9+, setuptools-scm
10+, ufonormalizer
11+, xmldiff
12+, defcon
13+, ufo2ft
14+, skia-pathops
15+}:
16+
17+buildPythonPackage rec {
18+ pname = "glyphslib";
19+ version = "6.0.4";
20+
21+ format = "pyproject";
22+
23+ src = fetchPypi {
24+ pname = "glyphsLib";
25+ inherit version;
26+ sha256 = "sha256-PT66n1WEO5FNcwov8GaXT1YNrAi22X4HN7iVNkuehKI=";
27+ };
28+
29+ nativeBuildInputs = [ setuptools-scm ];
30+
31+ checkInputs = [ pytestCheckHook ];
32+
33+ pythonImportsCheck = [ "glyphsLib" ];
34+
35+ propagatedBuildInputs = [
36+ fonttools
37+ openstep-plist
38+ ufoLib2
39+ unicodedata2
40+ ufonormalizer
41+ xmldiff
42+ defcon
43+ ufo2ft
44+ skia-pathops
45+ ];
46+
47+ disabledTestPaths = [
48+ "tests/builder/designspace_gen_test.py" # this test tries to use non-existent font "CoolFoundry Examplary Serif"
49+ "tests/builder/interpolation_test.py" # this test tries to use a font that previous test should made
50+ ];
51+
52+ meta = {
53+ description = "Bridge from Glyphs source files (.glyphs) to UFOs and Designspace files via defcon and designspaceLib";
54+ homepage = "https://github.com/googlefonts/glyphsLib";
55+ license = lib.licenses.asl20;
56+ maintainers = [ lib.maintainers.BarinovMaxim ];
57+ };
58+}
59+
pkgs/development/python-modules/openstep-plist/default.nixnew file+31
@@ -0,0 +1,31 @@
1+{ lib
2+, buildPythonPackage
3+, fetchPypi
4+, setuptools-scm
5+, pytestCheckHook
6+, cython
7+, pythonImportsCheckHook
8+}:
9+
10+buildPythonPackage rec {
11+ pname = "openstep-plist";
12+ version = "0.3.0";
13+
14+ src = fetchPypi {
15+ pname = "openstep_plist";
16+ inherit version;
17+ sha256 = "sha256-KO4sGKjod5BwUFQ1MU2S1dG0DyiJ06mdroMbRDsugBk=";
18+ extension = "zip";
19+ };
20+
21+ nativeBuildInputs = [ setuptools-scm cython ];
22+ checkInputs = [ pytestCheckHook ];
23+ pythonImportsCheck = [ "openstep_plist" ];
24+
25+ meta = {
26+ description = "Parser for the 'old style' OpenStep property list format also known as ASCII plist";
27+ homepage = "https://github.com/fonttools/openstep-plist";
28+ license = lib.licenses.mit;
29+ maintainers = [ lib.maintainers.BarinovMaxim ];
30+ };
31+}
pkgs/development/python-modules/skia-pathops/default.nixnew file+43
@@ -0,0 +1,43 @@
1+{ lib
2+, buildPythonPackage
3+, cython
4+, ninja
5+, setuptools-scm
6+, setuptools
7+, fetchPypi
8+, gn
9+, pytestCheckHook
10+}:
11+
12+buildPythonPackage rec {
13+ pname = "skia-pathops";
14+ version = "0.7.2";
15+
16+ src = fetchPypi {
17+ pname = "skia-pathops";
18+ inherit version;
19+ extension = "zip";
20+ sha256 = "sha256-Gdhcmv77oVr5KxPIiJlk935jgvWPQsYEC0AZ6yjLppA=";
21+ };
22+
23+ postPatch = ''
24+ substituteInPlace setup.py \
25+ --replace "build_cmd = [sys.executable, build_skia_py, build_dir]" \
26+ 'build_cmd = [sys.executable, build_skia_py, "--no-fetch-gn", "--no-virtualenv", "--gn-path", "${gn}/bin/gn", build_dir]'
27+ '';
28+
29+ nativeBuildInputs = [ cython ninja setuptools-scm ];
30+
31+ propagatedBuildInputs = [ setuptools ];
32+
33+ checkInputs = [ pytestCheckHook ];
34+
35+ pythonImportsCheck = [ "pathops" ];
36+
37+ meta = {
38+ description = "Python access to operations on paths using the Skia library";
39+ homepage = "https://skia.org/dev/present/pathops";
40+ license = lib.licenses.bsd3;
41+ maintainers = [ lib.maintainers.BarinovMaxim ];
42+ };
43+}
pkgs/development/python-modules/ufo2ft/default.nix+2−2
@@ -12,13 +12,13 @@
1212
1313buildPythonPackage rec {
1414 pname = "ufo2ft";
15− version = "2.26.0";
15+ version = "2.27.0";
1616
1717 format = "setuptools";
1818
1919 src = fetchPypi {
2020 inherit pname version;
21− sha256 = "sha256-1WQAs1ypWtLObgBzPtqtvHjkKnDWohu3PbI3bF7B0Sg=";
21+ sha256 = "r5bE4M/blt5TKzP43MpijwYY6ll3aasszmGksY5WTTE=";
2222 };
2323
2424 patches = [
pkgs/development/python-modules/ufoLib2/default.nix+3
@@ -5,6 +5,7 @@
55, fonttools
66, pytestCheckHook
77, fs
8+, setuptools-scm
89}:
910
1011buildPythonPackage rec {
@@ -25,6 +26,8 @@ buildPythonPackage rec {
2526 fs
2627 ];
2728
29+ nativeBuildInputs = [ setuptools-scm ];
30+
2831 checkInputs = [
2932 pytestCheckHook
3033 ];
pkgs/top-level/python-packages.nix+8
@@ -3140,6 +3140,14 @@ in {
31403140
31413141 fonttools = callPackage ../development/python-modules/fonttools { };
31423142
3143+ fontmake = callPackage ../development/python-modules/fontmake { };
3144+
3145+ skia-pathops = callPackage ../development/python-modules/skia-pathops { };
3146+
3147+ openstep-plist = callPackage ../development/python-modules/openstep-plist { };
3148+
3149+ glyphslib = callPackage ../development/python-modules/glyphslib { };
3150+
31433151 foobot-async = callPackage ../development/python-modules/foobot-async { };
31443152
31453153 foolscap = callPackage ../development/python-modules/foolscap { };