]> git.pld-linux.org Git - packages/python-parted.git/blame - python-parted.spec
rebuild with separate debuginfo build-ids
[packages/python-parted.git] / python-parted.spec
CommitLineData
65aa80ce
ER
1#
2# Conditional build:
3%bcond_without python2 # CPython 2.x module
4%bcond_without python3 # CPython 3.x module
5
6%define module parted
eb5307b8
JB
7Summary: Python 2.x bindings for libparted library
8Summary(pl.UTF-8): Wiązania Pythona 2.x do biblioteki libparted
65aa80ce 9Name: python-%{module}
8837c633 10Version: 3.11.2
ade53e84 11Release: 4
6a5082dc 12License: GPL v2+
f1f36bea 13Group: Libraries/Python
8837c633
JB
14#Source0Download: https://github.com/dcantrell/pyparted/releases
15Source0: https://github.com/dcantrell/pyparted/releases/download/v%{version}/pyparted-%{version}.tar.gz
16# Source0-md5: 9477016f5a00bd2d7a280879cdeec3a4
baa4a6a7 17Patch0: gcc10.patch
8837c633 18URL: https://github.com/dcantrell/pyparted
e60c57f7 19BuildRequires: parted-devel >= 3.1
761dee25 20BuildRequires: pkgconfig
94e8c355 21BuildRequires: rpm-pythonprov
8837c633 22BuildRequires: rpmbuild(macros) >= 1.714
65aa80ce
ER
23%if %{with python2}
24BuildRequires: python-devel >= 1:2.7
8837c633 25BuildRequires: python-modules >= 1:2.7
65aa80ce
ER
26%endif
27%if %{with python3}
8837c633
JB
28BuildRequires: python3-devel >= 1:3.2
29BuildRequires: python3-modules >= 1:3.2
65aa80ce 30%endif
e60c57f7 31Requires: parted >= 3.1
0dccf8bd
PZ
32BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34%description
eb5307b8
JB
35Python 2.x bindings for the libparted library. It is used for
36manipulating partition tables.
0dccf8bd 37
d59db43c 38%description -l pl.UTF-8
eb5307b8
JB
39Wiązania Pythona 2.x do biblioteki libparted. Służy do modyfikowania
40tablic partycji.
1d44540f 41
65aa80ce 42%package -n python3-%{module}
eb5307b8
JB
43Summary: Python 3.x bindings for libparted library
44Summary(pl.UTF-8): Wiązania Pythona 3.x do biblioteki libparted
65aa80ce 45Group: Libraries/Python
8837c633 46Requires: parted >= 3.1
65aa80ce
ER
47
48%description -n python3-%{module}
eb5307b8
JB
49Python 3.x bindings for the libparted library. It is used for
50manipulating partition tables.
65aa80ce
ER
51
52%description -n python3-%{module} -l pl.UTF-8
eb5307b8
JB
53Wiązania Pythona 3.x do biblioteki libparted. Służy do modyfikowania
54tablic partycji.
65aa80ce 55
0dccf8bd
PZ
56%prep
57%setup -q -n pyparted-%{version}
baa4a6a7 58%patch0 -p1
0dccf8bd
PZ
59
60%build
65aa80ce 61%if %{with python2}
f037ab2f 62%py_build
65aa80ce
ER
63%endif
64
65%if %{with python3}
f037ab2f 66%py3_build
65aa80ce 67%endif
0dccf8bd
PZ
68
69%install
70rm -rf $RPM_BUILD_ROOT
65aa80ce 71%if %{with python2}
f037ab2f 72%py_install
1d44540f 73
5a6eb7e0 74%py_postclean
65aa80ce
ER
75%endif
76
77%if %{with python3}
f037ab2f 78%py3_install
65aa80ce 79%endif
5a6eb7e0 80
0dccf8bd
PZ
81%clean
82rm -rf $RPM_BUILD_ROOT
83
65aa80ce 84%if %{with python2}
0dccf8bd
PZ
85%files
86%defattr(644,root,root,755)
8837c633 87%doc AUTHORS NEWS README TODO
cce5f450 88%attr(755,root,root) %{py_sitedir}/_ped.so
ba4d6950
PZ
89%dir %{py_sitedir}/parted
90%{py_sitedir}/parted/*.py[co]
89ffcaae 91%{py_sitedir}/pyparted-%{version}-py*.egg-info
65aa80ce
ER
92%endif
93
94%if %{with python3}
95%files -n python3-%{module}
96%defattr(644,root,root,755)
8837c633 97%doc AUTHORS NEWS README TODO
65aa80ce 98%attr(755,root,root) %{py3_sitedir}/_ped.*.so
04e6a5f1 99%dir %{py3_sitedir}/parted
65aa80ce
ER
100%{py3_sitedir}/parted/*.py
101%{py3_sitedir}/parted/__pycache__
102%{py3_sitedir}/pyparted-%{version}-py*.egg-info
103%endif
This page took 0.102494 seconds and 4 git commands to generate.