lol

scfbuild: 1.0.3 -> 2.0.0

+3 -55
+3 -9
pkgs/tools/misc/scfbuild/default.nix
··· 2 2 3 3 buildPythonApplication { 4 4 pname = "scfbuild"; 5 - version = "1.0.3"; 5 + version = "2.0.0"; 6 6 7 7 format = "other"; 8 8 9 9 src = fetchFromGitHub { 10 10 owner = "13rac1"; 11 11 repo = "scfbuild"; 12 - rev = "9acc7fc5fedbf48683d8932dd5bd7583bf922bae"; 13 - sha256 = "1zlqsxkpg7zvmhdjgbqwwc9qgac2b8amzq8c5kwyh5cv95zcp6qn"; 12 + rev = "6d84339512a892972185d894704efa67dd82e87a"; 13 + sha256 = "0wkyzkhshlax9rvdmn441gv87n9abfr0qqmgs8bkg9kbcjb4bhad"; 14 14 }; 15 - 16 - patches = [ 17 - # Convert to Python 3 18 - # https://github.com/13rac1/scfbuild/pull/19 19 - ./python-3.patch 20 - ]; 21 15 22 16 propagatedBuildInputs = [ pyyaml fonttools fontforge ]; 23 17
-46
pkgs/tools/misc/scfbuild/python-3.patch
··· 1 - --- a/bin/scfbuild 2 - +++ b/bin/scfbuild 3 - @@ -1,4 +1,4 @@ 4 - -#!/usr/bin/env python2 5 - +#!/usr/bin/env python3 6 - # -*- coding: utf-8 -*- 7 - 8 - from __future__ import (absolute_import, division, print_function, 9 - --- a/scfbuild/builder.py 10 - +++ b/scfbuild/builder.py 11 - @@ -287,8 +287,8 @@ def _add_name_record(self, text, name_id, platform_id, plat_enc_id, lang_id): 12 - # TODO: The installed version of fontTools doesn't have 13 - # table__n_a_m_e.setName(). 14 - record = NameRecord() 15 - - # PyYAML creates strings, force to Unicode 16 - - record.string = unicode(text) 17 - + # PyYAML creates strings, which are unicode as of Python3 18 - + record.string = text 19 - record.nameID = name_id 20 - record.platformID = platform_id 21 - record.platEncID = plat_enc_id 22 - --- a/scfbuild/fforge.py 23 - +++ b/scfbuild/fforge.py 24 - @@ -84,7 +84,7 @@ def add_glyphs(font, svg_filepaths, conf): 25 - u_ids = [int(u_id, 16) for u_id in filename.split("-")] 26 - # Example: (0x1f441, 0x1f5e8) 27 - 28 - - u_str = ''.join(map(unichr, u_ids)) 29 - + u_str = ''.join(map(chr, u_ids)) 30 - # Example: "U\0001f441U\0001f5e8" 31 - 32 - # Replace sequences with correct ZWJ/VS16 versions as needed 33 - --- a/scfbuild/main.py 34 - +++ b/scfbuild/main.py 35 - @@ -1,4 +1,4 @@ 36 - -#!/usr/bin/env python2 37 - +#!/usr/bin/env python3 38 - # -*- coding: utf-8 -*- 39 - 40 - # SCFBuild is released under the GNU General Public License v3. 41 - index 0000000..99418b5 42 - --- /dev/null 43 - +++ b/scfbuild/requirements.txt 44 - @@ -0,0 +1,2 @@ 45 - +fonttools>=3.41.2 46 - +PyYAML>=5.1