net-misc/putty: Add USE=gtk2
authorJeroen Roovers <jer@gentoo.org>
Sun, 17 Mar 2019 23:51:54 +0000 (00:51 +0100)
committerJeroen Roovers <jer@gentoo.org>
Sun, 17 Mar 2019 23:52:47 +0000 (00:52 +0100)
Package-Manager: Portage-2.3.62, Repoman-2.3.12
Fixes: https://bugs.gentoo.org/616412
Signed-off-by: Jeroen Roovers <jer@gentoo.org>
net-misc/putty/metadata.xml
net-misc/putty/putty-0.71.ebuild
net-misc/putty/putty-9999.ebuild

index bff885218f396f49fa6325b0b2efadd47e49aca7..6f7ffaa0c9724c8d511e5c7f7de123b5e57c2b19 100644 (file)
@@ -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>
index 888ed3b7bbbb1e7c39897f6a9d354a0f9fdbbf8d..06b7756af0599da298a409b637094500f6f23269 100644 (file)
@@ -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() {
index 9d0477fe17e1ecdaacd2bdc5bbbe99885b61960a..00e78d96259b67ab124aa7106149587c38865329 100644 (file)
@@ -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() {