]> git.pld-linux.org Git - packages/python-u-msgpack.git/blob - python-u-msgpack.spec
c8f5f50bddda5fe8a7a7d05c8a322c05796e881c
[packages/python-u-msgpack.git] / python-u-msgpack.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # unit tests
4 %bcond_without  python2 # CPython 2.x module
5 %bcond_without  python3 # CPython 3.x module
6
7 Summary:        Portable, lightweight MessagePack serializer and deserializer written in pure Python
8 Summary(pl.UTF-8):      Przenośna, lekka serializacja i deserializacja MessagePack napisana w czystym Pythonie
9 Name:           python-u-msgpack
10 Version:        2.7.1
11 Release:        2
12 License:        MIT
13 Group:          Libraries/Python
14 #Source0Download: https://pypi.python.org/simple/u-msgpack-python
15 Source0:        https://files.pythonhosted.org/packages/source/u/u-msgpack-python/u-msgpack-python-%{version}.tar.gz
16 # Source0-md5:  8691cea6bc7b44bce6e2115260a54323
17 URL:            https://github.com/vsergeev/u-msgpack-python
18 %if %{with tests} && %(locale -a | grep -q '^C\.UTF-8$'; echo $?)
19 BuildRequires:  glibc-localedb-all
20 %endif
21 %if %{with python2}
22 BuildRequires:  python-modules >= 1:2.5
23 BuildRequires:  python-setuptools
24 %endif
25 %if %{with python3}
26 BuildRequires:  python3-modules >= 1:3.2
27 BuildRequires:  python3-setuptools
28 %endif
29 BuildRequires:  rpm-pythonprov
30 BuildRequires:  rpmbuild(macros) >= 1.714
31 Requires:       python-modules >= 1:2.5
32 BuildArch:      noarch
33 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
34
35 %description
36 u-msgpack-python is a lightweight MessagePack <http://msgpack.org/>
37 serializer and deserializer module written in pure Python, compatible
38 with both Python 2 and Python 3, as well as CPython and PyPy
39 implementations of Python. u-msgpack-python is fully compliant with
40 the latest MessagePack specification
41 <https://github.com/msgpack/msgpack/blob/master/spec.md>. In
42 particular, it supports the new binary, UTF-8 string, and
43 application-defined ext types.
44
45 %description -l pl.UTF-8
46 u-msgpack-python to lekki moduł serializacji i deserializacji
47 MessagePack <http://msgpack.org/> napisany w Pythonie, zgodny z
48 Pythonem zarówno 2 i 3, z implementacjami CPython jak i PyPy.
49 u-msgpack-python jest w pełni zgodny z ostatnią specyfikacją
50 MessagePack <https://github.com/msgpack/msgpack/blob/master/spec.md>.
51 W szczególności obsługuje nowe typu binary, łańcuch UTF-8 oraz ext
52 definiowane przez aplikacje.
53
54 %package -n python3-u-msgpack
55 Summary:        Portable, lightweight MessagePack serializer and deserializer written in pure Python
56 Summary(pl.UTF-8):      Przenośna, lekka serializacja i deserializacja MessagePack napisana w czystym Pythonie
57 Group:          Libraries/Python
58 Requires:       python3-modules >= 1:3.2
59
60 %description -n python3-u-msgpack
61 u-msgpack-python is a lightweight MessagePack <http://msgpack.org/>
62 serializer and deserializer module written in pure Python, compatible
63 with both Python 2 and Python 3, as well as CPython and PyPy
64 implementations of Python. u-msgpack-python is fully compliant with
65 the latest MessagePack specification
66 <https://github.com/msgpack/msgpack/blob/master/spec.md>. In
67 particular, it supports the new binary, UTF-8 string, and
68 application-defined ext types.
69
70 %description -n python3-u-msgpack -l pl.UTF-8
71 u-msgpack-python to lekki moduł serializacji i deserializacji
72 MessagePack <http://msgpack.org/> napisany w Pythonie, zgodny z
73 Pythonem zarówno 2 i 3, z implementacjami CPython jak i PyPy.
74 u-msgpack-python jest w pełni zgodny z ostatnią specyfikacją
75 MessagePack <https://github.com/msgpack/msgpack/blob/master/spec.md>.
76 W szczególności obsługuje nowe typu binary, łańcuch UTF-8 oraz ext
77 definiowane przez aplikacje.
78
79 %prep
80 %setup -q -n u-msgpack-python-%{version}
81
82 %build
83 export LC_ALL=C.UTF-8
84
85 %if %{with python2}
86 %py_build
87
88 %if %{with tests}
89 %{__python} test_umsgpack.py
90 %endif
91 %endif
92
93 %if %{with python3}
94 %py3_build
95
96 %if %{with tests}
97 %{__python3} test_umsgpack.py
98 %endif
99 %endif
100
101 %install
102 rm -rf $RPM_BUILD_ROOT
103
104 %if %{with python2}
105 %py_install
106
107 %py_postclean
108 %endif
109
110 %if %{with python3}
111 %py3_install
112 %endif
113
114 %clean
115 rm -rf $RPM_BUILD_ROOT
116
117 %if %{with python2}
118 %files
119 %defattr(644,root,root,755)
120 %doc LICENSE
121 %{py_sitescriptdir}/umsgpack.py[co]
122 %{py_sitescriptdir}/u_msgpack_python-%{version}-py*.egg-info
123 %endif
124
125 %if %{with python3}
126 %files -n python3-u-msgpack
127 %defattr(644,root,root,755)
128 %doc LICENSE
129 %{py3_sitescriptdir}/umsgpack.py
130 %{py3_sitescriptdir}/__pycache__/umsgpack.cpython-*.py[co]
131 %{py3_sitescriptdir}/u_msgpack_python-%{version}-py*.egg-info
132 %endif
This page took 0.053855 seconds and 2 git commands to generate.