]> git.pld-linux.org Git - packages/python-dill.git/blame - python-dill.spec
rebuild with python 3.10
[packages/python-dill.git] / python-dill.spec
CommitLineData
cbb5ea63
JB
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
8Summary: Serialize all of Python
9Summary(pl.UTF-8): Serializacja całości Pythona
10Name: python-dill
11Version: 0.3.3
bdb2d3c9 12Release: 4
cbb5ea63
JB
13License: BSD
14Group: Libraries/Python
15#Source0Download: https://pypi.org/simple/dill/
16Source0: https://files.pythonhosted.org/packages/source/d/dill/dill-%{version}.zip
17# Source0-md5: 99c878e2e4e924f3234c0efcbcff6abf
18URL: https://pypi.org/project/dill/
19%if %{with python2}
20BuildRequires: python-modules >= 1:2.7
21BuildRequires: python-setuptools
22%endif
23%if %{with python3}
24BuildRequires: python3-modules >= 1:3.5
25BuildRequires: python3-setuptools
26%endif
27BuildRequires: rpm-pythonprov
28BuildRequires: rpmbuild(macros) >= 1.714
29BuildRequires: unzip
30%if %{with doc}
31BuildRequires: sphinx-pdg
32%endif
33Requires: python-modules >= 1:2.7
34BuildArch: noarch
35BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37%description
38dill extends Python's pickle module for serializing and de-serializing
39Python objects to the majority of the built-in Python types.
40Serialization is the process of converting an object to a byte stream,
41and the inverse of which is converting a byte stream back to a Python
42object hierarchy.
43
44%description -l pl.UTF-8
45dill rozszerza moduł Pythona pickle do serializacji i deserializacji
46obiektów pythonowych na większość wbudowanych typów Pythona.
47Serializacja to proces przekształcania obiektu na strumień bajtów, a
48deserializacja - odwrotność, czyli konwersja strumienia bajtów z
49powrotem do hierarchii obiektów Pythona.
50
51%package -n python3-dill
52Summary: Serialize all of Python
53Summary(pl.UTF-8): Serializacja całości Pythona
54Group: Libraries/Python
55Requires: python3-modules >= 1:3.5
56
57%description -n python3-dill
58dill extends Python's pickle module for serializing and de-serializing
59Python objects to the majority of the built-in Python types.
60Serialization is the process of converting an object to a byte stream,
61and the inverse of which is converting a byte stream back to a Python
62object hierarchy.
63
64%description -n python3-dill -l pl.UTF-8
65dill rozszerza moduł Pythona pickle do serializacji i deserializacji
66obiektów pythonowych na większość wbudowanych typów Pythona.
67Serializacja to proces przekształcania obiektu na strumień bajtów, a
68deserializacja - odwrotność, czyli konwersja strumienia bajtów z
69powrotem do hierarchii obiektów Pythona.
70
71%package apidocs
72Summary: API documentation for Python dill module
73Summary(pl.UTF-8): Dokumentacja API modułu Pythona dill
74Group: Documentation
75
76%description apidocs
77API documentation for Python dill module.
78
79%description apidocs -l pl.UTF-8
80Dokumentacja API modułu Pythona dill.
81
82%prep
83%setup -q -n dill-%{version}
84
85%build
86%if %{with python2}
87%py_build
88
89%if %{with tests}
90PYTHONPATH=$(pwd) \
91%{__python} tests/__main__.py
92%endif
93%endif
94
95%if %{with python3}
96%py3_build
97
98%if %{with tests}
99PYTHONPATH=$(pwd) \
100%{__python3} tests/__main__.py
101%endif
102%endif
103
104%if %{with doc}
105PYTHONPATH=$(pwd) \
106%{__make} -C docs html
107%endif
108
109%install
110rm -rf $RPM_BUILD_ROOT
111
112%if %{with python2}
113%py_install
114
115for bin in get_objgraph undill ; do
116 %{__mv} $RPM_BUILD_ROOT%{_bindir}/${bin} $RPM_BUILD_ROOT%{_bindir}/${bin}-2
117done
118
119%py_postclean
120%endif
121
122%if %{with python3}
123%py3_install
124
125for bin in get_objgraph undill ; do
126 %{__mv} $RPM_BUILD_ROOT%{_bindir}/${bin} $RPM_BUILD_ROOT%{_bindir}/${bin}-3
127done
128%endif
129
130%clean
131rm -rf $RPM_BUILD_ROOT
132
133%if %{with python2}
134%files
135%defattr(644,root,root,755)
136%doc DEV_NOTES LICENSE README.md
137%attr(755,root,root) %{_bindir}/get_objgraph-2
138%attr(755,root,root) %{_bindir}/undill-2
139%{py_sitescriptdir}/dill
140%{py_sitescriptdir}/dill-%{version}-py*.egg-info
141%endif
142
143%if %{with python3}
144%files -n python3-dill
145%defattr(644,root,root,755)
146%doc DEV_NOTES LICENSE README.md
147%attr(755,root,root) %{_bindir}/get_objgraph-3
148%attr(755,root,root) %{_bindir}/undill-3
149%{py3_sitescriptdir}/dill
150%{py3_sitescriptdir}/dill-%{version}-py*.egg-info
151%endif
152
153%if %{with doc}
154%files apidocs
155%defattr(644,root,root,755)
156%doc docs/build/{_static,*.html,*.js}
157%endif
This page took 0.120504 seconds and 4 git commands to generate.