--- bicyclerepair-0.9.ebuild.orig 2005-09-01 21:24:46.000000000 +0900 +++ bicyclerepair-0.9.ebuild 2005-09-07 21:29:13.000000000 +0900 @@ -2,8 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/dev-python/bicyclerepair/bicyclerepair-0.9.ebuild,v 1.1 2005/02/12 10:50:48 kloeri Exp $ -inherit distutils -mydoc="NEWS DESIGN" +inherit distutils elisp-common eutils DESCRIPTION="Bicycle Repair Man is the Python Refactoring Browser," @@ -11,15 +10,33 @@ SRC_URI="mirror://sourceforge/bicyclerepair/${P}.tar.gz" LICENSE="as-is" SLOT="0" -KEYWORDS="~x86 ~ppc" -IUSE="" -DEPEND="virtual/python" +KEYWORDS="~x86 ~ppc ~ppc-macos" +IUSE="emacs" +DEPEND=" + >=virtual/python-2.2 + emacs? ( + app-emacs/pymacs + >=app-emacs/python-mode-4.70 + )" + +SITEFILE="55bicyclerepair-gentoo.el" + +mydoc="README* NEWS" + + +src_unpack() { + unpack ${A} + cd ${S} || die "Failed to cd." + epatch ${FILESDIR}/BicycleRepairMan_Idle.py.diff +} src_install() { distutils_src_install + if use emacs ; then + elisp-site-file-install ${FILESDIR}/${SITEFILE} + fi insinto /usr/share/${PN} - doins ide-integration/bike.el - rm -f ${D}/usr/bin/bikeemacs.bat + doins ide-integration/bike.vim } pkg_postinst() { @@ -33,11 +50,30 @@ echo "[BicycleRepairMan_Idle]" >> ${config_txt} fi else - einfo "BicycleRepairMan won't integrate with IDLE included in Python 2.3*" + einfo "BicycleRepairMan for IDLE included in Python 2.3" + einfo "or higher is not fully supported." + einfo "If you want to try, add the following lines to" + einfo "/usr/lib/python${PYTHON_VER}/idlelib/config-extensions.def:" + einfo " " + einfo "[BicycleRepairMan_Idle]" + einfo "enable=1" + einfo "trace=0" + einfo "[BicycleRepairMan_Idle_cfgBindings]" + einfo "brm-find-references=" + einfo "brm-find-definition=" + einfo "brm-rename=" + einfo "brm-extract-method=" + einfo "brm-undo=" + einfo " " fi + use emacs && elisp-site-regen + einfo " " + einfo "To use bicyclerepair with vim, copy" + einfo "/usr/share/bicyclerepair/bike.vim to your ~/.vim/plugin/ directory." einfo " " - einfo "To use bicyclerepair with Xemacs or GNU Emacs you must be in Python" - einfo "mode and add this to your .emacs or .init.el:" - einfo "(load-library '/usr/share/bicyclerepair/bike.el')" } +pkg_postrm() { + distutils_pkg_postrm + use emacs && elisp-site-regen +}