Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Ebuild: app-editors/gedit-2.22.3 with Symbol Browser Plugin
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Unsupported Software
View previous topic :: View next topic  
Author Message
syslock
n00b
n00b


Joined: 02 Aug 2008
Posts: 1

PostPosted: Sat Aug 02, 2008 11:37 pm    Post subject: Ebuild: app-editors/gedit-2.22.3 with Symbol Browser Plugin Reply with quote

Hi all,

I modified the gedit-2.22.3 ebuild from portage to include the Symbol Browser Plugin from http://www.micahcarrick.com/11-14-2007/gedit-symbol-browser-plugin.html. I make it available here, so anyone interested can test it without much headache. Just put the ebuild and the patch file to your overlay and emerge it with USE="symbol-browser". Please note that it has an additional dependency on dev-util/ctags.

app-editors/gedit/gedit-2.22.3.ebuild:
Code:
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-editors/gedit/gedit-2.22.3.ebuild,v 1.3 2008/07/30 22:03:20 ranger Exp $

inherit gnome2 python eutils autotools

DESCRIPTION="A text editor for the GNOME desktop"
HOMEPAGE="http://www.gnome.org/"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd"
IUSE="doc python spell xattr symbol-browser"

# gedit sources itself seem to be defined indirectly or elsewhere
SRC_URI="${SRC_URI} http://surfnet.dl.sourceforge.net/sourceforge/symbol-browser/gedit-symbol-browser-plugin-0.1.tar.gz"

RDEPEND=">=gnome-base/gconf-2
   xattr? ( sys-apps/attr )
   >=dev-libs/glib-2.14
   >=x11-libs/gtk+-2.12
   >=x11-libs/gtksourceview-2.2
   >=gnome-base/libgnomeui-2.16
   >=gnome-base/libglade-2.5.1
   >=gnome-base/gnome-vfs-2.16
   spell? (
      >=app-text/enchant-1.2
      app-text/iso-codes
   )
   python? (
      >=dev-python/pygobject-2.12
      >=dev-python/pygtk-2.12
      >=dev-python/pygtksourceview-2.2
   )
   symbol-browser? ( dev-util/ctags )"

DEPEND="${RDEPEND}
   sys-devel/gettext
   >=dev-util/pkgconfig-0.9
   >=app-text/scrollkeeper-0.3.11
   >=dev-util/intltool-0.35
   >=app-text/gnome-doc-utils-0.3.2
   gnome-base/gnome-common"
# gnome-common needed to eautoreconf

DOCS="AUTHORS BUGS ChangeLog MAINTAINERS NEWS README"

if [[ "${ARCH}" == "PPC" ]] ; then
   # HACK HACK HACK: someone fix this garbage
   MAKEOPTS="${MAKEOPTS} -j1"
fi

pkg_setup() {
   G2CONF="${G2CONF}
      --disable-scrollkeeper
      $(use_enable python)
      $(use_enable spell)
      $(use_enable xattr attr)"
}

src_unpack() {
   gnome2_src_unpack

   # Remove symbols that are not meant to be part of the docs, and
   # break compilation if USE="doc -python" (bug #158638).
   if use !python && use doc; then
      epatch "${FILESDIR}"/${PN}-2.16.2-no_python_module_docs.patch
   fi

   # chown on fbsd doesn't have --reference.  Bug #183691
   epatch "${FILESDIR}"/${PN}-2.18.1-fbsd.patch

   # fixes failing python test due to libtool 2.2, bug #216110
   epatch "${FILESDIR}/${PN}-2.22.1-fix-libtool-2.2.patch"
   
   # http://www.micahcarrick.com/11-14-2007/gedit-symbol-browser-plugin.html
   if use symbol-browser; then
       mv "$S/../symbolbrowser" "$S/plugins/"
       find "$S/plugins/symbolbrowser" -name "Makefile" -exec rm {} \;
       find "$S/plugins/symbolbrowser" -name "Makefile.in" -exec rm {} \;
       epatch "${FILESDIR}/${PN}-2.22.3-symbolbrowser.patch"
   fi

   # disable pyc compiling
   mv "${S}"/py-compile "${S}"/py-compile.orig
   ln -s $(type -P true) "${S}"/py-compile

   eautoreconf
}

pkg_postinst() {
   use python && python_mod_optimize /usr/$(get_libdir)/gedit-2/plugins
}

