summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorD.M.D. Ljungmark <spider@gentoo.org>2003-02-03 03:36:08 +0000
committerD.M.D. Ljungmark <spider@gentoo.org>2003-02-03 03:36:08 +0000
commit98e9446e3635dddf139a0b9dbb92ac8e9439aa8d (patch)
treee0a28ca302d5726ec14b27a940fb9a177dc155b4 /net-irc
parentmore details in ChangeLog (diff)
downloadhistorical-98e9446e3635dddf139a0b9dbb92ac8e9439aa8d.tar.gz
historical-98e9446e3635dddf139a0b9dbb92ac8e9439aa8d.tar.bz2
historical-98e9446e3635dddf139a0b9dbb92ac8e9439aa8d.zip
add a new patch for xchat-2 to have tabs on left and right, merge the GTK icon patch with that as they conflict, then added a minor fix to make it work with tabs at bottom
Diffstat (limited to 'net-irc')
-rw-r--r--net-irc/xchat/ChangeLog9
-rw-r--r--net-irc/xchat/files/00_all_tabs-leftright-and-gtk-icons.patch424
-rw-r--r--net-irc/xchat/files/digest-xchat-2.0.0_pre1-r11
-rw-r--r--net-irc/xchat/xchat-2.0.0_pre1-r1.ebuild83
4 files changed, 516 insertions, 1 deletions
diff --git a/net-irc/xchat/ChangeLog b/net-irc/xchat/ChangeLog
index b101a4a92007..3fc49f64c6fc 100644
--- a/net-irc/xchat/ChangeLog
+++ b/net-irc/xchat/ChangeLog
@@ -1,7 +1,14 @@
# ChangeLog for net-irc/xchat
# Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL
-# $Header: /var/cvsroot/gentoo-x86/net-irc/xchat/ChangeLog,v 1.41 2003/02/02 01:17:52 foser Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-irc/xchat/ChangeLog,v 1.42 2003/02/03 03:36:07 spider Exp $
+*xchat-2.0.0pr1-r1 (02 Feb 2003)
+
+ 02 Feb 2003; Spider <spider@gentoo.org> xchat-2.0.0pr1-r1.ebuild :
+ added a patch to have tabs on left/right.
+ made that patch merged with gtk scrollbuttons
+ fixed it as per zed's comments on xchat-discuss
+
*xchat-2.0.0pre1 (26 Jan 2003)
01 Feb 2003; foser <foser@gentoo.org> xchat-2.0.0_pre1.ebuild :
diff --git a/net-irc/xchat/files/00_all_tabs-leftright-and-gtk-icons.patch b/net-irc/xchat/files/00_all_tabs-leftright-and-gtk-icons.patch
new file mode 100644
index 000000000000..e86405a0ebef
--- /dev/null
+++ b/net-irc/xchat/files/00_all_tabs-leftright-and-gtk-icons.patch
@@ -0,0 +1,424 @@
+diff -urw xchat-2.0.0pre1/src/fe-gtk/fe-gtk.h xchat-2.0.0pre1-patched/src/fe-gtk/fe-gtk.h
+--- xchat-2.0.0pre1/src/fe-gtk/fe-gtk.h 2003-01-01 07:08:05.000000000 +0100
++++ xchat-2.0.0pre1-patched/src/fe-gtk/fe-gtk.h 2003-02-03 04:00:12.000000000 +0100
+@@ -114,6 +114,7 @@
+ *topic_entry,
+ *note_book,
+ *main_vbox, /* container in TOPLEVEL window */
++ *main_table,
+ *user_tree, /* GtkTreeView */
+ *user_box,
+ *button_box_parent,
+diff -urw xchat-2.0.0pre1/src/fe-gtk/maingui.c xchat-2.0.0pre1-patched/src/fe-gtk/maingui.c
+--- xchat-2.0.0pre1/src/fe-gtk/maingui.c 2003-01-26 05:15:47.000000000 +0100
++++ xchat-2.0.0pre1-patched/src/fe-gtk/maingui.c 2003-02-03 04:28:48.000000000 +0100
+@@ -1723,6 +1723,9 @@
+ static void
+ mg_set_tabs_pos (session_gui *gui, int pos)
+ {
++ GtkOrientation orientation;
++ GtkWidget *new_tabs_box;
++
+ if (!gui)
+ {
+ gui = mg_gui;
+@@ -1730,23 +1733,42 @@
+ return;
+ }
+
++ gtk_widget_ref (gui->tabs_box);
++ gtk_container_remove (GTK_CONTAINER (gui->main_table), gui->tabs_box);
++
++ orientation = tab_group_get_orientation (gui->tabs_box);
++ if ((pos == 0 || pos == 1) && orientation == GTK_ORIENTATION_VERTICAL)
++ {
++ new_tabs_box = tab_group_set_orientation (gui->tabs_box, FALSE);
++ gtk_widget_unref (gui->tabs_box);
++ gui->tabs_box = new_tabs_box;
++ } else if((pos == 2 || pos == 3) && orientation == GTK_ORIENTATION_HORIZONTAL) {
++ new_tabs_box = tab_group_set_orientation (gui->tabs_box, TRUE);
++ gtk_widget_unref (gui->tabs_box);
++ gui->tabs_box = new_tabs_box;
++ }
++
+ gtk_widget_show (gui->tabs_box);
+
+ switch (pos)
+ {
+ case 0: /* bottom */
+- gtk_box_reorder_child (GTK_BOX (gui->main_vbox), gui->tabs_box, 9);
++ gtk_table_attach (GTK_TABLE (gui->main_table), gui->tabs_box,
++ 1, 2, 2, 3, GTK_FILL, GTK_FILL, 0, 0);
+ break;
+ case 1: /* top */
+- gtk_box_reorder_child (GTK_BOX (gui->main_vbox), gui->tabs_box, 1);
++ gtk_table_attach (GTK_TABLE (gui->main_table), gui->tabs_box,
++ 1, 2, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+ break;
+-#if 0
+ case 2: /* left */
++ gtk_table_attach (GTK_TABLE (gui->main_table), gui->tabs_box,
++ 0, 1, 1, 2, GTK_FILL, GTK_FILL, 0, 0);
+ break;
+ case 3: /* right */
++ gtk_table_attach (GTK_TABLE (gui->main_table), gui->tabs_box,
++ 2, 3, 1, 2, GTK_FILL, GTK_FILL, 0, 0);
+ break;
+-#endif
+- case 2: /* hidden */
++ case 4: /* hidden */
+ gtk_widget_hide (gui->tabs_box);
+ break;
+ }
+@@ -1824,7 +1846,8 @@
+ vert = TRUE;
+
+ gui->tabs_box = tab_group_new (mg_switch_tab_cb, vert);
+- gtk_box_pack_start (GTK_BOX (box), gui->tabs_box, 0, 0, 0);
++ gtk_table_attach (GTK_TABLE (gui->main_table), gui->tabs_box,
++ 1, 2, 0, 1, GTK_FILL, GTK_FILL, 0, 0);
+ }
+
+ static gboolean
+@@ -1993,6 +2016,7 @@
+ {
+ GtkWidget *win;
+ GtkWidget *vbox;
++ GtkWidget *table;
+ GtkWidget *book;
+
+ win = gtkutil_window_new ("X-Chat ["VERSION"]", prefs.mainwindow_width,
+@@ -2018,10 +2042,14 @@
+ sess->gui->main_vbox = vbox = gtk_vbox_new (FALSE, 1);
+ gtk_container_add (GTK_CONTAINER (win), vbox);
+
++ sess->gui->main_table = table = gtk_table_new (3, 3, FALSE);
++ gtk_container_add (GTK_CONTAINER (vbox), table);
++
+ sess->gui->note_book = book = gtk_notebook_new ();
+ gtk_notebook_set_show_tabs (GTK_NOTEBOOK (book), FALSE);
+ gtk_notebook_set_show_border (GTK_NOTEBOOK (book), FALSE);
+- gtk_container_add (GTK_CONTAINER (vbox), book);
++ gtk_table_attach (GTK_TABLE (table), book, 1, 2, 1, 2,
++ GTK_EXPAND | GTK_FILL, GTK_EXPAND | GTK_FILL, 0, 0);
+
+ mg_create_irctab (sess, book);
+ mg_create_tabs (sess->gui, vbox);
+@@ -2029,13 +2057,14 @@
+
+ mg_focus (sess);
+
+- if (prefs.tabs_position != 0)
++ if (prefs.tabs_position != 1)
+ mg_set_tabs_pos (sess->gui, prefs.tabs_position);
+
+ if (!prefs.hidemenu)
+ gtk_widget_show (sess->gui->menu);
+
+ gtk_widget_show (vbox);
++ gtk_widget_show (table);
+ gtk_widget_show_all (book);
+
+ if (prefs.hideuserlist)
+diff -urw xchat-2.0.0pre1/src/fe-gtk/setup.c xchat-2.0.0pre1-patched/src/fe-gtk/setup.c
+--- xchat-2.0.0pre1/src/fe-gtk/setup.c 2003-01-08 06:56:58.000000000 +0100
++++ xchat-2.0.0pre1-patched/src/fe-gtk/setup.c 2003-02-03 04:00:12.000000000 +0100
+@@ -145,8 +145,8 @@
+ {
+ N_("Bottom"),
+ N_("Top"),
+-/* N_("Left"),
+- N_("Right"),*/
++ N_("Left"),
++ N_("Right"),
+ N_("Hidden"),
+ NULL
+ };
+diff -urw xchat-2.0.0pre1/src/fe-gtk/tabs.c xchat-2.0.0pre1-patched/src/fe-gtk/tabs.c
+--- xchat-2.0.0pre1/src/fe-gtk/tabs.c 2003-01-18 03:43:43.000000000 +0100
++++ xchat-2.0.0pre1-patched/src/fe-gtk/tabs.c 2003-02-03 04:20:13.000000000 +0100
+@@ -3,6 +3,7 @@
+ #include <string.h>
+
+ #include <gtk/gtkhbox.h>
++#include <gtk/gtkvbox.h>
+ #include <gtk/gtktogglebutton.h>
+ #include <gtk/gtkwidget.h>
+ #include <gtk/gtkcontainer.h>
+@@ -12,6 +13,7 @@
+ #include <gtk/gtkvbox.h>
+ #include <gtk/gtkviewport.h>
+ #include <gtk/gtkvseparator.h>
++#include <gtk/gtkarrow.h>
+
+ /* keep this code generic, don't include xchat.h! */
+
+@@ -49,17 +51,20 @@
+ static void
+ tab_viewport_size_request (GtkWidget *widget, GtkRequisition *requisition, gpointer user_data)
+ {
++ if (GPOINTER_TO_INT (g_object_get_data (G_OBJECT (user_data), "v")) == 0)
+ requisition->width = 1;
+ requisition->height = 1;
+ }
+
+ static gint
+-tab_search_offset (GtkWidget *inner, gint start_offset, gboolean forward)
++tab_search_offset (GtkWidget *inner, gint start_offset,
++ gboolean forward, gboolean vertical)
+ {
+ GList *boxes;
+ GList *tabs;
+ GtkWidget *box;
+ GtkWidget *button;
++ gint found;
+
+ boxes = GTK_BOX (inner)->children;
+ if (!forward && boxes)
+@@ -82,9 +87,10 @@
+ if (!GTK_IS_TOGGLE_BUTTON (button))
+ continue;
+
+- if ((forward && button->allocation.x > start_offset) ||
+- (!forward && button->allocation.x < start_offset))
+- return button->allocation.x;
++ found = (vertical ? button->allocation.y : button->allocation.x);
++ if ((forward && found > start_offset) ||
++ (!forward && found < start_offset))
++ return found;
+ }
+ }
+
+@@ -92,21 +98,32 @@
+ }
+
+ static void
+-tab_scroll_left_clicked (GtkWidget *widget, GtkWidget *group)
++tab_scroll_left_up_clicked (GtkWidget *widget, GtkWidget *group)
+ {
+ GtkAdjustment *adj;
+- gint viewport_width;
++ gint viewport_size;
+ gfloat new_value;
+ GtkWidget *inner;
++ gint vertical;
+ gfloat i;
+
+ inner = g_object_get_data (G_OBJECT (group), "i");
++ vertical = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (group), "v"));
++
++ if (vertical)
++ {
++ adj = gtk_viewport_get_vadjustment (GTK_VIEWPORT (inner->parent));
++ gdk_window_get_geometry (inner->parent->window, 0, 0, 0, &viewport_size, 0);
++ } else
++ {
+ adj = gtk_viewport_get_hadjustment (GTK_VIEWPORT (inner->parent));
+- gdk_window_get_geometry (inner->parent->window, 0, 0, &viewport_width, 0, 0);
+- new_value = tab_search_offset (inner, adj->value, 0);
++ gdk_window_get_geometry (inner->parent->window, 0, 0, &viewport_size, 0, 0);
++ }
++
++ new_value = tab_search_offset (inner, adj->value, 0, vertical);
+
+- if (new_value + viewport_width > adj->upper)
+- new_value = adj->upper - viewport_width;
++ if (new_value + viewport_size > adj->upper)
++ new_value = adj->upper - viewport_size;
+
+ for (i = adj->value; i > new_value; i -= 0.1)
+ {
+@@ -119,21 +136,32 @@
+ }
+
+ static void
+-tab_scroll_right_clicked (GtkWidget *widget, GtkWidget *group)
++tab_scroll_right_down_clicked (GtkWidget *widget, GtkWidget *group)
+ {
+ GtkAdjustment *adj;
+- gint viewport_width;
++ gint viewport_size;
+ gfloat new_value;
+ GtkWidget *inner;
++ gint vertical;
+ gfloat i;
+
+ inner = g_object_get_data (G_OBJECT (group), "i");
++ vertical = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (group), "v"));
++
++ if (vertical)
++ {
++ adj = gtk_viewport_get_vadjustment (GTK_VIEWPORT (inner->parent));
++ gdk_window_get_geometry (inner->parent->window, 0, 0, 0, &viewport_size, 0);
++ } else
++ {
+ adj = gtk_viewport_get_hadjustment (GTK_VIEWPORT (inner->parent));
+- gdk_window_get_geometry (inner->parent->window, 0, 0, &viewport_width, 0, 0);
+- new_value = tab_search_offset (inner, adj->value, 1);
++ gdk_window_get_geometry (inner->parent->window, 0, 0, &viewport_size, 0, 0);
++ }
++
++ new_value = tab_search_offset (inner, adj->value, 1, vertical);
+
+- if (new_value == 0 || new_value + viewport_width > adj->upper)
+- new_value = adj->upper - viewport_width;
++ if (new_value == 0 || new_value + viewport_size > adj->upper)
++ new_value = adj->upper - viewport_size;
+
+ for (i = adj->value; i < new_value; i += 0.1)
+ {
+@@ -178,7 +206,7 @@
+ GtkWidget *box;
+ GtkWidget *viewport;
+ GtkWidget *group;
+- GtkWidget *button;
++ GtkWidget *button, *arrow;
+
+ if (vertical)
+ {
+@@ -192,7 +220,7 @@
+ viewport = gtk_viewport_new (0, 0);
+ gtk_viewport_set_shadow_type (GTK_VIEWPORT (viewport), GTK_SHADOW_NONE);
+ g_signal_connect (G_OBJECT (viewport), "size_request",
+- G_CALLBACK (tab_viewport_size_request), 0);
++ G_CALLBACK (tab_viewport_size_request), group);
+ gtk_box_pack_start (GTK_BOX (group), viewport, 1, 1, 0);
+ gtk_widget_show (viewport);
+
+@@ -204,17 +232,26 @@
+ gtk_container_add (GTK_CONTAINER (viewport), box);
+ gtk_widget_show (box);
+
+- button = gtk_button_new_with_label (">");
++
++ // button = gtk_button_new_with_label (vertical ? "v" : ">");
++ button = gtk_button_new ();
++ arrow = gtk_arrow_new (vertical ? GTK_ARROW_DOWN : GTK_ARROW_RIGHT , GTK_SHADOW_NONE);
++ gtk_container_add (GTK_CONTAINER (button), arrow);
++ gtk_widget_show (arrow);
+ gtk_button_set_relief (GTK_BUTTON (button), GTK_RELIEF_NONE);
+ g_signal_connect (G_OBJECT (button), "clicked",
+- G_CALLBACK (tab_scroll_right_clicked), group);
++ G_CALLBACK (tab_scroll_right_down_clicked), group);
+ gtk_widget_show (button);
+ gtk_box_pack_end (GTK_BOX (group), button, 0, 0, 0);
+
+- button = gtk_button_new_with_label ("<");
++ // button = gtk_button_new_with_label (vertical ? "^" : "<");
++ button = gtk_button_new ();
++ arrow = gtk_arrow_new (vertical ? GTK_ARROW_UP : GTK_ARROW_LEFT, GTK_SHADOW_NONE);
++ gtk_container_add (GTK_CONTAINER (button), arrow);
++ gtk_widget_show (arrow);
+ gtk_button_set_relief (GTK_BUTTON (button), GTK_RELIEF_NONE);
+ g_signal_connect (G_OBJECT (button), "clicked",
+- G_CALLBACK (tab_scroll_left_clicked), group);
++ G_CALLBACK (tab_scroll_left_up_clicked), group);
+ gtk_widget_show (button);
+ gtk_box_pack_end (GTK_BOX (group), button, 0, 0, 0);
+
+@@ -451,6 +488,7 @@
+ if (g_object_get_data (G_OBJECT (box), "f") == family)
+ {
+ tab_add_sorted (box, tab);
++ gtk_widget_queue_resize (inner->parent);
+ return;
+ }
+
+@@ -499,6 +537,7 @@
+ gtk_box_pack_start (GTK_BOX (box), tab, 0, 0, 0);
+ gtk_widget_show (tab);
+ gtk_widget_show (box);
++ gtk_widget_queue_resize (inner->parent);
+ }
+
+ static void
+@@ -577,6 +616,7 @@
+ tab_rename (GtkWidget *tab, char *new_name)
+ {
+ gtk_button_set_label (GTK_BUTTON (tab), new_name);
++ gtk_widget_queue_resize (tab->parent->parent->parent);
+ }
+
+ void
+@@ -616,3 +656,69 @@
+ tab_group_switch (group, 0, FALSE);
+ }
+ }
++
++GtkOrientation
++tab_group_get_orientation (GtkWidget *group)
++{
++ int vertical;
++ vertical = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (group), "v"));
++ return (vertical ? GTK_ORIENTATION_VERTICAL : GTK_ORIENTATION_HORIZONTAL);
++}
++
++GtkWidget *
++tab_group_set_orientation (GtkWidget *group, gboolean vertical)
++{
++ GtkWidget *box;
++ GtkWidget *new_group;
++ GList *boxes;
++ int is_vertical;
++
++ is_vertical = GPOINTER_TO_INT (g_object_get_data (G_OBJECT (group), "v"));
++ if ((vertical && is_vertical) || (!vertical && !is_vertical))
++ return group;
++
++ new_group = tab_group_new (g_object_get_data (G_OBJECT (group), "c"),
++ vertical);
++ g_object_set_data (G_OBJECT (new_group), "foc",
++ g_object_get_data (G_OBJECT (group), "foc"));
++ box = g_object_get_data (G_OBJECT (group), "i");
++ boxes = GTK_BOX (box)->children;
++ while (boxes)
++ {
++ GtkWidget *family_box;
++ GList *children;
++
++ family_box = ((GtkBoxChild *) boxes->data)->widget;
++ children = GTK_BOX (family_box)->children;
++
++ while (children)
++ {
++ GtkWidget *child;
++
++ child = ((GtkBoxChild *) children->data)->widget;
++
++ if (GTK_IS_TOGGLE_BUTTON (child))
++ {
++ void *family;
++
++ gtk_widget_ref (child);
++ gtk_container_remove (GTK_CONTAINER (family_box), child);
++ g_signal_handlers_disconnect_by_func (G_OBJECT (child),
++ G_CALLBACK (tab_pressed_cb), group);
++ g_signal_connect (G_OBJECT (child), "pressed",
++ G_CALLBACK (tab_pressed_cb), new_group);
++ family = g_object_get_data (G_OBJECT (child), "f");
++ g_object_set_data (G_OBJECT (child), "g", new_group);
++ tab_add_real (new_group, child, family);
++ gtk_widget_unref (child);
++ children = GTK_BOX (family_box)->children;
++ } else
++ children = children->next;
++ }
++
++ boxes = boxes->next;
++ }
++
++ return new_group;
++}
++
+diff -urw xchat-2.0.0pre1/src/fe-gtk/tabs.h xchat-2.0.0pre1-patched/src/fe-gtk/tabs.h
+--- xchat-2.0.0pre1/src/fe-gtk/tabs.h 2002-12-25 14:03:10.000000000 +0100
++++ xchat-2.0.0pre1-patched/src/fe-gtk/tabs.h 2003-02-03 04:00:12.000000000 +0100
+@@ -3,6 +3,8 @@
+ void tab_group_cleanup (GtkWidget *group);
+ int tab_group_get_size (GtkWidget *group);
+ GtkWidget *tab_group_add (GtkWidget *group, char *name, void *family, void *userdata, void *click_cb);
++GtkOrientation tab_group_get_orientation (GtkWidget *group);
++GtkWidget *tab_group_set_orientation (GtkWidget *group, gboolean vertical);
+
+ void tab_focus (GtkWidget *tab);
+ void tab_rename (GtkWidget *tab, char *new_name);
diff --git a/net-irc/xchat/files/digest-xchat-2.0.0_pre1-r1 b/net-irc/xchat/files/digest-xchat-2.0.0_pre1-r1
new file mode 100644
index 000000000000..c37db253d95f
--- /dev/null
+++ b/net-irc/xchat/files/digest-xchat-2.0.0_pre1-r1
@@ -0,0 +1 @@
+MD5 1aaa0477124897c4dcd26e8baba25226 xchat-2.0.0pre1.tar.bz2 875919
diff --git a/net-irc/xchat/xchat-2.0.0_pre1-r1.ebuild b/net-irc/xchat/xchat-2.0.0_pre1-r1.ebuild
new file mode 100644
index 000000000000..b05261426838
--- /dev/null
+++ b/net-irc/xchat/xchat-2.0.0_pre1-r1.ebuild
@@ -0,0 +1,83 @@
+# Copyright 1999-2002 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License, v2 or later
+# $Header: /var/cvsroot/gentoo-x86/net-irc/xchat/xchat-2.0.0_pre1-r1.ebuild,v 1.1 2003/02/03 03:36:08 spider Exp $
+
+inherit eutils
+
+IUSE="perl tcltk python gnome ssl gtk mmx ipv6 nls"
+
+P=${PN}-${PV/_/}
+S=${WORKDIR}/${P}
+
+DESCRIPTION="X-Chat is a graphical IRC client for UNIX operating systems."
+SRC_URI="http://www.xchat.org/files/source/1.9/${P}.tar.bz2"
+HOMEPAGE="http://www.xchat.org/"
+
+LICENSE="GPL-2"
+SLOT="2"
+KEYWORDS="~x86 ~ppc ~sparc ~alpha"
+
+RDEPEND=">=dev-libs/glib-2.0.3
+ >=x11-libs/gtk+-2.0.3
+ perl? ( >=sys-devel/perl-5.6.1 )
+ gnome? ( >=gnome-base/libgnome-2.0 )
+ ssl? ( >=dev-libs/openssl-0.9.6d )
+ python? ( dev-lang/python )
+ tcltk? ( dev-lang/tcl )"
+
+DEPEND="${RDEPEND}
+ nls? ( >=sys-devel/gettext-0.10.38 )"
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+ epatch ${FILESDIR}/00_all_tabs-leftright-and-gtk-icons.patch
+}
+
+src_compile() {
+ local myopts
+
+ use gnome \
+ && myopts="${myopts} --enable-gnome" \
+ || myopts="${myopts} --disable-gnome"
+ use gtk \
+ && myopts="${myopts} --enable-gtkfe" \
+ || myopts="${myopts} --disable-gtkfe"
+ use ssl \
+ && myopts="${myopts} --enable-openssl" \
+ || myopts="${myopts} --disable-openssl"
+ use perl \
+ && myopts="${myopts} --enable-perl" \
+ || myopts="${myopts} --disable-perl"
+ use python \
+ && myopts="${myopts} --enable-python" \
+ || myopts="${myopts} --disable-python"
+ use tcltk \
+ && myopts="${myopts} --enable-tcl" \
+ || myopts="${myopts} --disable-tcl"
+ use nls \
+ && myopts="${myopts} --enable-nls" \
+ || myopts="${myopts} --disable-nls"
+ use mmx \
+ && myopts="${myopts} --enable-mmx" \
+ || myopts="${myopts} --disable-mmx"
+ use ipv6 \
+ && myopts="${myopts} --enable-ipv6" \
+ || myopts="${myopts} --disable-ipv6"
+
+ econf \
+ --program-suffix=-2 \
+ ${myopts} || die "Configure failed"
+
+ MAKEOPTS="-j1" emake || die "Compile failed"
+}
+
+src_install() {
+ # some magic to create a menu entry for xchat 2
+ mv xchat.desktop xchat.desktop.old
+ sed -e "s:Exec=xchat:Exec=xchat-2:" -e "s:Name=XChat IRC:Name=XChat 2 IRC:" xchat.desktop.old > xchat.desktop
+
+ einstall install || die "Install failed"
+
+ dodoc AUTHORS COPYING ChangeLog README*
+}