File gcovr.spec of Package gcovr

#
# spec file for package gcovr
#
# Copyright (c) 2017 Neal Gompa <ngompa13@gmail.com>.
#
# 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:           gcovr
Version:        3.3
Release:        0
Summary:        A code coverage report generator using GNU gcov
License:        BSD-3-Clause
Group:          Development/Tools/Other
URL:            http://gcovr.com/
Source0:        https://github.com/gcovr/%{name}/archive/%{version}/%{name}-%{version}.tar.gz

# Fix HTML reports for Python 3 (rhbz#1428277)
# From: https://github.com/gcovr/gcovr/pull/163
Patch0001:      0001-re-enable-HTML-reports-under-Python3.patch

BuildRequires:  python3-devel
BuildRequires:  python3-setuptools
BuildRequires:  python-rpm-macros

Requires:       %{_bindir}/gcov

BuildArch:      noarch

%description
Gcovr provides a utility for managing the use of the GNU gcov utility
and generating summarized code coverage results.

This command is inspired by the Python coverage.py package, which provides
a similar utility in Python. The gcovr command produces either compact
human-readable summary reports, machine readable XML reports
(in Cobertura format) or simple HTML reports. Thus, gcovr can be viewed
as a command-line alternative to the lcov utility, which runs gcov and
generates an HTML-formatted report.


%prep
%autosetup -p1

%build
%py3_build

%install
%py3_install

# python metadata is useless and empty
rm -rf %{buildroot}%{python3_sitelib}

%files
%license LICENSE.txt
%doc README.md CHANGELOG.txt doc/guide.txt
%{_bindir}/gcovr

%changelog
openSUSE Build Service is sponsored by