new file mode 100644
@@ -0,0 +1,20 @@
+SUMMARY = "Sphinx SVG to PDF or PNG converter extension"
+HOMEPAGE = "https://github.com/missinglinkelectronics/sphinxcontrib-svg2pdfconverter"
+LICENSE = "BSD-2-Clause"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=b11cf936853a71258d4b57bb1849a3f9"
+
+SRC_URI[sha256sum] = "ab9c8f1080391e231812d20abf2657a69ee35574563b1014414f953964a95fa3"
+
+inherit pypi python_setuptools_build_meta
+
+PYPI_PACKAGE = "sphinxcontrib_svg2pdfconverter"
+UPSTREAM_CHECK_PYPI_PACKAGE = "${PYPI_PACKAGE}"
+
+RDEPENDS:${PN} = "python3-sphinx"
+# Only support sphinxcontrib.rsvgconverter for now.
+# As cairosvgconverter depends on cairosvg module, no recipe available yet
+# As inkscapeconverter depends on inkscape, recipe in meta-office, 3rd-party
+# layer not updated in years
+RDEPENDS:${PN} += "librsvg"
+
+BBCLASSEXTEND = "native nativesdk"
@@ -858,10 +858,14 @@ class PythonPyprojectTomlRecipeHandler(PythonRecipeHandler):
if metadata:
for field, values in metadata.items():
if field == "license":
- # For setuptools.build_meta and flit, licence is a table
+ # For flit, licence is a table
+ # For setuptools.build_meta, license can be:
+ # - an SPDX license expression as string, since PEP-0639,
+ # - a table, pre-PEP-0639,
# but for poetry licence is a string
# for hatchling, both table (jsonschema) and string (iniconfig) have been used
- if build_backend == "poetry.core.masonry.api":
+ if build_backend == "poetry.core.masonry.api" or \
+ (build_backend == "setuptools.build_meta" and type(values) == str):
value = values
else:
value = values.get("text", "")