]> git.pld-linux.org Git - packages/python-jdcal.git/blame - python-jdcal.spec
rebuild with tests and docs
[packages/python-jdcal.git] / python-jdcal.spec
CommitLineData
0bcba7eb
JP
1# Conditional build:
2%bcond_without python2 # CPython 2.x module
3%bcond_without python3 # CPython 3.x module
4
5%define module jdcal
6Summary: Julian dates from proleptic Gregorian and Julian calendars
7Name: python-%{module}
8Version: 1.4.1
1d153fcf 9Release: 5
0bcba7eb
JP
10License: BSD
11Group: Libraries/Python
12#Source0Download: https://pypi.org/simple/jdcal/
13Source0: https://files.pythonhosted.org/packages/source/j/jdcal/%{module}-%{version}.tar.gz
14# Source0-md5: e05bdb60fa80f25bc60e73e0c6b7c5dc
15URL: https://github.com/phn/jdcal
16%if %{with python2}
17BuildRequires: python-modules >= 1:2.7
18BuildRequires: python-setuptools
19%endif
20%if %{with python3}
21BuildRequires: python3-modules >= 1:3.4
22BuildRequires: python3-setuptools
23%endif
24BuildRequires: rpm-pythonprov
25BuildRequires: rpmbuild(macros) >= 1.714
26Requires: python-modules >= 1:2.7
27BuildArch: noarch
28BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
29
30%description
31This module contains functions for converting between Julian dates and
32calendar dates.
33
34%package -n python3-%{module}
35Summary: Julian dates from proleptic Gregorian and Julian calendars
36Group: Libraries/Python
37Requires: python3-modules >= 1:3.4
38
39%description -n python3-%{module}
40This module contains functions for converting between Julian dates and
41calendar dates.
42
43%prep
44%setup -q -n %{module}-%{version}
45
46%build
47%if %{with python2}
48%py_build
49%endif
50
51%if %{with python3}
52%py3_build
53%endif
54
55%install
56rm -rf $RPM_BUILD_ROOT
57
58%if %{with python2}
59%py_install
60
61%py_postclean
62%endif
63
64%if %{with python3}
65%py3_install
66%endif
67
68%clean
69rm -rf $RPM_BUILD_ROOT
70
71%if %{with python2}
72%files
73%defattr(644,root,root,755)
74%doc README.rst
75%{py_sitescriptdir}/%{module}.py[co]
76%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
77%endif
78
79%if %{with python3}
80%files -n python3-%{module}
81%defattr(644,root,root,755)
82%doc README.rst
83%{py3_sitescriptdir}/%{module}.py
84%{py3_sitescriptdir}/__pycache__
85%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
86%endif
This page took 0.100049 seconds and 4 git commands to generate.