app-editors/emacs-vcs: Reorganise gtk* flags.
authorUlrich Müller <ulm@gentoo.org>
Thu, 23 Aug 2018 17:07:20 +0000 (19:07 +0200)
committerUlrich Müller <ulm@gentoo.org>
Thu, 23 Aug 2018 17:08:38 +0000 (19:08 +0200)
As discussed with leio in #gentoo-dev and in #gentoo-qa.
- USE="gtk -gtk2" for GTK+ version 3,
- USE="gtk gtk2" for GTK+ version 2,
- USE="-gtk" for no GTK+ (the "gtk2" flag has no effect).

Package-Manager: Portage-2.3.48, Repoman-2.3.10

app-editors/emacs-vcs/emacs-vcs-26.1.9999.ebuild
app-editors/emacs-vcs/emacs-vcs-27.0.50_pre20180731.ebuild
app-editors/emacs-vcs/emacs-vcs-27.0.9999.ebuild
app-editors/emacs-vcs/metadata.xml

index 79e76df1347874eb82d973e0b226942e7f550843..1f69edf59adedc270a088f47dcdb37023fe11b48 100644 (file)
@@ -28,7 +28,7 @@ HOMEPAGE="https://www.gnu.org/software/emacs/"
 
 LICENSE="GPL-3+ FDL-1.3+ BSD HPND MIT W3C unicode PSF-2"
 SLOT="26"
-IUSE="acl alsa aqua athena cairo dbus dynamic-loading games gconf gfile gif gpm gsettings gtk +gtk3 gzip-el imagemagick +inotify jpeg kerberos lcms libxml2 livecd m17n-lib mailutils motif png selinux sound source ssl svg systemd +threads tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
+IUSE="acl alsa aqua athena cairo dbus dynamic-loading games gconf gfile gif gpm gsettings gtk gtk2 gzip-el imagemagick +inotify jpeg kerberos lcms libxml2 livecd m17n-lib mailutils motif png selinux sound source ssl svg systemd +threads tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
 REQUIRED_USE="?? ( aqua X )"
 RESTRICT="test"
 
