mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
sphinx(python), add new/updated dependency python recipes (#8775)
* sphinx(python), add new/updated dependency python recipes * Update dev-python/babel/babel-2.12.1.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/babel/babel-2.12.1.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/babel/babel-2.12.1.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/pytest_mock/pytest_mock-3.10.0.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/pytest_mock/pytest_mock-3.10.0.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/sphinxcontrib-jquery/sphinxcontrib_jquery-4.1.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/sphinx/sphinx-7.0.1.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/sphinx/sphinx-7.0.1.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> * Update dev-python/sphinx/sphinx-7.0.1.recipe Co-authored-by: OscarL <oscar.lesta@gmail.com> --------- Co-authored-by: OscarL <oscar.lesta@gmail.com>
This commit is contained in:
82
dev-python/sphinxcontrib-qthelp/patches/14.patch
Normal file
82
dev-python/sphinxcontrib-qthelp/patches/14.patch
Normal file
@@ -0,0 +1,82 @@
|
||||
From 40f9dc8921486b7fd8ac84964f1e45103b540b81 Mon Sep 17 00:00:00 2001
|
||||
From: MeggyCal <MeggyCal@users.noreply.github.com>
|
||||
Date: Wed, 1 Jun 2022 10:35:11 +0200
|
||||
Subject: [PATCH] Fix tests with Sphinx 5.0
|
||||
|
||||
---
|
||||
tests/test_qthelp.py | 20 ++++++++++----------
|
||||
1 file changed, 10 insertions(+), 10 deletions(-)
|
||||
|
||||
diff --git a/tests/test_qthelp.py b/tests/test_qthelp.py
|
||||
index fd83241..4c5f77d 100644
|
||||
--- a/tests/test_qthelp.py
|
||||
+++ b/tests/test_qthelp.py
|
||||
@@ -17,7 +17,7 @@
|
||||
def test_qthelp_basic(app, status, warning):
|
||||
app.builder.build_all()
|
||||
|
||||
- qhp = (app.outdir / 'Python.qhp').text()
|
||||
+ qhp = (app.outdir / 'Python.qhp').read_text()
|
||||
assert '<customFilter name="Python ">' in qhp
|
||||
assert '<filterAttribute>Python</filterAttribute>' in qhp
|
||||
assert '<filterAttribute></filterAttribute>' in qhp
|
||||
@@ -26,7 +26,7 @@ def test_qthelp_basic(app, status, warning):
|
||||
assert '<file>index.html</file>' in qhp
|
||||
assert '<file>_static/basic.css</file>' in qhp
|
||||
|
||||
- qhcp = (app.outdir / 'Python.qhcp').text()
|
||||
+ qhcp = (app.outdir / 'Python.qhcp').read_text()
|
||||
assert '<title>Python documentation</title>' in qhcp
|
||||
assert '<homePage>qthelp://org.sphinx.python/doc/index.html</homePage>' in qhcp
|
||||
assert '<startPage>qthelp://org.sphinx.python/doc/index.html</startPage>' in qhcp
|
||||
@@ -91,10 +91,10 @@ def test_qthelp_namespace(app, status, warning):
|
||||
# default namespace
|
||||
app.builder.build_all()
|
||||
|
||||
- qhp = (app.outdir / 'Python.qhp').text()
|
||||
+ qhp = (app.outdir / 'Python.qhp').read_text()
|
||||
assert '<namespace>org.sphinx.python</namespace>' in qhp
|
||||
|
||||
- qhcp = (app.outdir / 'Python.qhcp').text()
|
||||
+ qhcp = (app.outdir / 'Python.qhcp').read_text()
|
||||
assert '<homePage>qthelp://org.sphinx.python/doc/index.html</homePage>' in qhcp
|
||||
assert '<startPage>qthelp://org.sphinx.python/doc/index.html</startPage>' in qhcp
|
||||
|
||||
@@ -102,10 +102,10 @@ def test_qthelp_namespace(app, status, warning):
|
||||
app.config.qthelp_namespace = 'org.sphinx-doc.sphinx'
|
||||
app.builder.build_all()
|
||||
|
||||
- qhp = (app.outdir / 'Python.qhp').text()
|
||||
+ qhp = (app.outdir / 'Python.qhp').read_text()
|
||||
assert '<namespace>org.sphinx-doc.sphinx</namespace>' in qhp
|
||||
|
||||
- qhcp = (app.outdir / 'Python.qhcp').text()
|
||||
+ qhcp = (app.outdir / 'Python.qhcp').read_text()
|
||||
assert '<homePage>qthelp://org.sphinx-doc.sphinx/doc/index.html</homePage>' in qhcp
|
||||
assert '<startPage>qthelp://org.sphinx-doc.sphinx/doc/index.html</startPage>' in qhcp
|
||||
|
||||
@@ -115,10 +115,10 @@ def test_qthelp_title(app, status, warning):
|
||||
# default title
|
||||
app.builder.build_all()
|
||||
|
||||
- qhp = (app.outdir / 'Python.qhp').text()
|
||||
+ qhp = (app.outdir / 'Python.qhp').read_text()
|
||||
assert '<section title="Python documentation" ref="index.html">' in qhp
|
||||
|
||||
- qhcp = (app.outdir / 'Python.qhcp').text()
|
||||
+ qhcp = (app.outdir / 'Python.qhcp').read_text()
|
||||
assert '<title>Python documentation</title>' in qhcp
|
||||
|
||||
# give a title
|
||||
@@ -126,9 +126,9 @@ def test_qthelp_title(app, status, warning):
|
||||
app.config.html_short_title = 'Sphinx <b>"short"</b> title'
|
||||
app.builder.build_all()
|
||||
|
||||
- qhp = (app.outdir / 'Python.qhp').text()
|
||||
+ qhp = (app.outdir / 'Python.qhp').read_text()
|
||||
assert ('<section title="Sphinx <b>"full"</b> title" ref="index.html">'
|
||||
in qhp)
|
||||
|
||||
- qhcp = (app.outdir / 'Python.qhcp').text()
|
||||
+ qhcp = (app.outdir / 'Python.qhcp').read_text()
|
||||
assert '<title>Sphinx <b>"short"</b> title</title>' in qhcp
|
||||
@@ -0,0 +1,74 @@
|
||||
SUMMARY="A sphinx extension which outputs QtHelp document"
|
||||
DESCRIPTION="sphinxcontrib-qthelp is a sphinx extension which outputs QtHelp document."
|
||||
HOMEPAGE="http://sphinx-doc.org/
|
||||
https://pypi.org/project/sphinxcontrib-qthelp/"
|
||||
COPYRIGHT="2007-2019 by the Sphinx team"
|
||||
LICENSE="BSD (2-clause)"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://pypi.python.org/packages/source/s/sphinxcontrib-qthelp/sphinxcontrib-qthelp-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="4c33767ee058b70dba89a6fc5c1892c0d57a54be67ddd3e7875a18d14cba5a72"
|
||||
SOURCE_DIR="sphinxcontrib-qthelp-$portVersion"
|
||||
PATCHES="14.patch" # from upstream
|
||||
|
||||
ARCHITECTURES="any"
|
||||
|
||||
PROVIDES="
|
||||
$portName = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
"
|
||||
|
||||
PYTHON_PACKAGES=(python39 python310)
|
||||
PYTHON_VERSIONS=(3.9 3.10)
|
||||
defaultTestVersion="python39"
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonPackage=${PYTHON_PACKAGES[i]}
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
eval "PROVIDES_$pythonPackage=\"
|
||||
${portName}_$pythonPackage = $portVersion
|
||||
\""
|
||||
eval "REQUIRES_$pythonPackage=\"
|
||||
haiku
|
||||
cmd:python$pythonVersion
|
||||
\""
|
||||
BUILD_REQUIRES+="
|
||||
build_$pythonPackage
|
||||
installer_$pythonPackage
|
||||
setuptools_$pythonPackage
|
||||
wheel_$pythonPackage
|
||||
"
|
||||
BUILD_PREREQUIRES+="
|
||||
cmd:python$pythonVersion
|
||||
"
|
||||
done
|
||||
|
||||
TEST_REQUIRES="
|
||||
sphinx_$defaultTestVersion
|
||||
cmd:pytest
|
||||
"
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
for i in "${!PYTHON_PACKAGES[@]}"; do
|
||||
pythonVersion=${PYTHON_VERSIONS[$i]}
|
||||
|
||||
python=python$pythonVersion
|
||||
|
||||
$python -m build --wheel --skip-dependency-check --no-isolation
|
||||
$python -m installer -p $prefix dist/*.whl
|
||||
|
||||
packageEntries ${PYTHON_PACKAGES[i]} \
|
||||
$prefix/lib/python*
|
||||
done
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
pytest -v
|
||||
}
|
||||
Reference in New Issue
Block a user