From 37c63a99adc9c0ea8c359f12c8cd3a14c8458546 Mon Sep 17 00:00:00 2001
From: Petteri Räty <betelgeuse@gentoo.org>
Date: Sat, 7 Mar 2009 16:01:00 +0000
Subject: Migrate to EAPI 2. (Portage version: 2.2_rc20/cvs/Linux 2.6.29-rc6
 i686)

---
 net-p2p/bittorrent/ChangeLog                  |  7 ++-
 net-p2p/bittorrent/bittorrent-5.0.9-r1.ebuild | 23 +++-----
 net-p2p/bittorrent/bittorrent-5.2.0.ebuild    | 84 ---------------------------
 net-p2p/bittorrent/bittorrent-5.2.2.ebuild    | 21 +++----
 4 files changed, 21 insertions(+), 114 deletions(-)
 delete mode 100644 net-p2p/bittorrent/bittorrent-5.2.0.ebuild

diff --git a/net-p2p/bittorrent/ChangeLog b/net-p2p/bittorrent/ChangeLog
index 7809c89c77ae..4caba6241ecc 100644
--- a/net-p2p/bittorrent/ChangeLog
+++ b/net-p2p/bittorrent/ChangeLog
@@ -1,6 +1,11 @@
 # ChangeLog for net-p2p/bittorrent
 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/bittorrent/ChangeLog,v 1.132 2009/02/04 14:23:39 patrick Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/bittorrent/ChangeLog,v 1.133 2009/03/07 16:01:00 betelgeuse Exp $
+
+  07 Mar 2009; Petteri Räty <betelgeuse@gentoo.org>
+  bittorrent-5.0.9-r1.ebuild, -bittorrent-5.2.0.ebuild,
+  bittorrent-5.2.2.ebuild:
+  Migrate to EAPI 2.
 
 *bittorrent-5.2.2 (04 Feb 2009)
 
diff --git a/net-p2p/bittorrent/bittorrent-5.0.9-r1.ebuild b/net-p2p/bittorrent/bittorrent-5.0.9-r1.ebuild
index e741d0e937fa..2470ac8080ef 100644
--- a/net-p2p/bittorrent/bittorrent-5.0.9-r1.ebuild
+++ b/net-p2p/bittorrent/bittorrent-5.0.9-r1.ebuild
@@ -1,8 +1,10 @@
-# Copyright 1999-2008 Gentoo Foundation
+# Copyright 1999-2009 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/bittorrent/bittorrent-5.0.9-r1.ebuild,v 1.4 2008/07/10 14:09:55 armin76 Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/bittorrent/bittorrent-5.0.9-r1.ebuild,v 1.5 2009/03/07 16:01:00 betelgeuse Exp $
 
+EAPI="2"
 WX_GTK_VER="2.6"
+
 inherit distutils fdo-mime eutils wxwidgets
 
 MY_P="${P/bittorrent/BitTorrent}"
@@ -18,8 +20,8 @@ SLOT="0"
 KEYWORDS="alpha amd64 arm hppa ia64 ppc ppc64 s390 sh sparc x86 ~x86-fbsd"
 IUSE="gtk"
 
-RDEPEND=">=dev-lang/python-2.3
-	gtk? ( =dev-python/wxpython-2.6* )
+RDEPEND=">=dev-lang/python-2.4.4-r14[threads]
+	gtk? ( =dev-python/wxpython-2.6*[unicode] )
 	>=dev-python/pycrypto-2.0
 	>=dev-python/twisted-2
 	dev-python/twisted-web
@@ -36,22 +38,13 @@ pkg_setup() {
 	if use gtk ; then
 		need-wxwidgets unicode ||
 			die "You must build wxGTK and wxpython with unicode support"
-
-		if ! built_with_use =dev-python/wxpython-2.6* unicode ; then
-			die "You must build wxGTK and wxpython with unicode support"
-		fi
 	fi
-
-	if ! built_with_use dev-lang/python threads; then
-                die "${PN} needs dev-lang/python with USE=\"threads\""
-        fi
 }
 
