From: Jakub Bogusz Date: Sun, 28 Jun 2020 04:53:50 +0000 (+0200) Subject: - python-ujson updated to 3.0.0 for python 3.5+ X-Git-Tag: auto/th/python3-ujson-3.0.0-1 X-Git-Url: http://git.pld-linux.org/gitweb.cgi?a=commitdiff_plain;h=eaba2e1b150eba847009bb6634ce73590e8dc963;p=packages%2Fpython3-ujson.git - python-ujson updated to 3.0.0 for python 3.5+ --- diff --git a/python-ujson.spec b/python-ujson.spec deleted file mode 100644 index 370840d..0000000 --- a/python-ujson.spec +++ /dev/null @@ -1,116 +0,0 @@ -# -# Conditional build: -%bcond_without tests # unit tests -%bcond_without python2 # CPython 2.x module -%bcond_without python3 # CPython 3.x module - -Summary: Ultra fast JSON encoder and decoder for Python -Summary(pl.UTF-8): Ultraszybki koder i dekoder formatu JSON dla Pythona -Name: python-ujson -Version: 2.0.3 -Release: 1 -License: BSD -Group: Libraries/Python -#Source0Download: https://pypi.org/simple/ujson/ -Source0: https://files.pythonhosted.org/packages/source/u/ujson/ujson-%{version}.tar.gz -# Source0-md5: 80d288c186dd02579e1561494b45aa41 -URL: https://pypi.org/project/ujson/ -BuildRequires: libstdc++-devel -%if %{with python2} -BuildRequires: python-devel >= 1:2.7 -BuildRequires: python-setuptools -BuildRequires: python-setuptools_scm -%if %{with tests} -BuildRequires: python-pytest -BuildRequires: python-six -%endif -%endif -%if %{with python3} -BuildRequires: python3-devel >= 1:3.5 -BuildRequires: python3-setuptools -BuildRequires: python3-setuptools_scm -%if %{with tests} -BuildRequires: python3-pytest -BuildRequires: python3-six -%endif -%endif -BuildRequires: rpm-pythonprov -BuildRequires: rpmbuild(macros) >= 1.714 -Requires: python-modules >= 1:2.7 -BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) - -%description -UltraJSON is an ultra fast JSON encoder and decoder written in pure C -with bindings for Python 2.7 and 3.5+. - -%description -l pl.UTF-8 -UltraJSON to ultraszybki koder i dekoder formatu JSON, napisany w -czystym C z wiązaniami do Pythona 2.7 oraz 3.5+. - -%package -n python3-ujson -Summary: Ultra fast JSON encoder and decoder for Python -Summary(pl.UTF-8): Ultraszybki koder i dekoder formatu JSON dla Pythona -Group: Libraries/Python -Requires: python3-modules >= 1:3.5 - -%description -n python3-ujson -UltraJSON is an ultra fast JSON encoder and decoder written in pure C -with bindings for Python 2.7 and 3.5+. - -%description -n python3-ujson -l pl.UTF-8 -UltraJSON to ultraszybki koder i dekoder formatu JSON, napisany w -czystym C z wiązaniami do Pythona 2.7 oraz 3.5+. - -%prep -%setup -q -n ujson-%{version} - -%build -%if %{with python2} -%py_build - -%if %{with tests} -PYTHONPATH=$(readlink -f build-2/lib.*) \ -%{__python} -m pytest tests -%endif -%endif - -%if %{with python3} -%py3_build - -%if %{with tests} -PYTHONPATH=$(readlink -f build-3/lib.*) \ -%{__python3} -m pytest tests -%endif -%endif - -%install -rm -rf $RPM_BUILD_ROOT - -%if %{with python2} -%py_install - -%py_postclean -%endif - -%if %{with python3} -%py3_install -%endif - -%clean -rm -rf $RPM_BUILD_ROOT - -%if %{with python2} -%files -%defattr(644,root,root,755) -%doc LICENSE.txt README.rst -%attr(755,root,root) %{py_sitedir}/ujson.so -%{py_sitedir}/ujson-%{version}-py*.egg-info -%endif - -%if %{with python3} -%files -n python3-ujson -%defattr(644,root,root,755) -%doc LICENSE.txt README.rst -%attr(755,root,root) %{py3_sitedir}/ujson.cpython-*.so -%{py3_sitedir}/ujson-%{version}-py*.egg-info -%endif diff --git a/python3-ujson.spec b/python3-ujson.spec new file mode 100644 index 0000000..332332d --- /dev/null +++ b/python3-ujson.spec @@ -0,0 +1,59 @@ +# +# Conditional build: +%bcond_without tests # unit tests + +Summary: Ultra fast JSON encoder and decoder for Python +Summary(pl.UTF-8): Ultraszybki koder i dekoder formatu JSON dla Pythona +Name: python3-ujson +Version: 3.0.0 +Release: 1 +License: BSD +Group: Libraries/Python +#Source0Download: https://pypi.org/simple/ujson/ +Source0: https://files.pythonhosted.org/packages/source/u/ujson/ujson-%{version}.tar.gz +# Source0-md5: 1c13a485776a2a0dfa1795d101bb3d57 +URL: https://pypi.org/project/ujson/ +BuildRequires: libstdc++-devel +BuildRequires: python3-devel >= 1:3.5 +BuildRequires: python3-setuptools +BuildRequires: python3-setuptools_scm +%if %{with tests} +BuildRequires: python3-pytest +%endif +BuildRequires: rpm-pythonprov +BuildRequires: rpmbuild(macros) >= 1.714 +Requires: python-modules >= 1:2.7 +BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) + +%description +UltraJSON is an ultra fast JSON encoder and decoder written in pure C +with bindings for Python 3.5+. + +%description -l pl.UTF-8 +UltraJSON to ultraszybki koder i dekoder formatu JSON, napisany w +czystym C z wiązaniami do Pythona 3.5+. + +%prep +%setup -q -n ujson-%{version} + +%build +%py3_build + +%if %{with tests} +PYTHONPATH=$(readlink -f build-3/lib.*) \ +%{__python3} -m pytest tests +%endif + +%install +rm -rf $RPM_BUILD_ROOT + +%py3_install + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +%defattr(644,root,root,755) +%doc LICENSE.txt README.rst +%attr(755,root,root) %{py3_sitedir}/ujson.cpython-*.so +%{py3_sitedir}/ujson-%{version}-py*.egg-info