commit:     514824518d83a1eaf42b6512972980d238e2feaf
Author:     Philipp Rösner <rndxelement <AT> protonmail <DOT> com>
AuthorDate: Wed Jul 26 14:42:25 2023 +0000
Commit:     Joonas Niilola <juippis <AT> gentoo <DOT> org>
CommitDate: Mon Aug 14 07:02:28 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=51482451

app-editors/retext: pep517 support for live ebuild

Add support for PEP517 using the setuptools backend for
the live ebuild of app-editors/retext.

Bug: https://bugs.gentoo.org/909870
Signed-off-by: Philipp Rösner <rndxelement <AT> protonmail.com>
Closes: https://github.com/gentoo/gentoo/pull/32054
Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>

 app-editors/retext/retext-9999.ebuild | 19 +++++++++++++------
 1 file changed, 13 insertions(+), 6 deletions(-)

diff --git a/app-editors/retext/retext-9999.ebuild 
b/app-editors/retext/retext-9999.ebuild
index 7f375768199a..aa9aaadfcf57 100644
--- a/app-editors/retext/retext-9999.ebuild
+++ b/app-editors/retext/retext-9999.ebuild
@@ -3,14 +3,12 @@
 
 EAPI=8
 
-# Please don't add pypy support before testing if it's actually supported. The
-# old compat matrix is no longer accessible as of 2021-02-13 but stated back
-# in 2020-07-05 that PyQt5 was explicitly not supported.
+DISTUTILS_USE_PEP517="setuptools"
 PYTHON_COMPAT=( python3_{9..11} )
 PYPI_NO_NORMALIZE=1
 PYPI_PN="ReText"
 
-inherit distutils-r1 optfeature qmake-utils virtualx xdg
+inherit desktop distutils-r1 optfeature qmake-utils virtualx xdg
 
 DESCRIPTION="Simple editor for Markdown and reStructuredText"
 HOMEPAGE="https://github.com/retext-project/retext 
https://github.com/retext-project/retext/wiki";
@@ -49,6 +47,13 @@ pkg_setup() {
        export PATH="$(qt5_get_bindir):${PATH}"
 }
 
+python_install() {
+       distutils-r1_python_install
+
+       newicon data/retext-kde5.png retext.png
+       make_desktop_entry ${PN} "ReText" ${PN} "Office;WordProcessor"
+}
+
 src_test() {
        virtx distutils-r1_src_test
 }
@@ -61,11 +66,13 @@ pkg_postinst() {
        xdg_pkg_postinst
 
        optfeature "dictionary support" dev-python/pyenchant
-       # See https://bugs.gentoo.org/772197.
-       optfeature "rendering with webengine" dev-python/PyQt6-WebEngine
 
        einfo "Starting with retext-7.0.4 the markdown-math plugin is 
installed."
        einfo "Note that you can use different math delimiters, e.g. \(...\) 
for inline math."
        einfo "For more details take a look at:"
        einfo "https://github.com/mitya57/python-markdown-math#math-delimiters";
 }
+
+pkg_postrm() {
+       xdg_icon_cache_update
+}

Reply via email to