diff --git a/.gitignore b/.gitignore index 85eaf7e..c55b3e5 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ pyenchant-1.3.1.tar.gz /pyenchant-3.2.0.tar.gz /pyenchant-3.2.1.tar.gz /pyenchant-3.2.2.tar.gz +/pyenchant-3.3.0.tar.gz diff --git a/python-enchant.spec b/python-enchant.spec index 67b7cc3..3854a73 100644 --- a/python-enchant.spec +++ b/python-enchant.spec @@ -1,7 +1,7 @@ %global srcname enchant Name: python-enchant -Version: 3.2.2 +Version: 3.3.0 Release: %autorelease Summary: Python bindings for Enchant spellchecking library @@ -13,8 +13,10 @@ BuildArch: noarch BuildRequires: enchant2 BuildRequires: python3-devel +%if %{undefined rhel} # For importing the wxSpellCheckerDialog module BuildRequires: python3-wxpython4 +%endif %description PyEnchant is a spellchecking library for Python, based on the Enchant @@ -32,6 +34,8 @@ library by Dom Lachowicz. %prep %autosetup -p1 -n py%{srcname}-%{version} +# Workaround for https://github.com/pyenchant/pyenchant/issues/326 +sed -i "/size=wxSpellCheckerDialog\.sz/s/wxSpellCheckerDialog\.//" enchant/checker/wxSpellCheckerDialog.py %generate_buildrequires %pyproject_buildrequires @@ -46,8 +50,9 @@ library by Dom Lachowicz. # Tests are not included in the upstream tarball %check # We exclude testing of the import for the GtkSpellCheckerDialog -# as it utilizes the legacy PyGTK bindings -%pyproject_check_import -e '*.GtkSpellCheckerDialog' +# as it utilizes the legacy PyGTK bindings. +# On RHEL, we also exclude wx to avoid it as a dependency. +%pyproject_check_import -e '*.GtkSpellCheckerDialog' %{?rhel:-e '*.wxSpellCheckerDialog'} %files -n python3-%{srcname} -f %{pyproject_files} %doc README.rst diff --git a/sources b/sources index 3401ed4..be597a1 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (pyenchant-3.2.2.tar.gz) = 65dd6abf51f7dd45d9879c63d9a1d34a4682ef37da961d0eb41849c6bbb707d94d079f5581b5f695a01fd9a9b68e9456d487b4423ed8382882f22eeeb6b080f8 +SHA512 (pyenchant-3.3.0.tar.gz) = b9d70697623415314d1ba145d02e8b6e37da19ad04efca5fd114c814cce9f12d0899751ec620efc6ada347754a28075ad351e81db3cf0165c4f3aad5b5ee5086