File python-pySMART.spec of Package python-pySMART

#
# spec file for package python-pySMART
#
# Copyright (c) 2020 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#


%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name:           python-pySMART
Version:        1.0
Release:        0
Summary:        Wrapper for smartctl (smartmontools)
License:        LGPL-2.1
URL:            https://github.com/freenas/py-SMART
Source:         https://files.pythonhosted.org/packages/source/p/pySMART/pySMART-%{version}.tar.gz
BuildRequires:  %{python_module devel}
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
Requires:       smartmontools
BuildArch:      noarch
%python_subpackages

%description
pySMART is a Python wrapper for the smartctl component of smartmontools.
Running with administrative rights is strongly recommended, as smartctl
cannot accurately detect all device types or parse all SMART information
without these permissions.

%prep
%setup -q -n pySMART-%{version}

%build
%python_build

%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}

%files %{python_files}
%license LICENSE
%doc README.md
%{python_sitelib}/*

%changelog
openSUSE Build Service is sponsored by