-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpython-pygit2.spec
More file actions
78 lines (65 loc) · 2.2 KB
/
python-pygit2.spec
File metadata and controls
78 lines (65 loc) · 2.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
#
# Conditional build:
%bcond_with tests # unit tests
%define module pygit2
%define egg_name pygit2
%define pypi_name pygit2
Summary: Python bindings for libgit2 library
Summary(pl.UTF-8): Wiązania Pythona do biblioteki libgit2
Name: python-%{module}
Version: 1.19.0
Release: 1
License: GPL v2 with linking exception
Group: Libraries/Python
#Source0Download: https://pypi.org/simple/pygit2/
Source0: https://files.pythonhosted.org/packages/source/p/pygit2/%{pypi_name}-%{version}.tar.gz
# Source0-md5: 411d41189d99a69e6c7f0faa35e62442
URL: https://pypi.org/project/pygit2/
BuildRequires: libgit2-devel >= 1.4
BuildRequires: python3-cffi >= 2.0
BuildRequires: python3-devel >= 1:3.11
BuildRequires: python3-modules >= 1:3.11
BuildRequires: python3-setuptools
%{?with_tests:BuildRequires: python3-pytest}
BuildRequires: rpm-pythonprov
BuildRequires: rpmbuild(macros) >= 1.714
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
pygit2 is a set of Python bindings to the libgit2 shared library.
%description -l pl.UTF-8
pygit2 to zbiór wiązań Pythona do biblioteki współdzielonej libgit2.
%package -n python3-%{module}
Summary: Python 3.x bindings for libgit2 library
Summary(pl.UTF-8): Wiązania Pythona 3.x do biblioteki libgit2
Group: Libraries/Python
Requires: libgit2 >= 1.4
%description -n python3-%{module}
pygit2 is a set of Python bindings to the libgit2 shared library.
%description -n python3-%{module} -l pl.UTF-8
pygit2 to zbiór wiązań Pythona do biblioteki współdzielonej libgit2.
%prep
%setup -q -n %{module}-%{version}
%build
%py3_build
%if %{with tests}
PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 \
PYTHONPATH=$(echo $(pwd)/build-3/lib.*) \
%{__python3} -m pytest test
%endif
%install
rm -rf $RPM_BUILD_ROOT
%py3_install
%clean
rm -rf $RPM_BUILD_ROOT
%files -n python3-%{module}
%defattr(644,root,root,755)
%doc AUTHORS.md CHANGELOG.md README.md SPONSORS.md
%dir %{py3_sitedir}/pygit2
%{py3_sitedir}/pygit2/decl
%{py3_sitedir}/pygit2/py.typed
%{py3_sitedir}/pygit2/*.py
%{py3_sitedir}/pygit2/*.pyi
%{py3_sitedir}/pygit2/__pycache__
%attr(755,root,root) %{py3_sitedir}/pygit2/_libgit2.abi3.so
%attr(755,root,root) %{py3_sitedir}/pygit2/_pygit2.cpython-*.so
%{py3_sitedir}/pygit2-%{version}-py*.egg-info