commit:     bc09138125aebb04ad3e6c4cecfff0277d7f3dbf
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Jun 15 07:38:08 2024 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Jun 15 08:14:56 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bc091381

dev-python/legacy-cgi: Add compat package for py3.13, v2.6

Add the compatibility `legacy-cgi` package that brings back `cgi`
modules in Python 3.13.  This is only meant as a stop-gap solution
to fix dead packages relying on the module.  As such, the package
is deprecated immediately.

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 dev-python/legacy-cgi/Manifest              |  1 +
 dev-python/legacy-cgi/legacy-cgi-2.6.ebuild | 30 +++++++++++++++++++++++++++++
 dev-python/legacy-cgi/metadata.xml          | 12 ++++++++++++
 profiles/package.deprecated                 |  5 +++++
 4 files changed, 48 insertions(+)

diff --git a/dev-python/legacy-cgi/Manifest b/dev-python/legacy-cgi/Manifest
new file mode 100644
index 000000000000..32ddc67cdb5a
--- /dev/null
+++ b/dev-python/legacy-cgi/Manifest
@@ -0,0 +1 @@
+DIST python-cgi-c6c8567a66f5ff8c5510755ca25a9bdd2756c4f6.gh.tar.gz 34964 
BLAKE2B 
0717bf9de721aef145443dd09475a4ed2d093bda0746512bc2074b2d7b90da37055662a47726240c9e7c07f0afca88639eb160d48289b0e9726e6638e1049b42
 SHA512 
0c0ca50a82a8fe76dd3eec56f75e408bbb035b16e726ba0156fd9360210068d63e7e3e60bd6f6793cef38276fc3c940d3195f7c0a9b1eea5056373358fbdb564

diff --git a/dev-python/legacy-cgi/legacy-cgi-2.6.ebuild 
b/dev-python/legacy-cgi/legacy-cgi-2.6.ebuild
new file mode 100644
index 000000000000..181f2547ee83
--- /dev/null
+++ b/dev-python/legacy-cgi/legacy-cgi-2.6.ebuild
@@ -0,0 +1,30 @@
+# Copyright 2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=poetry
+PYTHON_COMPAT=( python3_13 )
+
+inherit distutils-r1
+
+# this is 2.6 + tests
+EGIT_COMMIT=c6c8567a66f5ff8c5510755ca25a9bdd2756c4f6
+MY_P=python-cgi-${EGIT_COMMIT}
+DESCRIPTION="Fork of the standard library cgi and cgitb modules (deprecated)"
+HOMEPAGE="
+       https://github.com/jackrosenthal/python-cgi/
+       https://pypi.org/project/legacy-cgi/
+"
+# no tests in sdist
+SRC_URI="
+       
https://github.com/jackrosenthal/python-cgi/archive/${EGIT_COMMIT}.tar.gz
+               -> ${MY_P}.gh.tar.gz
+"
+S=${WORKDIR}/${MY_P}
+
+LICENSE="PSF-2"
+SLOT="0"
+KEYWORDS="~amd64"
+
+distutils_enable_tests pytest

diff --git a/dev-python/legacy-cgi/metadata.xml 
b/dev-python/legacy-cgi/metadata.xml
new file mode 100644
index 000000000000..1de0f4062d0f
--- /dev/null
+++ b/dev-python/legacy-cgi/metadata.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd";>
+<pkgmetadata>
+       <maintainer type="project">
+               <email>[email protected]</email>
+       </maintainer>
+       <stabilize-allarches/>
+       <upstream>
+               <remote-id type="github">jackrosenthal/python-cgi</remote-id>
+               <remote-id type="pypi">legacy-cgi</remote-id>
+       </upstream>
+</pkgmetadata>

diff --git a/profiles/package.deprecated b/profiles/package.deprecated
index 00fdb46f32af..c0bb1408ec78 100644
--- a/profiles/package.deprecated
+++ b/profiles/package.deprecated
@@ -17,6 +17,11 @@
 
 #--- END OF EXAMPLES ---
 
+# Michał Górny <[email protected]> (2024-06-15)
+# Stop-gap compatibility package.  Upstreams really need to move away
+# from the removed cgi module rather than rely on this.
+dev-python/legacy-cgi
+
 # Volkmar W. Pogatzki <[email protected]> (2024-03-10)
 # ant-core should no longer be ussed as of version 1.10.14 or higher.
 # It is now completely integrated in dev-java/ant and will be removed after a

Reply via email to