@@ -80,14 +80,13 @@ RDEPEND="sys-libs/ncurses:0=
                        )
                )
                gtk? (
-                       xwidgets? (
-                               net-libs/webkit-gtk:4=
+                       gtk2? ( x11-libs/gtk+:2 )
+                       !gtk2? (
                                x11-libs/gtk+:3
-                               x11-libs/libXcomposite
-                       )
-                       !xwidgets? (
-                               gtk3? ( x11-libs/gtk+:3 )
-                               !gtk3? ( x11-libs/gtk+:2 )
+                               xwidgets? (
+                                       net-libs/webkit-gtk:4=
+                                       x11-libs/libXcomposite
+                               )
                        )
                )
                !gtk? (
@@ -210,11 +209,12 @@ src_configure() {
                                recommended that you compile Emacs with the Athena/Lucid or the
                                Motif toolkit instead.
                        EOF
-                       if use xwidgets; then
-                               myconf+=" --with-x-toolkit=gtk3 --with-xwidgets"
+                       if use gtk2; then
+                               myconf+=" --with-x-toolkit=gtk2 --without-xwidgets"
+                               use xwidgets && ewarn \
+                                       "USE flag \"xwidgets\" has no effect if \"gtk2\" is set."
                        else
-                               myconf+=" --with-x-toolkit=$(usex gtk3 gtk3 gtk2)"
-                               myconf+=" --without-xwidgets"
+                               myconf+=" --with-x-toolkit=gtk3 $(use_with xwidgets)"
                        fi
                        for f in motif Xaw3d athena; do
                                use ${f} && ewarn \
index ee8f5f2ac3c2001191808080ffd925950c89b3fc..c5898b1c2dd7022d0c773b6c2c540897ef46df72 100644 (file)
@@ -28,7 +28,7 @@ HOMEPAGE="https://www.gnu.org/software/emacs/"
 
 LICENSE="GPL-3+ FDL-1.3+ BSD HPND MIT W3C unicode PSF-2"
 SLOT="27"
-IUSE="acl alsa aqua athena cairo dbus dynamic-loading games gconf gfile gif gpm gsettings gtk +gtk3 gzip-el imagemagick +inotify jpeg json kerberos lcms libxml2 livecd m17n-lib mailutils motif png selinux sound source ssl svg systemd +threads tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
+IUSE="acl alsa aqua athena cairo dbus dynamic-loading games gconf gfile gif gpm gsettings gtk gtk2 gzip-el imagemagick +inotify jpeg json kerberos lcms libxml2 livecd m17n-lib mailutils motif png selinux sound source ssl svg systemd +threads tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
 REQUIRED_USE="?? ( aqua X )"
 RESTRICT="test"
 
@@ -81,14 +81,13 @@ RDEPEND="sys-libs/ncurses:0=
                        )
                )
                gtk? (
-                       xwidgets? (
-                               net-libs/webkit-gtk:4=
+                       gtk2? ( x11-libs/gtk+:2 )
+                       !gtk2? (
                                x11-libs/gtk+:3
-                               x11-libs/libXcomposite
-                       )
-                       !xwidgets? (
-                               gtk3? ( x11-libs/gtk+:3 )
-                               !gtk3? ( x11-libs/gtk+:2 )
+                               xwidgets? (
+                                       net-libs/webkit-gtk:4=
+                                       x11-libs/libXcomposite
+                               )
                        )
                )
                !gtk? (
@@ -211,11 +210,12 @@ src_configure() {
                                recommended that you compile Emacs with the Athena/Lucid or the
                                Motif toolkit instead.
                        EOF
-                       if use xwidgets; then
-                               myconf+=" --with-x-toolkit=gtk3 --with-xwidgets"
+                       if use gtk2; then
+                               myconf+=" --with-x-toolkit=gtk2 --without-xwidgets"
+                               use xwidgets && ewarn \
+                                       "USE flag \"xwidgets\" has no effect if \"gtk2\" is set."
                        else
-                               myconf+=" --with-x-toolkit=$(usex gtk3 gtk3 gtk2)"
-                               myconf+=" --without-xwidgets"
+                               myconf+=" --with-x-toolkit=gtk3 $(use_with xwidgets)"
                        fi
                        for f in motif Xaw3d athena; do
                                use ${f} && ewarn \
index 2fef204a39064fbddc4e2883c628fe6d1f2dcc16..3cb2cdf754ad664dd4d957880ebd8aea53a33048 100644 (file)
@@ -28,7 +28,7 @@ HOMEPAGE="https://www.gnu.org/software/emacs/"
 
 LICENSE="GPL-3+ FDL-1.3+ BSD HPND MIT W3C unicode PSF-2"
 SLOT="27"
-IUSE="acl alsa aqua athena cairo dbus dynamic-loading games gconf gfile gif +gmp gpm gsettings gtk +gtk3 gzip-el imagemagick +inotify jpeg json kerberos lcms libxml2 livecd m17n-lib mailutils motif png selinux sound source ssl svg systemd +threads tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
+IUSE="acl alsa aqua athena cairo dbus dynamic-loading games gconf gfile gif +gmp gpm gsettings gtk gtk2 gzip-el imagemagick +inotify jpeg json kerberos lcms libxml2 livecd m17n-lib mailutils motif png selinux sound source ssl svg systemd +threads tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
 REQUIRED_USE="?? ( aqua X )"
 RESTRICT="test"
 
@@ -82,14 +82,13 @@ RDEPEND="sys-libs/ncurses:0=
                        )
                )
                gtk? (
-                       xwidgets? (
-                               net-libs/webkit-gtk:4=
+                       gtk2? ( x11-libs/gtk+:2 )
+                       !gtk2? (
                                x11-libs/gtk+:3
-                               x11-libs/libXcomposite
-                       )
-                       !xwidgets? (
-                               gtk3? ( x11-libs/gtk+:3 )
-                               !gtk3? ( x11-libs/gtk+:2 )
+                               xwidgets? (
+                                       net-libs/webkit-gtk:4=
+                                       x11-libs/libXcomposite
+                               )
                        )
                )
                !gtk? (
@@ -213,11 +212,12 @@ src_configure() {
                                recommended that you compile Emacs with the Athena/Lucid or the
                                Motif toolkit instead.
                        EOF
-                       if use xwidgets; then
-                               myconf+=" --with-x-toolkit=gtk3 --with-xwidgets"
+                       if use gtk2; then
+                               myconf+=" --with-x-toolkit=gtk2 --without-xwidgets"
+                               use xwidgets && ewarn \
+                                       "USE flag \"xwidgets\" has no effect if \"gtk2\" is set."
                        else
-                               myconf+=" --with-x-toolkit=$(usex gtk3 gtk3 gtk2)"
-                               myconf+=" --without-xwidgets"
+                               myconf+=" --with-x-toolkit=gtk3 $(use_with xwidgets)"
                        fi
                        for f in motif Xaw3d athena; do
                                use ${f} && ewarn \
index 3562545ef0a4bebdb2daa487deeb74b19119743c..d60762a414da3bc4c8d2adeeec1c4e171b199f84 100644 (file)
@@ -31,7 +31,7 @@
     notification</flag>
   <flag name="gsettings">Use gsettings (<pkg>dev-libs/glib</pkg>) to read the
     system font name</flag>
-  <flag name="gtk3">Prefer version 3 of the GIMP Toolkit to version 2
+  <flag name="gtk2">Prefer version 2 of the GIMP Toolkit to version 3
     (<pkg>x11-libs/gtk+</pkg>)</flag>
   <flag name="gzip-el">Compress bundled Emacs Lisp source</flag>
   <flag name="imagemagick">Use <pkg>media-gfx/imagemagick</pkg> for image