]> git.pld-linux.org Git - packages/pyp2rpm.git/blame - pyp2rpm.spec
- build with python 3
[packages/pyp2rpm.git] / pyp2rpm.spec
CommitLineData
20e72201
ER
1#
2# Conditional build:
d3776c9d 3%bcond_with tests # do not perform "make test". requires network access, https://github.com/fedora-python/pyp2rpm/issues/57
20e72201
ER
4
5Summary: Convert Python packages to RPM .spec files
6Name: pyp2rpm
65b2716d 7Version: 3.3.2
41978a25 8Release: 1
14705ca7 9License: MIT
42073356
ER
10Group: Development
11Source0: https://github.com/fedora-python/pyp2rpm/archive/v%{version}/%{name}-%{version}.tar.gz
65b2716d 12# Source0-md5: 32a6c74763c1b1d8ea6a260750bd0176
aa1c3d8d 13Patch0: default-savepath.patch
86badbed 14Patch1: no-rpmdev-packager.patch
71736564 15Patch2: default-distro.patch
1588ee5b 16URL: https://github.com/fedora-python/pyp2rpm
65b2716d
ER
17BuildRequires: python3-flexmock >= 0.9.3
18BuildRequires: python3-setuptools
45c8ad12 19BuildRequires: python3-wheel
20e72201 20BuildRequires: rpm-pythonprov
1588ee5b 21BuildRequires: rpmbuild(macros) >= 1.714
65b2716d
ER
22%if %{with tests}
23BuildRequires: python3-click
24BuildRequires: python3-jinja2
25BuildRequires: python3-pytest
26BuildRequires: python3-scripttest
27%endif
20e72201
ER
28BuildArch: noarch
29BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31%description
32Convert Python packages to RPM .spec.
33
34Users can provide their own templates for rendering the package
35metadata. Both the package source and metadata can be extracted from
36PyPI or from local filesystem (local file doesn't provide that much
37information though).
38
39%prep
c1f92037 40%setup -q
aa1c3d8d 41%patch0 -p1
86badbed 42%patch1 -p1
71736564 43%patch2 -p1
1588ee5b 44
20e72201 45%build
45c8ad12 46%py3_build
20e72201
ER
47
48%if %{with tests}
65b2716d 49PYTHONPATH=$(pwd) py.test-3
20e72201
ER
50%endif
51
52%install
53rm -rf $RPM_BUILD_ROOT
45c8ad12 54%py3_install
20e72201
ER
55
56%clean
57rm -rf $RPM_BUILD_ROOT
58
59%files
60%defattr(644,root,root,755)
42073356 61%doc README.md LICENSE
20e72201 62%attr(755,root,root) %{_bindir}/pyp2rpm
45c8ad12
JR
63%dir %{py3_sitescriptdir}/%{name}
64%{py3_sitescriptdir}/%{name}/__pycache__
65%{py3_sitescriptdir}/%{name}/*.py
66%{py3_sitescriptdir}/%{name}/command
67%dir %{py3_sitescriptdir}/%{name}/templates
68%{py3_sitescriptdir}/%{name}/templates/epel6.spec
69%{py3_sitescriptdir}/%{name}/templates/epel7.spec
70%{py3_sitescriptdir}/%{name}/templates/fedora.spec
71%{py3_sitescriptdir}/%{name}/templates/macros.spec
72%{py3_sitescriptdir}/%{name}/templates/mageia.spec
73%{py3_sitescriptdir}/%{name}/templates/pld.spec
74%{py3_sitescriptdir}/%{name}-%{version}-py*.egg-info
This page took 0.124106 seconds and 4 git commands to generate.