2018-08-29 13:04:09 +00:00
|
|
|
#
|
|
|
|
|
# spec file for package python-hiredis
|
|
|
|
|
#
|
2022-01-16 13:27:21 +00:00
|
|
|
# Copyright (c) 2022 SUSE LLC
|
2018-08-29 13:04:09 +00:00
|
|
|
#
|
|
|
|
|
# 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.
|
|
|
|
|
|
2019-08-27 00:53:49 +00:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2018-08-29 13:04:09 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
|
|
|
Name: python-hiredis
|
2022-01-16 13:27:21 +00:00
|
|
|
Version: 2.0.0
|
2018-08-29 13:04:09 +00:00
|
|
|
Release: 0
|
|
|
|
|
Summary: Python wrapper for hiredis
|
|
|
|
|
License: BSD-3-Clause
|
|
|
|
|
URL: https://github.com/redis/hiredis-py
|
2022-01-16 13:27:21 +00:00
|
|
|
Source: https://files.pythonhosted.org/packages/source/h/hiredis/hiredis-%{version}.tar.gz
|
2018-08-29 13:04:09 +00:00
|
|
|
Patch0: 0001-Use-system-libhiredis.patch
|
2021-12-31 13:23:52 +00:00
|
|
|
# PATCH-FIX-UPSTREAM drop-vendor-sources.patch gh#redis/hiredis-py#90 mcepl@suse.com
|
|
|
|
|
# Allow to use platform hiredis libs on build
|
2019-08-27 00:53:49 +00:00
|
|
|
Patch2: drop-vendor-sources.patch
|
2018-08-29 13:04:09 +00:00
|
|
|
BuildRequires: %{python_module devel}
|
|
|
|
|
BuildRequires: %{python_module setuptools}
|
|
|
|
|
BuildRequires: fdupes
|
2021-03-03 12:42:11 +00:00
|
|
|
BuildRequires: hiredis-devel >= 1.0.0
|
2018-08-29 13:04:09 +00:00
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
|
%python_subpackages
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
Python wrapper for hiredis C connector.
|
|
|
|
|
|
|
|
|
|
%prep
|
2022-01-16 13:27:21 +00:00
|
|
|
%setup -q -n hiredis-%{version}
|
2018-08-29 13:04:09 +00:00
|
|
|
%autopatch -p1
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
%python_build
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
%python_install
|
|
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
|
|
|
|
|
|
|
|
|
%check
|
2021-03-03 12:42:11 +00:00
|
|
|
%python_exec setup.py build_ext --inplace
|
|
|
|
|
export PYTHONPATH=%{buildroot}%{$python_sitearch}
|
2021-12-31 13:23:52 +00:00
|
|
|
%python_exec test.py
|
2018-08-29 13:04:09 +00:00
|
|
|
|
|
|
|
|
%files %{python_files}
|
|
|
|
|
%license COPYING
|
|
|
|
|
%{python_sitearch}/*
|
|
|
|
|
|
|
|
|
|
%changelog
|