Backport upstream patch for fix build error

This commit is contained in:
liwenjun@kylinos.cn 2024-10-17 17:45:01 +08:00 committed by openkylin-cibot
parent bb837c7ea1
commit 9116b1e1e7
3 changed files with 34 additions and 0 deletions

6
debian/changelog vendored
View File

@ -1,3 +1,9 @@
sphinx-rtd-theme (2.0.0+dfsg-ok2) nile; urgency=medium
* Backport upstream patch for fix build error.
-- liwenjun <liwenjun@kylinos.cn> Thu, 17 Oct 2024 17:42:19 +0800
sphinx-rtd-theme (2.0.0+dfsg-ok1) nile; urgency=medium
* Build for openKylin.

View File

@ -0,0 +1,27 @@
From: "liwenjun@kylinos.cn" <liwenjun>
Date: Thu, 17 Oct 2024 17:45:01 +0800
Subject: Backport upstream patch for fix build error
---
tests/test_builders.py | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/tests/test_builders.py b/tests/test_builders.py
index d3d3c51..184e416 100644
--- a/tests/test_builders.py
+++ b/tests/test_builders.py
@@ -37,10 +37,13 @@ def test_basic():
)
assert search in content
elif isinstance(app.builder, SingleFileHTMLBuilder):
+ internal_ref = '#document-foo'
+ if sphinx.version_info[:3] < (7, 3, 0):
+ internal_ref = 'index.html' + internal_ref
search = (
'<ul>\n'
'<li class="toctree-l1">'
- '<a class="reference internal" href="index.html#document-foo">foo</a>'
+ f'<a class="reference internal" href="{internal_ref}">foo</a>'
'</li>\n'
'</ul>'
)

View File

@ -3,3 +3,4 @@ tests-configuration.patch
replace-webpack-imports.patch
do-not-override-build-commands.patch
remove-html5shiv.patch
0006-Backport-upstream-patch-for-fix-build-error.patch