pkg_postrm() {
   use python && python_mod_cleanup /usr/$(get_libdir)/gedit-2/plugins
}


app-editors/gedit/files/gedit-2.22.3-symbolbrowser.patch
Code:
diff -ur gedit-2.22.3/configure.ac gedit-2.22.3-symbolbrowser/configure.ac
--- gedit-2.22.3/configure.ac   2008-08-02 03:06:20.000000000 +0200
+++ gedit-2.22.3-symbolbrowser/configure.ac   2008-08-02 03:35:49.000000000 +0200
@@ -384,7 +384,9 @@
 plugins/spell/Makefile
 plugins/taglist/Makefile
 plugins/time/Makefile
-po/Makefile.in])
+po/Makefile.in
+plugins/symbolbrowser/Makefile
+plugins/symbolbrowser/symbols/Makefile])
 
 AC_OUTPUT
 
diff -Nur gedit-2.22.3/plugins/Makefile.am gedit-2.22.3-symbolbrowser/plugins/Makefile.am
--- gedit-2.22.3/plugins/Makefile.am   2008-08-02 04:06:03.000000000 +0200
+++ gedit-2.22.3-symbolbrowser/plugins/Makefile.am   2008-08-02 04:19:28.000000000 +0200
@@ -8,7 +8,9 @@
    sort       \
    spell       \
    taglist    \
-   time
+   time        \
+   symbolbrowser   \
+   symbolbrowser/symbols
 
 SUBDIRS =       \
    changecase   \
@@ -20,7 +22,9 @@
    sort      \
    taglist      \
    time      \
-   $(SPELL_PLUGIN_DIR)
+   $(SPELL_PLUGIN_DIR) \
+   symbolbrowser   \
+   symbolbrowser/symbols
 
 if ENABLE_PYTHON
 DIST_SUBDIRS += externaltools pythonconsole snippets

diff -ur gedit-2.22.3/configure.ac gedit-2.22.3-symbolbrowser/configure.ac
--- gedit-2.22.3/plugins/symbolbrowser/gedit-symbol-browser-plugin-defs.h   2008-08-02 05:19:43.000000000 +0200
+++ gedit-2.22.3-symbolbrowser/plugins/symbolbrowser/gedit-symbol-browser-plugin-defs.h   2008-08-02 05:19:56.000000000 +0200
@@ -4,7 +4,7 @@
 #define WINDOW_DATA_KEY "GeditSymbolBrowserPluginWindowData"
 #define GEDIT_SYMBOL_BROWSER_PLUGIN_GCONF_PATH "/apps/gedit-2/plugins/symbol-browser/"
-#define GEDIT_SYMBOL_BROWSER_PLUGIN_CTAGS_EXEC "ctags -n --fields=-k-f-s-t+K+l+n -f - %s"
-#define GEDIT_SYMBOL_BROWSER_PLUGIN_CTAGS_VERSION "ctags --version"
+#define GEDIT_SYMBOL_BROWSER_PLUGIN_CTAGS_EXEC "exuberant-ctags -n --fields=-k-f-s-t+K+l+n -f - %s"
+#define GEDIT_SYMBOL_BROWSER_PLUGIN_CTAGS_VERSION "exuberant-ctags --version"
 #define GEDIT_SYMBOL_BROWSER_PLUGIN_HOME_SYMBOL_PATH ".gnome2/gedit/symbols/"
 #define GEDIT_SYMBOL_BROWSER_PLUGIN_SYS_SYMBOL_PATH GEDIT_SYMBOLBROWSER_DIR"symbols/"
 #define GEDIT_SYMBOL_BROWSER_PLUGIN_HOME_LOGO \

--- gedit-2.22.3/plugins/symbolbrowser/symbols/Makefile.am   2007-11-14 18:33:37.000000000 +0100
+++ gedit-2.22.3-symbolbrowser/plugins/symbolbrowser/symbols/Makefile.am   2008-08-02 23:45:33.000000000 +0200
@@ -1,5 +1,5 @@
 # Symbol Browser Plugin
-symbolsdir = $(libdir)/gedit-2/symbols
+symbolsdir = $(datadir)/gedit-2/symbolbrowser/symbols
 
 symbols_DATA = \
    gedit-symbol-browser-plugin.png \
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Unsupported Software All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum