]> git.pld-linux.org Git - packages/python-pycoinnet.git/blame - python-pycoinnet.spec
use epoch 1 for python3 package
[packages/python-pycoinnet.git] / python-pycoinnet.spec
CommitLineData
e299101d
AM
1#
2# Conditional build:
3%bcond_with python2 # Python 2.x module
4%bcond_without python3 # Python 3.x module
0c9f4fb2
ER
5
6%define module pycoinnet
e299101d
AM
7Summary: Speaking the Bitcoin Protocol
8Name: python-pycoinnet
9Version: 0.01
10Release: 0.1
11License: MIT
12Group: Development/Languages/Python
13Source0: https://github.com/richardkiss/pycoinnet/archive/%{version}.tar.gz
14# Source0-md5: 512f17827323eb1ba2bfe7952829575d
15URL: https://github.com/richardkiss/pycoinnet
05080eb1 16BuildRequires: rpmbuild(macros) >= 1.710
0c9f4fb2 17BuildRequires: rpm-pythonprov
e299101d
AM
18%if %{with python2}
19BuildRequires: python-devel
20BuildRequires: python-modules
e299101d
AM
21%endif
22%if %{with python3}
23BuildRequires: python3-2to3
a90a0b42
ER
24BuildRequires: python3-devel >= 1:3.3
25BuildRequires: python3-modules >= 1:3.3
e299101d 26%endif
0c9f4fb2 27Requires: python
e299101d
AM
28BuildArch: noarch
29BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31%description
32It provides utilities and examples for writing tools in pure Python
33that speak the bitcoin protocol on the bitcoin network.
34
35%package -n python3-%{module}
36Summary: Speaking the Bitcoin Protocol
37Version: 0.01
38Release: 1
39Group: Libraries/Python
a90a0b42 40Requires: python3 >= 1:3.3
e299101d
AM
41
42%description -n python3-%{module}
43It provides utilities and examples for writing tools in pure Python
44that speak the bitcoin protocol on the bitcoin network.
45
46%prep
47%setup -q -n pycoinnet-%{version}
48
49%build
50%if %{with python2}
d101da2a 51%py_build --build-base py2
e299101d
AM
52%endif
53%if %{with python3}
d101da2a 54%py3_build --build-base py3
e299101d
AM
55%endif
56
57%install
58rm -rf $RPM_BUILD_ROOT
59%if %{with python2}
60install -d $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version}
d101da2a 61%py_build \
e299101d
AM
62 --build-base py2 \
63 install \
64 --optimize 2 \
65 --root=$RPM_BUILD_ROOT
66%endif
67
68%if %{with python3}
69install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
d101da2a 70%py3_build \
e299101d
AM
71 --build-base py3 \
72 install \
73 --optimize 2 \
74 --root=$RPM_BUILD_ROOT
75%endif
76
77%clean
78rm -rf $RPM_BUILD_ROOT
79
80%if %{with python2}
81%files
82%defattr(644,root,root,755)
83%doc CHANGES CREDITS README.md
e299101d
AM
84%{py_sitescriptdir}/%{module}
85%{py_sitescriptdir}/*egg-info
0c9f4fb2 86%{_examplesdir}/python-%{module}-%{version}
e299101d
AM
87%endif
88
89%if %{with python3}
90%files -n python3-%{module}
91%defattr(644,root,root,755)
92%doc CHANGES CREDITS README.md
e299101d
AM
93%{py3_sitescriptdir}/%{module}
94%{py3_sitescriptdir}/*egg-info
0c9f4fb2 95%{_examplesdir}/python3-%{module}-%{version}
e299101d 96%endif
This page took 0.082782 seconds and 4 git commands to generate.