-src_unpack() {
-	unpack ${A}
-	cd "${S}"
+src_prepare() {
 	# path for documentation is in lowercase #109743
 	sed -i -r "s:(dp.*appdir):\1.lower():" BitTorrent/platform.py
+	distutils_src_prepare
 }
 
 src_install() {
diff --git a/net-p2p/bittorrent/bittorrent-5.2.0.ebuild b/net-p2p/bittorrent/bittorrent-5.2.0.ebuild
deleted file mode 100644
index 2e45a7ef0091..000000000000
--- a/net-p2p/bittorrent/bittorrent-5.2.0.ebuild
+++ /dev/null
@@ -1,84 +0,0 @@
-# Copyright 1999-2008 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/bittorrent/bittorrent-5.2.0.ebuild,v 1.3 2008/07/21 05:33:51 mr_bones_ Exp $
-
-WX_GTK_VER="2.6"
-inherit distutils fdo-mime eutils wxwidgets
-
-MY_P="${P/bittorrent/BitTorrent}"
-#MY_P="${MY_P/}"
-S=${WORKDIR}/${MY_P}
-
-DESCRIPTION="tool for distributing files via a distributed network of nodes"
-HOMEPAGE="http://www.bittorrent.com/"
-SRC_URI="http://download.bittorrent.com/dl/${MY_P}.tar.gz"
-
-LICENSE="BitTorrent"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
-IUSE="gtk"
-
-RDEPEND=">=dev-lang/python-2.3
-	gtk? ( =dev-python/wxpython-2.6* )
-	>=dev-python/pycrypto-2.0
-	>=dev-python/twisted-2
-	dev-python/twisted-web
-	net-zope/zopeinterface"
-DEPEND="${RDEPEND}
-	app-arch/gzip
-	>=sys-apps/sed-4.0.5
-	dev-python/dnspython"
-
-DOCS="README.txt TRACKERLESS.txt public.key"
-PYTHON_MODNAME="BitTorrent"
-
-pkg_setup() {
-	if use gtk ; then
-		need-wxwidgets unicode ||
-			die "You must build wxGTK and wxpython with unicode support"
-
-		if ! built_with_use =dev-python/wxpython-2.6* unicode ; then
-			die "You must build wxGTK and wxpython with unicode support"
-		fi
-	fi
-
-	if ! built_with_use dev-lang/python threads; then
-		die "${PN} needs dev-lang/python with USE=\"threads\""
-	fi
-}
-
-src_unpack() {
-	unpack ${A}
-	cd "${S}"
-	# path for documentation is in lowercase #109743
-	sed -i -r "s:(dp.*appdir):\1.lower():" BitTorrent/platform.py
-}
-
-src_install() {
-	distutils_src_install
-	use gtk || rm -f "${D}"/usr/bin/bittorrent
-
-	if use gtk ; then
-		doicon images/logo/bittorrent.ico
-		newicon images/logo/bittorrent_icon_32.png bittorrent.png
-		make_desktop_entry "bittorrent" "BitTorrent" bittorrent "Network"
-		echo "MimeType=application/x-bittorrent" \
-			>> "${D}"/usr/share/applications/bittorrent-${PN}.desktop
-	fi
-
-	newinitd "${FILESDIR}"/bittorrent-tracker.initd bittorrent-tracker
-	newconfd "${FILESDIR}"/bittorrent-tracker.confd bittorrent-tracker
-}
-
-pkg_postinst() {
-	einfo "Remember that BitTorrent has changed file naming scheme"
-	einfo "To run BitTorrent just execute /usr/bin/bittorrent"
-	einfo "To run the init.d, please use /etc/init.d/bittorrent-tracker"
-	elog
-	elog "If you are upgrading from bittorrent-4.4.0 you must remove "
-	elog "the ~/.bittorrent dir to make this version work. Remember to "
-	elog "do a backup first!"
-	elog
-	distutils_pkg_postinst
-	fdo-mime_desktop_database_update
-}
diff --git a/net-p2p/bittorrent/bittorrent-5.2.2.ebuild b/net-p2p/bittorrent/bittorrent-5.2.2.ebuild
index 7304d5fba338..24e341b5bddd 100644
--- a/net-p2p/bittorrent/bittorrent-5.2.2.ebuild
+++ b/net-p2p/bittorrent/bittorrent-5.2.2.ebuild
@@ -1,8 +1,10 @@
 # Copyright 1999-2009 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/bittorrent/bittorrent-5.2.2.ebuild,v 1.1 2009/02/04 14:23:39 patrick Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/bittorrent/bittorrent-5.2.2.ebuild,v 1.2 2009/03/07 16:01:00 betelgeuse Exp $
 
+EAPI="2"
 WX_GTK_VER="2.6"
+
 inherit distutils fdo-mime eutils wxwidgets
 
 MY_P="${P/bittorrent/BitTorrent}"
@@ -18,8 +20,8 @@ SLOT="0"
 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
 IUSE="gtk"
 
-RDEPEND=">=dev-lang/python-2.3
-	gtk? ( =dev-python/wxpython-2.6* )
+RDEPEND=">=dev-lang/python-2.4.4-r14[threads]
+	gtk? ( =dev-python/wxpython-2.6*[unicode] )
 	>=dev-python/pycrypto-2.0
 	>=dev-python/twisted-2
 	dev-python/twisted-web
@@ -36,22 +38,13 @@ pkg_setup() {
 	if use gtk ; then
 		need-wxwidgets unicode ||
 			die "You must build wxGTK and wxpython with unicode support"
-
-		if ! built_with_use =dev-python/wxpython-2.6* unicode ; then
-			die "You must build wxGTK and wxpython with unicode support"
-		fi
-	fi
-
-	if ! built_with_use dev-lang/python threads; then
-		die "${PN} needs dev-lang/python with USE=\"threads\""
 	fi
 }
 
-src_unpack() {
-	unpack ${A}
-	cd "${S}"
+src_prepare() {
 	# path for documentation is in lowercase #109743
 	sed -i -r "s:(dp.*appdir):\1.lower():" BitTorrent/platform.py
+	distutils_src_prepare
 }
 
 src_install() {
-- 
cgit v1.2.3-65-gdbad