diff --git a/nototools.spec b/nototools.spec index 454cd820d6eb22e84d65aba9d98cc0926ebbdf5c..c6d2c2ced0606bee02214881dcc7f5f420f67458 100644 --- a/nototools.spec +++ b/nototools.spec @@ -3,11 +3,12 @@ Name: nototools Version: 0.2.17 -Release: 1 +Release: 2 Summary: Noto fonts support tools and scripts plus web site generation -License: ASL 2.0 +License: Apache-2.0 URL: https://github.com/googlei18n/nototools Source0: https://github.com/googlei18n/nototools/archive/%{commit0}/nototools-%{shortcommit0}.tar.gz +Patch0: remove-requireReal-arg-for-fonttools-4.27.0.patch BuildArch: noarch BuildRequires: python3-devel python-setuptools python3-wheel python3-setuptools_scm Requires: python3-nototools = %{version}-%{release} python3-pillow @@ -30,7 +31,7 @@ BuildRequires: python3dist(fonttools) The tools package contains python3 scripts. %prep -%autosetup -c -p0 +%autosetup -c -p1 # fix module 'nototools.notoconfig' has no attribute 'values' sed -i 's/notoconfig.values/notoconfig._values/g' */nototools/autofix_for_release.py @@ -72,6 +73,9 @@ cd .. %changelog +* Thu Nov 28 2024 wangkai <13474090681@163.com> - 0.2.17-2 +- Fix noto_lint.py scripts error + * Thu Sep 15 2022 lutcunpeng - 0.2.17-1 - DESC: update to 0.2.17 diff --git a/remove-requireReal-arg-for-fonttools-4.27.0.patch b/remove-requireReal-arg-for-fonttools-4.27.0.patch new file mode 100644 index 0000000000000000000000000000000000000000..af0049b3b44447ea6ffc4f92ee0a1a3a0ae31b01 --- /dev/null +++ b/remove-requireReal-arg-for-fonttools-4.27.0.patch @@ -0,0 +1,31 @@ +diff --git a/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/compare_fonts.py b/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/compare_fonts.py +index b0b9379..48a1746 100755 +--- a/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/compare_fonts.py ++++ b/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/compare_fonts.py +@@ -182,10 +182,10 @@ class FontCompare(object): + return result + + def _test_gid(self, cp): +- return self.test.getGlyphID(self.test_cmap[cp], requireReal=True) ++ return self.test.getGlyphID(self.test_cmap[cp]) + + def _target_gid(self, cp): +- return self.target.getGlyphID(self.target_cmap[cp], requireReal=True) ++ return self.target.getGlyphID(self.target_cmap[cp]) + + def _cp_error_msg(self, cp, test_msg, target_msg): + test_gid = self._test_gid(cp) +diff --git a/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/noto_lint.py b/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/noto_lint.py +index 4951832..4c902f1 100755 +--- a/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/noto_lint.py ++++ b/nototools-cd79db632c9a506ad61ae72bfad5875341ca56b8/nototools/noto_lint.py +@@ -1380,7 +1380,7 @@ def check_font( + cmap = font_data.get_cmap(font) + for cp in lint_config.parse_int_ranges(WIN_ANSI_CODEPOINTS, True): + if cp in cmap: +- tmp_gids.add(font.getGlyphID(cmap[cp], requireReal=True)) ++ tmp_gids.add(font.getGlyphID(cmap[cp])) + win_ansi_gids = frozenset(tmp_gids) + + font_ymin = None +