]> git.pld-linux.org Git - packages/python-ipaddress.git/blame - python-ipaddress.spec
- release 2 (by relup.sh)
[packages/python-ipaddress.git] / python-ipaddress.spec
CommitLineData
b3652667
AM
1#
2# Conditional build:
ae82a4bf
JB
3%bcond_without python2 # CPython 2.x module
4%bcond_with python3 # CPython 3.x module [already included in 3.3+ distribution]
b3652667
AM
5%bcond_without tests # do not perform "make test"
6
7%define module ipaddress
8Summary: IPv4/IPv6 manipulation library
ae82a4bf 9Summary(pl.UTF-8): Biblioteka do operacji na adresach IPv4/IPv6
b3652667 10Name: python-%{module}
dab95539 11Version: 1.0.18
904865f5 12Release: 2
b3652667
AM
13License: PSF
14Group: Libraries/Python
ae82a4bf 15#Source0Download: https://pypi.python.org/simple/ipaddress/
dab95539
JB
16Source0: https://files.pythonhosted.org/packages/source/i/ipaddress/%{module}-%{version}.tar.gz
17# Source0-md5: 310c2dfd64eb6f0df44aa8c59f2334a7
b3652667 18URL: https://pypi.python.org/pypi/ipaddress/
b3652667 19BuildRequires: rpm-pythonprov
ae82a4bf
JB
20BuildRequires: rpmbuild(macros) >= 1.714
21%if %{with python2}
22BuildRequires: python-modules >= 1:2.6
23%endif
24%if %{with python3}
25BuildRequires: python3-modules >= 1:3.2
26BuildRequires: python3-modules < 1:3.3
27%endif
28Requires: python-modules >= 1:2.6
b3652667
AM
29BuildArch: noarch
30BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32%description
33IPv4/IPv6 manipulation library.
34
ae82a4bf
JB
35%description -l pl.UTF-8
36Biblioteka do operacji na adresach IPv4/IPv6.
37
38%package -n python3-%{module}
39Summary: IPv4/IPv6 manipulation library
40Summary(pl.UTF-8): Biblioteka do operacji na adresach IPv4/IPv6
41Group: Libraries/Python
42Requires: python-modules >= 1:3.2
43Requires: python-modules < 1:3.3
b3652667 44
ae82a4bf
JB
45%description -n python3-%{module}
46IPv4/IPv6 manipulation library.
b3652667 47
ae82a4bf
JB
48%description -n python3-%{module} -l pl.UTF-8
49Biblioteka do operacji na adresach IPv4/IPv6.
b3652667
AM
50
51%prep
52%setup -q -n %{module}-%{version}
53
54%build
ae82a4bf 55%if %{with python2}
589fd4aa 56%py_build %{?with_tests:test}
ae82a4bf 57%endif
b3652667 58
ae82a4bf
JB
59%if %{with python3}
60%py3_build %{?with_tests:test}
b3652667
AM
61%endif
62
63%install
64rm -rf $RPM_BUILD_ROOT
65
ae82a4bf 66%if %{with python2}
589fd4aa 67%py_install
b3652667
AM
68
69%py_postclean
ae82a4bf
JB
70%endif
71
72%if %{with python3}
73%py3_install
74%endif
b3652667
AM
75
76%clean
77rm -rf $RPM_BUILD_ROOT
78
ae82a4bf 79%if %{with python2}
b3652667
AM
80%files
81%defattr(644,root,root,755)
ae82a4bf
JB
82%doc README.md
83%{py_sitescriptdir}/ipaddress.py[co]
b3652667
AM
84%{py_sitescriptdir}/ipaddress-*.egg-info
85%endif
86
ae82a4bf
JB
87%if %{with python3}
88%files -n python3-%{module}
b3652667 89%defattr(644,root,root,755)
ae82a4bf
JB
90%doc README.md
91%{py3_sitescriptdir}/ipaddress.py
92%{py3_sitescriptdir}/__pycache__/ipaddress.cpython-*.py[co]
93%{py3_sitescriptdir}/ipaddress-*.egg-info
b3652667 94%endif
This page took 0.05159 seconds and 4 git commands to generate.