1 # TODO: extern/six -> python-six?
4 %bcond_without tests # test target
5 %bcond_without python2 # CPython 2.x module
6 %bcond_without python3 # CPython 3.x module
9 Summary: Allow using distutils2-like setup.cfg files with setup.py (Python 2 version)
10 Summary(pl.UTF-8): Możliwość używania setup.cfg w stylu distutils2 z setup.py (wersja dla Pythona 2)
11 Name: python-%{module}
15 Group: Libraries/Python
16 #Source0Download: URL: https://pypi.python.org/pypi/d2to1
17 Source0: https://pypi.python.org/packages/source/d/d2to1/%{module}-%{version}.tar.gz
18 # Source0-md5: 1ba7e64ead23cbf104993122f0871030
19 URL: https://pypi.python.org/pypi/d2to1
20 BuildRequires: rpm-pythonprov
21 BuildRequires: rpmbuild(macros) >= 1.710
23 BuildRequires: python-modules >= 1:2.5
24 BuildRequires: python-setuptools
26 BuildRequires: python-nose
30 BuildRequires: python3-modules >= 1:3.2
31 BuildRequires: python3-setuptools
33 BuildRequires: python3-nose
36 Requires: python-setuptools
38 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41 d2to1 allows using distutils2-like setup.cfg files for a package's
42 metadata with a distribute/setuptools setup.py script. It works by
43 providing a distutils2-formatted setup.cfg file containing all of a
44 package's metadata, and a very minimal setup.py which will slurp its
45 arguments from the setup.cfg.
47 %description -l pl.UTF-8
48 d2to1 pozwala na używanie plików setup.cfg w stylu distutils2 jako
49 metadanych pakietu ze skryptem setup.py typowym dla
50 distribute/setuptools. Działa poprzez dostarczenie pliku setup.cfg w
51 formacie distutils2, zawierającego wszystkie metadane pakietu oraz
52 minimalnego pliku setup.py, który pobiera wszystkie argumenty z pliku
55 %package -n python3-d2to1
56 Summary: Allow using distutils2-like setup.cfg files with setup.py (Python 3 version)
57 Summary(pl.UTF-8): Możliwość używania setup.cfg w stylu distutils2 z setup.py (wersja dla Pythona 3)
58 Group: Libraries/Python
59 Requires: python3-setuptools
61 %description -n python3-d2to1
62 d2to1 allows using distutils2-like setup.cfg files for a package's
63 metadata with a distribute/setuptools setup.py script. It works by
64 providing a distutils2-formatted setup.cfg file containing all of a
65 package's metadata, and a very minimal setup.py which will slurp its
66 arguments from the setup.cfg.
68 %description -n python3-d2to1 -l pl.UTF-8
69 d2to1 pozwala na używanie plików setup.cfg w stylu distutils2 jako
70 metadanych pakietu ze skryptem setup.py typowym dla
71 distribute/setuptools. Działa poprzez dostarczenie pliku setup.cfg w
72 formacie distutils2, zawierającego wszystkie metadane pakietu oraz
73 minimalnego pliku setup.py, który pobiera wszystkie argumenty z pliku
77 %setup -q -n %{module}-%{version}
79 %{__rm} -r %{module}.egg-info
83 %py_build %{?with_tests:test}
87 %py3_build %{?with_tests:test}
91 rm -rf $RPM_BUILD_ROOT
104 rm -rf $RPM_BUILD_ROOT
108 %defattr(644,root,root,755)
109 %doc CHANGES.rst CONTRIBUTORS LICENSE README.rst
110 %dir %{py_sitescriptdir}/d2to1
111 %{py_sitescriptdir}/d2to1/*.py[co]
112 %dir %{py_sitescriptdir}/d2to1/extern
113 %{py_sitescriptdir}/d2to1/extern/__init__.py[co]
114 %{py_sitescriptdir}/d2to1/extern/six.py[co]
115 %{py_sitescriptdir}/d2to1-%{version}-py*.egg-info
119 %files -n python3-d2to1
120 %defattr(644,root,root,755)
121 %doc CHANGES.rst CONTRIBUTORS LICENSE README.rst
122 %{py3_sitescriptdir}/d2to1
123 %{py3_sitescriptdir}/d2to1-%{version}-py*.egg-info