commit:     e0690ffab43b375dd17e660562a5cb8c9e3107dc
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 17 23:51:54 2019 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Sun Mar 17 23:52:47 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e0690ffa

net-misc/putty: Add USE=gtk2

Package-Manager: Portage-2.3.62, Repoman-2.3.12
Fixes: https://bugs.gentoo.org/616412
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 net-misc/putty/metadata.xml      | 10 +++-------
 net-misc/putty/putty-0.71.ebuild |  7 ++++---
 net-misc/putty/putty-9999.ebuild |  7 ++++---
 3 files changed, 11 insertions(+), 13 deletions(-)

diff --git a/net-misc/putty/metadata.xml b/net-misc/putty/metadata.xml
index bff885218f3..6f7ffaa0c97 100644
--- a/net-misc/putty/metadata.xml
+++ b/net-misc/putty/metadata.xml
@@ -13,12 +13,8 @@ authentication protocols, and various other interesting 
things not provided by
 ssh in an xterm.
 </longdescription>
 <use>
-<flag name="gssapi">
-Enable support for GSSAPI (<pkg>virtual/krb5</pkg>)
-</flag>
-<flag name="gtk">
-Build the PuTTY client which requires <pkg>x11-libs/gtk+</pkg>:3. If disabled
-only the CLI tools puttygen, plink, pscp and psftp will be built.
-</flag>
+<flag name="gssapi">Enable support for GSSAPI (<pkg>virtual/krb5</pkg>)</flag>
+<flag name="gtk">Build the PuTTY client which requires 
<pkg>x11-libs/gtk+</pkg>. If disabled only the CLI tools puttygen, plink, pscp 
and psftp will be built</flag>
+<flag name="gtk2">Build the PuTTY client with <pkg>x11-libs/gtk+</pkg>:2 
instead of <pkg>x11-libs/gtk+</pkg>:3</flag>
 </use>
 </pkgmetadata>

diff --git a/net-misc/putty/putty-0.71.ebuild b/net-misc/putty/putty-0.71.ebuild
index 888ed3b7bbb..06b7756af05 100644
--- a/net-misc/putty/putty-0.71.ebuild
+++ b/net-misc/putty/putty-0.71.ebuild
@@ -10,7 +10,7 @@ LICENSE="MIT"
 
 SLOT="0"
 KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
-IUSE="doc +gtk ipv6 gssapi"
+IUSE="doc +gtk gtk2 ipv6 gssapi"
 SRC_URI="
        https://dev.gentoo.org/~jer/${PN}-icons.tar.bz2
        https://the.earth.li/~sgtatham/${PN}/latest/${P}.tar.gz
@@ -21,9 +21,10 @@ RDEPEND="
        gtk? (
                dev-libs/glib:2
                x11-libs/gdk-pixbuf
-               x11-libs/gtk+:3[X]
                x11-libs/libX11
                x11-libs/pango
+               gtk2? ( x11-libs/gtk+:2 )
+               !gtk2? ( x11-libs/gtk+:3[X] )
        )
        gssapi? ( virtual/krb5 )
 "
@@ -48,7 +49,7 @@ src_configure() {
        cd "${S}"/unix || die
        econf \
                $(use_with gssapi) \
-               $(use_with gtk)
+               $(usex gtk --with-gtk= --without-gtk $(usex gtk2 2 3 ) )
 }
 
 src_compile() {

diff --git a/net-misc/putty/putty-9999.ebuild b/net-misc/putty/putty-9999.ebuild
index 9d0477fe17e..00e78d96259 100644
--- a/net-misc/putty/putty-9999.ebuild
+++ b/net-misc/putty/putty-9999.ebuild
@@ -12,16 +12,17 @@ LICENSE="MIT"
 
 SLOT="0"
 KEYWORDS=""
-IUSE="doc +gtk ipv6 gssapi"
+IUSE="doc +gtk gtk2 ipv6 gssapi"
 
 RDEPEND="
        !net-misc/pssh
        gtk? (
                dev-libs/glib:2
                x11-libs/gdk-pixbuf
-               x11-libs/gtk+:3[X]
                x11-libs/libX11
                x11-libs/pango
+               gtk2? ( x11-libs/gtk+:2 )
+               !gtk2? ( x11-libs/gtk+:3[X] )
        )
        gssapi? ( virtual/krb5 )
 "
@@ -54,7 +55,7 @@ src_configure() {
        cd "${S}"/unix || die
        econf \
                $(use_with gssapi) \
-               $(use_with gtk gtk=3)
+               $(usex gtk --with-gtk= --without-gtk $(usex gtk2 2 3 ) )
 }
 
 src_compile() {

Reply via email to