commit:     bd5359cbda10c6ba292526e84f09f65dbd6b8bd1
Author:     Marek Szuba <marecki <AT> gentoo <DOT> org>
AuthorDate: Mon Jul 12 14:24:23 2021 +0000
Commit:     Marek Szuba <marecki <AT> gentoo <DOT> org>
CommitDate: Mon Jul 12 14:32:55 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bd5359cb

x11-terms/rxvt-unicode-9.26: only apply 24-bit-colour patch when needed

It's too aggressive, i.e. USE=-24-bit-color doesn't fully disable this
feature.

Closes: https://bugs.gentoo.org/801571
Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>

 ...-9.26-r1.ebuild => rxvt-unicode-9.26-r2.ebuild} | 39 +++++++++++++---------
 1 file changed, 24 insertions(+), 15 deletions(-)

diff --git a/x11-terms/rxvt-unicode/rxvt-unicode-9.26-r1.ebuild 
b/x11-terms/rxvt-unicode/rxvt-unicode-9.26-r2.ebuild
similarity index 80%
rename from x11-terms/rxvt-unicode/rxvt-unicode-9.26-r1.ebuild
rename to x11-terms/rxvt-unicode/rxvt-unicode-9.26-r2.ebuild
index 4fa68cb62a3..f439e028a7e 100644
--- a/x11-terms/rxvt-unicode/rxvt-unicode-9.26-r1.ebuild
+++ b/x11-terms/rxvt-unicode/rxvt-unicode-9.26-r2.ebuild
@@ -36,7 +36,6 @@ BDEPEND="virtual/pkgconfig"
 PATCHES=(
        "${FILESDIR}"/${PN}-9.06-case-insensitive-fs.patch
        "${FILESDIR}"/${PN}-9.21-xsubpp.patch
-       "${WORKDIR}"/${COLOUR_PATCH_NAME}
 )
 DOCS=(
        Changes
@@ -50,6 +49,11 @@ DOCS=(
 src_prepare() {
        default
 
+       # Current patch is too aggressive to apply unconditionally, see Bug 
#801571
+       if use 24-bit-color; then
+               eapply "${WORKDIR}"/${COLOUR_PATCH_NAME}
+       fi
+
        # kill the rxvt-unicode terminfo file - #192083
        sed -i -e "/rxvt-unicode.terminfo/d" doc/Makefile.in || die "sed failed"
 
@@ -59,21 +63,26 @@ src_prepare() {
 
 src_configure() {
        # --enable-everything goes first: the order of the arguments matters
-       econf --enable-everything \
-               $(use_enable 24-bit-color) \
-               $(use_enable 256-color) \
-               $(use_enable blink text-blink) \
-               $(use_enable fading-colors fading) \
-               $(use_enable font-styles) \
-               $(use_enable gdk-pixbuf pixbuf) \
-               $(use_enable iso14755) \
-               $(use_enable mousewheel) \
-               $(use_enable perl) \
-               $(use_enable startup-notification) \
-               $(use_enable unicode3) \
-               $(use_enable utmp) \
-               $(use_enable wtmp) \
+       local myconf=(
+               --enable-everything
+               $(use_enable 256-color)
+               $(use_enable blink text-blink)
+               $(use_enable fading-colors fading)
+               $(use_enable font-styles)
+               $(use_enable gdk-pixbuf pixbuf)
+               $(use_enable iso14755)
+               $(use_enable mousewheel)
+               $(use_enable perl)
+               $(use_enable startup-notification)
+               $(use_enable unicode3)
+               $(use_enable utmp)
+               $(use_enable wtmp)
                $(use_enable xft)
+       )
+       if use 24-bit-color; then
+               myconf+=( --enable-24-bit-color )
+       fi
+       econf "${myconf[@]}"
 }
 
 src_compile() {

Reply via email to