# # spec file for package python-hpack # # Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: python-hpack Version: 2.0.1 Release: 0 Summary: Pure-Python HPACK header compression License: MIT Group: Development/Languages/Python Url: https://pypi.python.org/pypi/hpack Source: https://pypi.python.org/packages/source/h/hpack/hpack-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: fdupes BuildRequires: python-devel BuildRequires: python-setuptools %if 0%{?suse_version} && 0%{?suse_version} <= 1110 %{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %else BuildArch: noarch %endif %description This module contains a pure-Python HTTP/2 header encoding (HPACK) logic for use in Python programs that implement HTTP/2. It also contains a compatibility layer that automatically enables the use of nghttp2 if it’s available. %prep %setup -q -n hpack-%{version} %build python setup.py build %install python setup.py install --prefix=%{_prefix} --root %{buildroot} # cleanup rm -rf %{buildroot}%{python_sitelib}/test rm -rf %{buildroot}%{python_sitelib}/hpack/__pycache__ %fdupes %{buildroot} %files %defattr(-,root,root,-) %{python_sitelib}/hpack %{python_sitelib}/hpack-%{version}*egg* %doc LICENSE HISTORY.rst CONTRIBUTORS.rst README.rst %changelog