#
# spec file for package python-breathe
#
# 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/
#


%define skip_python2 1
Name:           python-breathe
Version:        4.19.2
Release:        1.1
Summary:        Sphinx Doxygen renderer
License:        BSD-3-Clause
Group:          Development/Languages/Python
URL:            https://github.com/michaeljones/breathe
Source:         https://github.com/michaeljones/breathe/archive/v%{version}.tar.gz
BuildRequires:  %{python_module Sphinx >= 3.0.4}
BuildRequires:  %{python_module docutils >= 0.12}
BuildRequires:  %{python_module mock}
BuildRequires:  %{python_module pytest}
BuildRequires:  %{python_module setuptools}
BuildRequires:  %{python_module six >= 1.9}
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
Requires:       python-Sphinx >= 2.0
Requires:       python-docutils >= 0.12
Requires:       python-setuptools
Requires:       python-six >= 1.9
Requires(post): update-alternatives
Requires(postun): update-alternatives
Provides:       python-sphinxcontrib-breathe = %{version}
Obsoletes:      python-sphinxcontrib-breathe < %{version}
BuildArch:      noarch
%python_subpackages

%description
Breathe is an extension to reStructuredText and Sphinx to be
able to read and  render Doxygen xml output.

%prep
%autosetup -p1 -n breathe-%{version}

%build
%python_build

%check
%pytest

%install
%python_install
%python_clone -a %{buildroot}%{_bindir}/breathe-apidoc
%python_expand %fdupes %{buildroot}%{$python_sitelib}

%post
%python_install_alternative breathe-apidoc

%postun
%python_uninstall_alternative breathe-apidoc

%files %{python_files}
%doc README.rst
%license LICENSE
%python_alternative %{_bindir}/breathe-apidoc
%{python_sitelib}/breathe
%{python_sitelib}/breathe-%{version}-py*.egg-info

%changelog
* Fri Jun 26 2020 Guillaume GARDET <guillaume.gardet@opensuse.org>
- update to 4.19.2:
  * Fix crash when visiting typedef. #547
* Mon Jun 15 2020 Tomáš Chvátal <tchvatal@suse.com>
- Use tag, not random sha
* Sun Jun 14 2020 Dirk Mueller <dmueller@suse.com>
- update to 4.19.1:
  * Mark package as compatible with Sphinx 3.1.
  * Refactoring. #528
  * Make debug config variables available in conf.py. #533
  * Fix warning formatting for function lookup. #535
  * Correctly reverse nested namespaces in get_qualification. #540
* Tue Jun  2 2020 Matej Cepl <mcepl@suse.com>
- Increase required version of Sphinx to the one where module
  cstructobject was introduced. (bsc#1168627)
* Wed May 27 2020 pgajdos@suse.com
- version update to 4.18.1
  * 2020-05-10 - Breathe v4.18.1
  - Fix friend class rendering and allow friend struct. #522
  - Add extern examples to doc and remove variable hack. #526
  - Render function candidates without using Sphinx directives. #524
  * 2020-05-02 - Breathe v4.18.0
  - Support tiles in verbatim blocks. #517
  * 2020-05-01 - Breathe v4.17.0
  - Scoped rendering, better integration with Sphinx, misc fixes. #512
  * 2020-04-19 - Breathe v4.16.0
  - Strictly depend on Sphinx's minor version. #498
  - Simplifications and fixes, use more of modern Sphinx natively. #503
  - Add section option to the doxygen(auto)file directive. #501
  - Fix link generation when enum is inside a group (enum FQDN). #508
  - Fix creation of LaTeX math formulas. #506
  - Improve documentation for doxygen(auto)file section option. #509
  * 2020-04-07 - Breathe v4.15.0
  - Add license file to distribution. #492
  - Update for Sphinx 3. #491
* Wed May 27 2020 Petr Gajdos <pgajdos@suse.com>
- %%python3_only -> %%python_alternative
* Tue Apr 14 2020 Paolo Stivanin <info@paolostivanin.com>
- Update to 4.14.2:
  * Fixes to use Sphinx 2.4.4
  * Switch to pytest from nose.
- Remove 0001-Add-MockApp.emit.patch
* Thu Apr  2 2020 Dan Čermák <dcermak@suse.com>
- Fix FTBFS due to test failure
  Add patch: 0001-Add-MockApp.emit.patch
  This is cherry picked from https://github.com/michaeljones/breathe/pull/486
  and fixes test failures with sphinx 2.4.4
* Sun Feb  2 2020 aloisio@gmx.com
- Update to version 4.14.1
  * Use sphinx core instead of mathbase ext. #469
  * Fix test failure for Sphinx >= 2.2.2. #472
  version 4.14.0:
  * Add events attribute to MockApp. #452
  * Add bit field support for C/C++. #454
  * Add alias and variable template support. #461
* Fri Sep 13 2019 Tomáš Chvátal <tchvatal@suse.com>
- Update to 4.13.1:
  * no upstream changelog
* Thu Jun  6 2019 Tomáš Chvátal <tchvatal@suse.com>
- Update to 4.13.0:
  * Fixes for Sphinx 2.0
* Tue Mar 19 2019 Tomáš Chvátal <tchvatal@suse.com>
- Update to 4.12.0:
  * More sphinx fixes
- Remove merged patch sphinx18.patch
* Wed Mar  6 2019 Tomáš Chvátal <tchvatal@suse.com>
- Update to 4.11.1:
  * Fixes for newer sphinx releases
- Switch to github tarball for tests and license
- Add patch to fix build with sphinx 1.8:
  * sphinx18.patch
* Tue Dec  4 2018 Matej Cepl <mcepl@suse.com>
- Remove superfluous devel dependency for noarch package
* Mon Sep 18 2017 toddrme2178@gmail.com
- Fix provides/obsoletes
* Fri Sep  8 2017 toddrme2178@gmail.com
- Initial version