]> git.pld-linux.org Git - SPECS.git/blame - python-versioneer.spec
SPECS updated Mon 29 Apr 22:05:02 CEST 2024
[SPECS.git] / python-versioneer.spec
CommitLineData
283903ce 1#
2# Conditional build:
3%bcond_with tests # unit tests (FIXME)
4%bcond_without python2 # CPython 2.x module
5%bcond_with python3 # CPython 3.x module (built from python3-versioneer.spec)
6
7Summary: Easy VCS-based management of project version strings
8Summary(pl.UTF-8): Łatwe, oparte o VCS zarządzanie łańcuchami wersji projektu
9Name: python-versioneer
10# keep 0.18 here for python2 support
11Version: 0.18
12Release: 1
13License: Public Domain
14Group: Libraries/Python
15#Source0Download: https://pypi.org/simple/versioneer/
16Source0: https://files.pythonhosted.org/packages/source/v/versioneer/versioneer-%{version}.tar.gz
17# Source0-md5: c8000ed8adf127cc95fa2584e9810115
18URL: https://pypi.org/project/versioneer/
19%if %{with python2}
20BuildRequires: python-modules >= 1:2.6
21BuildRequires: python-setuptools
22%endif
23%if %{with python3}
24BuildRequires: python3-modules >= 1:3.2
25BuildRequires: python3-setuptools
26%endif
27BuildRequires: rpm-pythonprov
28BuildRequires: rpmbuild(macros) >= 1.714
29Requires: python-modules >= 1:2.6
30BuildArch: noarch
31BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33%description
34Versioneer is a tool to automatically update version strings (in
35setup.py and the conventional "from PROJECT import _version" pattern)
36by asking your version-control system about the current tree.
37
38%description -l pl.UTF-8
39Versioneer to narzędzie do automatycznego uaktualniania łańcuchów
40wersji (w setup.py oraz konwencjonalnym wzorcu "from PROJECT import
41_version), odpytując system kontroli wersji o bieżące drzewo.
42
43%package -n python3-versioneer
44Summary: Easy VCS-based management of project version strings
45Summary(pl.UTF-8): Łatwe, oparte o VCS zarządzanie łańcuchami wersji projektu
46Group: Libraries/Python
47Requires: python3-modules >= 1:3.2
48
49%description -n python3-versioneer
50Versioneer is a tool to automatically update version strings (in
51setup.py and the conventional "from PROJECT import _version" pattern)
52by asking your version-control system about the current tree.
53
54%description -n python3-versioneer -l pl.UTF-8
55Versioneer to narzędzie do automatycznego uaktualniania łańcuchów
56wersji (w setup.py oraz konwencjonalnym wzorcu "from PROJECT import
57_version), odpytując system kontroli wersji o bieżące drzewo.
58
59%prep
60%setup -q -n versioneer-%{version}
61
62%build
63%if %{with python2}
64%py_build
65
66%if %{with tests}
67# FIXME: how to unpack versioneer.py for tests?
68%{__python} -m unittest discover -s test
69%endif
70%endif
71
72%if %{with python3}
73%py3_build
74
75%if %{with tests}
76# FIXME: how to unpack versioneer.py for tests?
77%{__python3} -m unittest discover -s test
78%endif
79%endif
80
81%install
82rm -rf $RPM_BUILD_ROOT
83
84%if %{with python2}
85%py_install
86
87%py_postclean
88
89%{__mv} $RPM_BUILD_ROOT%{_bindir}/versioneer{,-2}
90%endif
91
92%if %{with python3}
93%py3_install
94
95%{__mv} $RPM_BUILD_ROOT%{_bindir}/versioneer{,-3}
96ln -sf versioneer-3 $RPM_BUILD_ROOT%{_bindir}/versioneer
97%endif
98
99%clean
100rm -rf $RPM_BUILD_ROOT
101
102%if %{with python2}
103%files
104%defattr(644,root,root,755)
105%doc README.md details.md developers.md
106%attr(755,root,root) %{_bindir}/versioneer-2
107%{py_sitescriptdir}/versioneer.py[co]
108%{py_sitescriptdir}/versioneer-%{version}-py*.egg-info
109%endif
110
111%if %{with python3}
112%files -n python3-versioneer
113%defattr(644,root,root,755)
114%doc README.md details.md developers.md
115%attr(755,root,root) %{_bindir}/versioneer
116%attr(755,root,root) %{_bindir}/versioneer-3
117%{py3_sitescriptdir}/versioneer.py
118%{py3_sitescriptdir}/__pycache__/versioneer.cpython-*.py[co]
119%{py3_sitescriptdir}/versioneer-%{version}-py*.egg-info
120%endif
This page took 4.367707 seconds and 4 git commands to generate.