commit:     4eccdb1b084607826d743347cb1370c528b7ab96
Author:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Fri Jan 20 03:52:31 2023 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Fri Jan 20 22:44:10 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4eccdb1b

www-client/qutebrowser: adjust 3.0.0_pre9999 ebuild

* show USE=-qt6 warning on amd64 (about to be unmasked) + note Qt5
  support is eventually due for removal (while upstream will keep
  supporting it for a while, they strongly recommend moving to Qt6)
* restore full set of keywords given USE=qt6 will remain masked on
  non-amd64 until keyworded. Not that it matters in live.
* minor style/comment adjustments

This ebuild will eventually replace 9999 after qt6-v2 is merged
to master, so not bothering to keep in sync for now.

Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 .../qutebrowser/qutebrowser-3.0.0_pre9999.ebuild   | 29 +++++++++++-----------
 1 file changed, 15 insertions(+), 14 deletions(-)

diff --git a/www-client/qutebrowser/qutebrowser-3.0.0_pre9999.ebuild 
b/www-client/qutebrowser/qutebrowser-3.0.0_pre9999.ebuild
index 5fa6c903ac8c..cffa4849cc2e 100644
--- a/www-client/qutebrowser/qutebrowser-3.0.0_pre9999.ebuild
+++ b/www-client/qutebrowser/qutebrowser-3.0.0_pre9999.ebuild
@@ -14,7 +14,7 @@ if [[ ${PV} == *9999 ]]; then
        EGIT_BRANCH="qt6-v2"
 else
        
SRC_URI="https://github.com/qutebrowser/qutebrowser/releases/download/v${PV}/${P}.tar.gz";
-       KEYWORDS="~amd64"
+       KEYWORDS="~amd64 ~arm64 ~x86"
 fi
 
 DESCRIPTION="Keyboard-driven, vim-like browser based on Python and Qt"
@@ -74,33 +74,33 @@ src_prepare() {
        distutils-r1_src_prepare
 
        if use pdf; then
-               sed '/^content.pdfjs:/,+1s/false/true/' \
+               sed -e '/^content.pdfjs:/,+1s/false/true/' \
                        -i ${PN}/config/configdata.yml || die
        fi
 
        if use widevine; then
-               # Qt6 knows Gentoo's, but pass to ensure libdir, EPREFIX, and 
for Qt5
+               # Qt6 knows Gentoo's, but pass for libdir, EPREFIX, and Qt5(bug 
#888783)
                local 
widevine=${EPREFIX}/usr/$(get_libdir)/chromium-browser/WidevineCdm/_platform_specific/linux_x64/libwidevinecdm.so
-               sed "/yield from _qtwebengine_settings_args/a\    yield 
'--widevine-path=${widevine}'" \
+               sed -e "/yield from _qtwebengine_settings_args/a\    yield 
'--widevine-path=${widevine}'" \
                        -i ${PN}/config/qtargs.py || die
        fi
 
        # ensure run the requested Qt backend
-       sed -i '/^_WRAPPERS = /,/^]/c\_WRAPPERS = [ "PyQt'$(usex qt6 6 5)'" ]' \
-               ${PN}/qt/machinery.py || die
+       sed -e '/^_WRAPPERS = /,/^]/c\_WRAPPERS = [ "PyQt'$(usex qt6 6 5)'" ]' \
+               -i ${PN}/qt/machinery.py || die
 
        # let eclass handle python
        sed -i '/setup.py/d' misc/Makefile || die
 
        if [[ ${PV} == *9999 ]]; then
                # call asciidoc(1) rather than the single target python module
-               sed '/cmdline = /s/= .*/= ["asciidoc"]/' \
+               sed -e '/cmdline = /s/= .*/= ["asciidoc"]/' \
                        -i scripts/asciidoc2html.py || die
 
                "${EPYTHON}" scripts/asciidoc2html.py || die
        fi
 
-       # disable unnecessary tests/plugins that need extras (_ignore not 
enough)
+       # disable unnecessary tests/plugins that need extras
        sed -e '/pytest-benchmark/d' -e 's/--benchmark[^ ]*//' \
                -e '/pytest-instafail/d' -e 's/--instafail//' \
                -i pytest.ini || die
@@ -175,10 +175,11 @@ pkg_postinst() {
                fi
        fi
 
-       # TODO: left-out given be confusing while IUSE is masked anywhere
-#      if use !qt6; then
-#              ewarn "USE=qt6 is disabled, be warned that Qt5's WebEngine uses 
an older"
-#              ewarn "chromium version. While it is relatively maintained for 
security, it may"
-#              ewarn "cause issues for sites/features designed with a newer 
version in mind."
-#      fi
+       # only show qt6 warning on arches where USE=qt6 is unmasked
+       if use amd64 && use !qt6; then
+               ewarn "USE=qt6 is disabled, be warned that Qt5's WebEngine uses 
an older"
+               ewarn "chromium version. While it is relatively maintained for 
security, it may"
+               ewarn "cause issues for sites/features designed with a newer 
version in mind."
+               ewarn "When Qt6 support is stable enough, ebuild's Qt5 support 
may get removed."
+       fi
 }

Reply via email to