]> git.pld-linux.org Git - packages/python-zope.event.git/blob - python-zope.event.spec
cba852ff978abeb1f71d949c960a78f1eeea2517
[packages/python-zope.event.git] / python-zope.event.spec
1 #
2 # Conditional build:
3 %bcond_without  doc     # Sphinx documentation
4 %bcond_without  tests   # unit tests
5 %bcond_without  python2 # CPython 2.x module
6 %bcond_without  python3 # CPython 3.x module
7
8 %define module zope.event
9 Summary:        Simple event system
10 Summary(pl.UTF-8):      Prosty system zdarzeń
11 Name:           python-%{module}
12 Version:        4.4
13 Release:        3
14 License:        ZPL v2.1
15 Group:          Libraries/Python
16 #Source0Download: https://pypi.org/simple/zope-event/
17 Source0:        https://files.pythonhosted.org/packages/source/z/zope.event/zope.event-%{version}.tar.gz
18 # Source0-md5:  54e5bf148548726d626ec47bb01bec41
19 URL:            https://www.zope.org/
20 %if %{with python2}
21 BuildRequires:  python >= 1:2.7
22 BuildRequires:  python-devel >= 1:2.7
23 BuildRequires:  python-setuptools
24 %if %{with tests}
25 BuildRequires:  python-zope.testrunner
26 %endif
27 %endif
28 %if %{with python3}
29 BuildRequires:  python3 >= 1:3.4
30 BuildRequires:  python3-devel >= 1:3.4
31 BuildRequires:  python3-setuptools
32 %if %{with tests}
33 BuildRequires:  python3-zope.testrunner
34 %endif
35 %endif
36 BuildRequires:  rpm-pythonprov
37 BuildRequires:  rpmbuild(macros) >= 1.714
38 %if %{with doc}
39 BuildRequires:  sphinx-pdg
40 %endif
41 Requires:       python-modules >= 1:2.7
42 Requires:       python-zope-base
43 Obsoletes:      Zope-Event
44 BuildArch:      noarch
45 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
47 %description
48 The zope.event package provides a simple event system. It provides:
49 - an event publishing system
50 - a very simple event-dispatching system on which more sophisticated
51   event dispatching systems can be built. (For example, a type-based
52   event dispatching system that builds on zope.event can be found in
53   zope.component)
54
55 %description -l pl.UTF-8
56 Pakiet zope.event udostępnia prosty system zdarzeń. Zawiera:
57 - system publikacji zdarzeń
58 - bardzo prosty system przekazywania zdarzeń, w oparciu o który można
59   stworzyć bardziej wyszukane systemy przekazywania zdarzeń (na przykład
60   system przekazywania zdarzeń oparty na typach, zbudowany w oparciu o
61   zope.event, można znaleźć w zope.component)
62
63 %package -n python3-%{module}
64 Summary:        Simple event system
65 Summary(pl.UTF-8):      Prosty system zdarzeń
66 Group:          Libraries/Python
67 Requires:       python3-modules >= 1:3.4
68 Requires:       python3-zope-base
69
70 %description -n python3-%{module}
71 The zope.event package provides a simple event system. It provides:
72 - an event publishing system
73 - a very simple event-dispatching system on which more sophisticated
74   event dispatching systems can be built. (For example, a type-based
75   event dispatching system that builds on zope.event can be found in
76   zope.component)
77
78 %description -n python3-%{module} -l pl.UTF-8
79 Pakiet zope.event udostępnia prosty system zdarzeń. Zawiera:
80 - system publikacji zdarzeń
81 - bardzo prosty system przekazywania zdarzeń, w oparciu o który można
82   stworzyć bardziej wyszukane systemy przekazywania zdarzeń (na przykład
83   system przekazywania zdarzeń oparty na typach, zbudowany w oparciu o
84   zope.event, można znaleźć w zope.component)
85
86 %package apidocs
87 Summary:        API documentation for Python zope.event module
88 Summary(pl.UTF-8):      Dokumentacja API modułu Pythona zope.event
89 Group:          Documentation
90
91 %description apidocs
92 API documentation for Python zope.event module.
93
94 %description apidocs -l pl.UTF-8
95 Dokumentacja API modułu Pythona zope.event.
96
97 %prep
98 %setup -q -n %{module}-%{version}
99
100 %build
101 %if %{with python2}
102 %py_build
103
104 %if %{with tests}
105 PYTHONPATH=$(pwd)/src \
106 %{__python} -m zope.testrunner --test-path=src
107 %endif
108 %endif
109
110 %if %{with python3}
111 %py3_build
112
113 %if %{with tests}
114 PYTHONPATH=$(pwd)/src \
115 %{__python3} -m zope.testrunner --test-path=src
116 %endif
117 %endif
118
119 %if %{with doc}
120 PYTHONPATH=$(pwd)/src \
121 %{__make} -C docs html
122 %endif
123
124 %install
125 rm -rf $RPM_BUILD_ROOT
126
127 %if %{with python2}
128 %py_install \
129         --install-purelib=%{py_sitescriptdir}
130
131 %py_postclean
132 %endif
133
134 %if %{with python3}
135 %py3_install \
136         --install-purelib=%{py3_sitescriptdir}
137 %endif
138
139 %clean
140 rm -rf $RPM_BUILD_ROOT
141
142 %if %{with python2}
143 %files
144 %defattr(644,root,root,755)
145 %doc CHANGES.rst COPYRIGHT.txt LICENSE.txt README.rst
146 %{py_sitescriptdir}/zope/event
147 %{py_sitescriptdir}/zope.event-%{version}-py*.egg-info
148 %{py_sitescriptdir}/zope.event-%{version}-py*-nspkg.pth
149 %endif
150
151 %if %{with python3}
152 %files -n python3-%{module}
153 %defattr(644,root,root,755)
154 %{py3_sitescriptdir}/zope/event
155 %{py3_sitescriptdir}/zope.event-%{version}-py*.egg-info
156 %{py3_sitescriptdir}/zope.event-%{version}-py*-nspkg.pth
157 %endif
158
159 %if %{with doc}
160 %files apidocs
161 %defattr(644,root,root,755)
162 %doc docs/_build/html/{_modules,_static,*.html,*.js}
163 %endif
This page took 0.076565 seconds and 2 git commands to generate.