From df448efc330060fefb5e4c6408998f9903506559 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= Date: Thu, 11 Jan 2024 19:01:59 +0000 Subject: [PATCH] Fix the build for f39 and rawhide Remove -W from SPHINXOPTS since Python 3.10 we should use mkdir instead makedirs --- py_mkdir.patch | 11 +++++++++++ python-breathe.spec | 4 +++- 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 py_mkdir.patch diff --git a/py_mkdir.patch b/py_mkdir.patch new file mode 100644 index 0000000..3aeeb88 --- /dev/null +++ b/py_mkdir.patch @@ -0,0 +1,11 @@ +--- breathe-4.35.0/tests/test_renderer.py.orig 2024-01-11 18:51:06.375701278 +0000 ++++ breathe-4.35.0/tests/test_renderer.py 2024-01-11 18:51:11.394686093 +0000 +@@ -35,7 +35,7 @@ def app(test_params, app_params, make_ap + """ + args, kwargs = app_params + assert "srcdir" in kwargs +- kwargs["srcdir"].makedirs(exist_ok=True) ++ kwargs["srcdir"].mkdir(exist_ok=True) + (kwargs["srcdir"] / "conf.py").write_text("") + app_ = make_app(*args, **kwargs) + yield app_ diff --git a/python-breathe.spec b/python-breathe.spec index a32e79d..6d1b82c 100644 --- a/python-breathe.spec +++ b/python-breathe.spec @@ -17,6 +17,7 @@ URL: https://github.com/%{owner}/%{srcname} Source0: %{URL}/archive/v%{version}.tar.gz Source1: %{URL}/releases/download/v%{version}/%{srcname}-%{version}.tar.gz.sig Source2: https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x8aed58021feacdd5f27ba0e6a72f627716ea9d96#./vermware.key +Patch1: py_mkdir.patch BuildArch: noarch @@ -74,7 +75,8 @@ This package contains documentation for developer documentation for %{srcname}. %py3_build %if %{with doc} # Build the documentation -%make_build DOXYGEN=$(which doxygen) PYTHONPATH=$(pwd) html +# Remove -W (turn warnings into errors) from SPHINXOPTS to fix the build for f39 +%make_build SPHINXOPTS="-v -E" DOXYGEN=$(which doxygen) PYTHONPATH=$(pwd) html # Remove temporary build files rm documentation/build/html/.buildinfo %endif