2013-03-15 14:55:50 +01:00
|
|
|
#
|
|
|
|
# spec file for package python-zope.event
|
|
|
|
#
|
2021-07-11 10:42:20 +02:00
|
|
|
# Copyright (c) 2021 SUSE LLC
|
2013-03-15 14:55:50 +01:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2018-12-04 15:16:38 +01:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2013-03-15 14:55:50 +01:00
|
|
|
#
|
|
|
|
|
|
|
|
|
2017-06-21 15:42:36 +02:00
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
|
|
%global modname zope.event
|
2018-12-04 18:26:41 +01:00
|
|
|
%define oldpython python
|
|
|
|
Name: python-zope.event
|
2021-07-11 10:42:20 +02:00
|
|
|
Version: 4.5.0
|
2013-03-15 14:55:50 +01:00
|
|
|
Release: 0
|
|
|
|
Summary: Very basic event publishing system
|
|
|
|
License: ZPL-2.1
|
2018-12-04 18:26:41 +01:00
|
|
|
URL: http://pypi.python.org/pypi/%{modname}
|
|
|
|
Source: https://files.pythonhosted.org/packages/source/z/zope.event/%{modname}-%{version}.tar.gz
|
2017-06-21 15:42:36 +02:00
|
|
|
BuildRequires: %{python_module setuptools}
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: python-rpm-macros
|
2013-03-15 14:55:50 +01:00
|
|
|
# Documentation requirements:
|
2017-06-21 15:44:28 +02:00
|
|
|
BuildRequires: python3-Sphinx
|
2013-03-15 14:55:50 +01:00
|
|
|
BuildArch: noarch
|
2017-06-21 15:42:36 +02:00
|
|
|
%ifpython2
|
|
|
|
Provides: %{oldpython}-zope-event = %{version}
|
|
|
|
Obsoletes: %{oldpython}-zope-event < %{version}
|
|
|
|
%endif
|
|
|
|
%python_subpackages
|
2013-03-15 14:55:50 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
An event publishing system and a very simple event-dispatching system on
|
|
|
|
which more sophisticated event dispatching systems can be built. For
|
|
|
|
example, a type-based event dispatching system that builds on zope.event
|
|
|
|
can be found in zope.component.
|
|
|
|
|
2017-06-21 15:42:36 +02:00
|
|
|
%package -n %{name}-doc
|
2013-07-31 08:37:35 +02:00
|
|
|
Summary: Very basic event publishing system
|
|
|
|
|
2017-06-21 15:42:36 +02:00
|
|
|
%description -n %{name}-doc
|
2013-07-31 08:37:35 +02:00
|
|
|
This package contains documentation files for %{name}.
|
2013-03-15 14:55:50 +01:00
|
|
|
|
|
|
|
%prep
|
2017-06-21 15:42:36 +02:00
|
|
|
%setup -q -n %{modname}-%{version}
|
2013-03-15 14:55:50 +01:00
|
|
|
|
|
|
|
%build
|
2017-06-21 15:42:36 +02:00
|
|
|
%python_build
|
2013-07-31 08:37:35 +02:00
|
|
|
# cannot give build/lib here, as pkg_resources.py needs the egg info and
|
|
|
|
# raises DistributionNotFound for zope.event, hence build doc directly
|
|
|
|
# from source in order to avoid the need for an external doc package
|
2017-06-21 15:42:36 +02:00
|
|
|
export PYTHONPATH=$(pwd)/src
|
|
|
|
python3 setup.py build_sphinx && rm build/sphinx/html/.buildinfo
|
2013-03-15 14:55:50 +01:00
|
|
|
|
|
|
|
%install
|
2017-06-21 15:42:36 +02:00
|
|
|
%python_install
|
2018-12-06 12:46:16 +01:00
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
2013-03-15 14:55:50 +01:00
|
|
|
|
|
|
|
%check
|
2021-09-24 15:05:02 +02:00
|
|
|
cd build/lib
|
|
|
|
%{python_expand \
|
|
|
|
$python -m unittest -v zope.event.tests
|
|
|
|
$python -m doctest -v zope/event/classhandler.py
|
|
|
|
}
|
2013-03-15 14:55:50 +01:00
|
|
|
|
2017-06-21 15:42:36 +02:00
|
|
|
%files %{python_files}
|
2018-12-04 19:10:02 +01:00
|
|
|
%license COPYRIGHT.txt LICENSE.txt
|
|
|
|
%doc CHANGES.rst README.rst
|
2013-03-15 14:55:50 +01:00
|
|
|
%{python_sitelib}/*
|
|
|
|
|
2017-06-21 15:42:36 +02:00
|
|
|
%files -n %{name}-doc
|
2013-07-31 08:37:35 +02:00
|
|
|
%doc build/sphinx/html/
|
|
|
|
|
2013-03-15 14:55:50 +01:00
|
|
|
%changelog
|