OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:mailman/python-mailman?expand=0&rev=6
This commit is contained in:
parent
d5472cd640
commit
cbfe4ad007
@ -40,10 +40,13 @@ BuildRequires: %{python_module falcon > 1.0.0}
|
||||
BuildRequires: %{python_module flufl.bounce}
|
||||
BuildRequires: %{python_module flufl.i18n >= 2.0}
|
||||
BuildRequires: %{python_module flufl.lock >= 3.1}
|
||||
BuildRequires: %{python_module flufl.testing}
|
||||
BuildRequires: %{python_module gunicorn}
|
||||
BuildRequires: %{python_module lazr.config}
|
||||
BuildRequires: %{python_module passlib}
|
||||
BuildRequires: %{python_module python-dateutil >= 2.0}
|
||||
BuildRequires: %{python_module pytest}
|
||||
BuildRequires: %{python_module nose2}
|
||||
BuildRequires: %{python_module requests}
|
||||
BuildRequires: %{python_module sqlalchemy >= 1.2.3}
|
||||
BuildRequires: %{python_module zope.component}
|
||||
@ -85,6 +88,13 @@ Mailman -- the GNU mailing list manager
|
||||
%setup -q -n mailman-%{version}
|
||||
|
||||
%build
|
||||
pushd src/mailman
|
||||
for i in $(grep -r '^from importlib_resources' | sed 's/\(.*\.py\):.*/\1/'); do
|
||||
line=$(grep '^from importlib_resources' $i)
|
||||
what_import=$(echo $line | sed 's:.* import ::')
|
||||
sed -i "s@^\(from importlib_resources.*\)@try:\n from importlib.resources import $what_import\nexcept ImportError:\n \1\n@" $i;
|
||||
done
|
||||
popd
|
||||
%python_build
|
||||
|
||||
%install
|
||||
@ -92,7 +102,7 @@ Mailman -- the GNU mailing list manager
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
|
||||
%check
|
||||
%python_exec setup.py test
|
||||
%python_exec -m nose2 -v
|
||||
|
||||
%files %{python_files}
|
||||
%doc README.rst
|
||||
|
Loading…
Reference in New Issue
Block a user