summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVlastimil Babka <caster@gentoo.org>2008-11-02 20:19:09 +0000
committerVlastimil Babka <caster@gentoo.org>2008-11-02 20:19:09 +0000
commit913b1bf095520e6115fae5b4fb815176d6002f11 (patch)
tree121d3eea2415b672c3c9972208fafcb210c97fd6 /net-p2p/azureus
parentKeyword ~amd64; bug 245139 (diff)
downloadgentoo-2-913b1bf095520e6115fae5b4fb815176d6002f11.tar.gz
gentoo-2-913b1bf095520e6115fae5b4fb815176d6002f11.tar.bz2
gentoo-2-913b1bf095520e6115fae5b4fb815176d6002f11.zip
Version bump to 4.0.0.2, bug #242520. Uses EAPI=2 use deps for swt. Now uses shared plugin directory for upstream-bundled core plugins which fixes bug #219177 and #140372. Fixed also console UI and revbumped 3.1.1.0-r1 to include the fix as well for possibly sooner stable candidate - bug #219103. Cleanup old and unperspective versions.
(Portage version: 2.2_rc12/cvs/Linux 2.6.27-gentoo-r1-perfctr x86_64)
Diffstat (limited to 'net-p2p/azureus')
-rw-r--r--net-p2p/azureus/ChangeLog28
-rw-r--r--net-p2p/azureus/azureus-2.5.0.4-r1.ebuild136
-rw-r--r--net-p2p/azureus/azureus-3.1.1.0-r1.ebuild (renamed from net-p2p/azureus/azureus-3.0.5.0-r1.ebuild)110
-rw-r--r--net-p2p/azureus/azureus-4.0.0.2.ebuild167
-rw-r--r--net-p2p/azureus/files/azureus-3.1.1.0-pre75
-rw-r--r--net-p2p/azureus/files/azureus-4.0.0.2-pre75
-rw-r--r--net-p2p/azureus/files/azureus-bcprov-1.35.patch20
-rw-r--r--net-p2p/azureus/files/build.xml21
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.0/azureus-cache-size.patch11
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.0/azureus-no-restart.patch19
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-manifest-classpath.patch10
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-PlatformManagerUpdateChecker.patch14
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-osx-platforms.patch37
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.4/azureus-cache-size.patch11
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.4/azureus-no-restart.patch19
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-manifest-classpath.patch10
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-PlatformManagerUpdateChecker.patch14
-rw-r--r--net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-osx-platforms.patch51
-rw-r--r--net-p2p/azureus/files/patches-4.0.0.2/remove-osx-platform.diff24
-rw-r--r--net-p2p/azureus/files/patches-4.0.0.2/use-jdk-cipher-only.diff41
20 files changed, 456 insertions, 437 deletions
diff --git a/net-p2p/azureus/ChangeLog b/net-p2p/azureus/ChangeLog
index c40f5015f585..4becb2dc92c2 100644
--- a/net-p2p/azureus/ChangeLog
+++ b/net-p2p/azureus/ChangeLog
@@ -1,6 +1,32 @@
# ChangeLog for net-p2p/azureus
# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/azureus/ChangeLog,v 1.69 2008/10/25 21:21:46 pvdabeel Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/azureus/ChangeLog,v 1.70 2008/11/02 20:19:08 caster Exp $
+
+*azureus-4.0.0.2 (02 Nov 2008)
+*azureus-3.1.1.0-r1 (02 Nov 2008)
+
+ 02 Nov 2008; Vlastimil Babka <caster@gentoo.org>
+ -files/azureus-bcprov-1.35.patch,
+ -files/fedora-2.5.0.0/azureus-cache-size.patch,
+ -files/fedora-2.5.0.0/azureus-no-restart.patch,
+ -files/fedora-2.5.0.0/azureus-remove-manifest-classpath.patch,
+ -files/fedora-2.5.0.0/azureus-remove-win32-PlatformManagerUpdateChecker.pa
+ tch, -files/fedora-2.5.0.0/azureus-remove-win32-osx-platforms.patch,
+ -files/fedora-2.5.0.4/azureus-cache-size.patch,
+ -files/fedora-2.5.0.4/azureus-no-restart.patch,
+ -files/fedora-2.5.0.4/azureus-remove-manifest-classpath.patch,
+ -files/fedora-2.5.0.4/azureus-remove-win32-PlatformManagerUpdateChecker.pa
+ tch, -files/fedora-2.5.0.4/azureus-remove-win32-osx-platforms.patch,
+ +files/azureus-3.1.1.0-pre, +files/azureus-4.0.0.2-pre,
+ +files/patches-4.0.0.2/remove-osx-platform.diff,
+ +files/patches-4.0.0.2/use-jdk-cipher-only.diff, -files/build.xml,
+ -azureus-2.5.0.4-r1.ebuild, -azureus-3.0.5.0-r1.ebuild,
+ +azureus-3.1.1.0-r1.ebuild, +azureus-4.0.0.2.ebuild:
+ Version bump to 4.0.0.2, bug #242520. Uses EAPI=2 use deps for swt. Now
+ uses shared plugin directory for upstream-bundled core plugins which fixes
+ bug #219177 and #140372. Fixed also console UI and revbumped 3.1.1.0-r1 to
+ include the fix as well for possibly sooner stable candidate - bug
+ #219103. Cleanup old and unperspective versions.
*azureus-3.1.1.0 (16 Aug 2008)
diff --git a/net-p2p/azureus/azureus-2.5.0.4-r1.ebuild b/net-p2p/azureus/azureus-2.5.0.4-r1.ebuild
deleted file mode 100644
index 3ae15f2578ff..000000000000
--- a/net-p2p/azureus/azureus-2.5.0.4-r1.ebuild
+++ /dev/null
@@ -1,136 +0,0 @@
-# Copyright 1999-2007 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/azureus/azureus-2.5.0.4-r1.ebuild,v 1.10 2007/11/16 13:52:24 betelgeuse Exp $
-
-inherit eutils fdo-mime java-pkg-2 java-ant-2
-
-DESCRIPTION="Azureus - Java BitTorrent Client"
-HOMEPAGE="http://azureus.sourceforge.net/"
-SRC_URI="mirror://sourceforge/azureus/azureus_${PV}_source.zip"
-LICENSE="GPL-2 BSD"
-SLOT="0"
-KEYWORDS="amd64 ppc x86 ~x86-fbsd"
-
-IUSE="source"
-
-# >=swt-3.2 for bug
-# https://bugs.gentoo.org/show_bug.cgi?id=135835
-
-RDEPEND="
- >=virtual/jre-1.5
- >=dev-java/swt-3.2-r1
- >=dev-java/log4j-1.2.8
- >=dev-java/commons-cli-1.0
- >=dev-java/bcprov-1.35
- !net-p2p/azureus-bin"
-DEPEND="${RDEPEND}
- >=virtual/jdk-1.5
- dev-util/desktop-file-utils
- >=dev-java/ant-core-1.6.2
- source? ( app-arch/zip )
- >=app-arch/unzip-5.0"
-
-S=${WORKDIR}/${PN}
-
-src_unpack() {
- mkdir ${S}
- cd ${S}
- unpack ${A}
-
- # patches from 2.5.0.0 still work here
- EPATCH_SUFFIX="patch" EPATCH_FORCE="yes" \
- epatch ${FILESDIR}/fedora-${PV}/
-
- epatch ${FILESDIR}/azureus-bcprov-1.35.patch
-
- #removing osx files and entries
- rm -fr org/gudy/azureus2/ui/swt/osx org/gudy/azureus2/platform/macosx
- #removing windows files
- rm -fr org/gudy/azureus2/ui/swt/win32 org/gudy/azureus2/platform/win32
- #removing test files
- rm -fr org/gudy/azureus2/ui/swt/test
- rm -f org/gudy/azureus2/ui/console/multiuser/TestUserManager.java
- #removing bouncycastle
- rm -fr org/bouncycastle
-
- mkdir -p build/libs
- cd build/libs
- java-pkg_jar-from log4j
- java-pkg_jar-from commons-cli-1
- java-pkg_jar-from swt-3
- java-pkg_jar-from bcprov
-}
-
-src_compile() {
- # we started to force ecj because -Xmx seemed to have no effect but that
- # was because of ANT_OPTS not exported. Bug #145338
- use x86 && export ANT_OPTS="-Xmx128m"
- use amd64 && export ANT_OPTS="-Xmx256m"
- use ppc && export ANT_OPTS="-Xmx192m"
-
- eant ${ant_extra_opts} jar
-}
-
-src_install() {
- java-pkg_dojar dist/Azureus2.jar || die "dojar failed"
-
- java-pkg_dolauncher ${PN} \
- --main org.gudy.azureus2.ui.common.Main \
- -pre ${FILESDIR}/${PN}-2.5.0.0-pre \
- --pkg_args '--ui=${UI}' \
- --java_args '-Dazureus.install.path=${HOME}/.azureus/ ${JAVA_OPTIONS}'
-
- doicon "${FILESDIR}/azureus.png"
- domenu "${FILESDIR}/azureus.desktop"
- use source && java-pkg_dosrc ${S}/{com,org}
-}
-
-pkg_postinst() {
- echo
- elog "Due to the nature of the portage system, we recommend"
- elog "that users check portage for new versions of Azureus"
- elog "instead of attempting to use the auto-update feature."
- elog "We also set azureus.install.path to ~/.azureus so auto"
- elog "update probably does not even work."
- elog ""
- elog "You can disable auto-update in"
- elog "Tools->Options...->Interface->Start"
- echo
- elog "After running azureus for the first time, configuration"
- elog "options will be placed in ~/.azureus/gentoo.config"
- elog "It is recommended that you modify this file rather than"
- elog "the azureus startup script directly."
- echo
- elog "As of this version, the new ui type 'console' is supported,"
- elog "and this may be set in ~/.azureus/gentoo.config."
- echo
- elog "If you have problems starting azureus, try starting it"
- elog "from the command line to look at debugging output."
- echo
- ewarn "If you are upgrading, and the menu in azureus has entries like"
- ewarn "\"!MainWindow.menu.transfers!\" then you have a stray"
- ewarn "MessageBundle.properties file,"
- ewarn "and you may safely delete ~/.azureus/MessagesBundle.properties"
- echo
- elog "It's recommended to use Sun's Java version 1.5 or later."
- elog "If you're experiencing problems running azureus and you've"
- elog "using an older version of Java, try to upgrading to a new version. "
- echo
- elog "New in 2.5.0.0-r3:"
- ewarn 'azureus.install.path was changed to ${HOME}/.azureus/. Before'
- ewarn 'the Azureus plugin dir was created to the current working directory.'
- ewarn 'This means that you probably have a useless plugins directory in'
- ewarn 'your home directory.'
- ewarn 'See http://bugs.gentoo.org/show_bug.cgi?id=145908'
- ewarn 'for more information. Also you probably need to move the user'
- ewarn 'installed plugins to the new plugin directory.'
- echo
- ewarn "Please, do not run azureus as root!"
- ewarn "Azureus has not been developed for multi-user environments!"
-
- fdo-mime_desktop_database_update
-}
-
-pkg_postrm() {
- fdo-mime_desktop_database_update
-}
diff --git a/net-p2p/azureus/azureus-3.0.5.0-r1.ebuild b/net-p2p/azureus/azureus-3.1.1.0-r1.ebuild
index c0a5a13ddb29..2b29004cb2ca 100644
--- a/net-p2p/azureus/azureus-3.0.5.0-r1.ebuild
+++ b/net-p2p/azureus/azureus-3.1.1.0-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/azureus/azureus-3.0.5.0-r1.ebuild,v 1.1 2008/04/03 19:43:57 caster Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/azureus/azureus-3.1.1.0-r1.ebuild,v 1.1 2008/11/02 20:19:08 caster Exp $
###
### @Todo The new Azureus gui requires swt built with embedded mozilla support,
@@ -20,39 +20,44 @@ JAVA_PKG_IUSE="source"
inherit eutils fdo-mime java-pkg-2 java-ant-2
-DESCRIPTION="BitTorrent client in Java"
+DESCRIPTION="BitTorrent client in Java, also known as Vuze"
HOMEPAGE="http://azureus.sourceforge.net/"
-SRC_URI="mirror://sourceforge/azureus/Azureus_${PV}_source.zip"
+SRC_URI="mirror://sourceforge/azureus/Vuze_${PV}_source.zip"
LICENSE="GPL-2 BSD"
SLOT="0"
-KEYWORDS="~amd64 ~ppc ~x86 ~x86-fbsd"
+KEYWORDS="~amd64 ~x86 ~ppc ~ppc64"
IUSE=""
RDEPEND="
+ dev-java/json-simple:0
>=dev-java/bcprov-1.35:0
>=dev-java/commons-cli-1.0:1
>=dev-java/log4j-1.2.8:0
- >=dev-java/swt-3.4_pre6-r1:3.4
+ >=dev-java/swt-3.4:3.4
!net-p2p/azureus-bin
- >=virtual/jre-1.4"
+ >=virtual/jre-1.5"
DEPEND="${RDEPEND}
app-arch/unzip
dev-util/desktop-file-utils
- >=virtual/jdk-1.4"
+ >=virtual/jdk-1.5"
JAVA_PKG_FILTER_COMPILER="jikes"
S="${WORKDIR}"
pkg_setup() {
- if ! built_with_use --missing false -o dev-java/swt firefox seamonkey xulrunner; then
- eerror
- eerror "dev-java/swt:3.4 must be compiled with the firefox, seamonkey or xulrunner USE flag"
- eerror "(support may vary per swt version) or azureus will hang at startup!"
- eerror
- die "recompile dev-java/swt:3.4 with embedded browser"
+ # the order matters here because built_with_use doesn't like -o and --missing false combo
+ if ! built_with_use --missing false -o dev-java/swt:3.4 xulrunner mozilla firefox seamonkey; then
+ eerror "dev-java/swt:3.4 must be compiled with the firefox, mozilla, seamonkey or xulrunner USE flag"
+ eerror "(support may vary per swt version) or azureus would hang at startup!"
+ die "please recompile dev-java/swt:3.4 with embedded browser"
+ fi
+ # without cairo, some button captions seems missing
+ if ! built_with_use dev-java/swt:3.4 cairo; then
+ eerror "dev-java/swt:3.4 must be compiled with cairo USE flag"
+ die "please recompile dev-java/swt:3.4 with cairo USE flag"
fi
java-pkg-2_pkg_setup
}
@@ -60,49 +65,52 @@ pkg_setup() {
src_unpack() {
unpack ${A}
- epatch "${FILESDIR}/patches-3.0.3.4/azureus_all_modify-for-use-with-bcprov.patch"
- epatch "${FILESDIR}/patches-3.0.3.4/04_all_remove-osx-and-win32-PlatformManagerFactory.patch"
-
- ### Remove an unit test we never run
- rm -v ./org/gudy/azureus2/ui/console/multiuser/TestUserManager.java || die
+ epatch "${FILESDIR}/patches-3.1.1.0/use-jdk-cipher-only.diff"
+ epatch "${FILESDIR}/patches-3.1.1.0/remove-osx-platform.diff"
### Removes OS X files and entries.
rm -rv "org/gudy/azureus2/platform/macosx" \
- "org/gudy/azureus2/ui/swt/osx" || die
+ "org/gudy/azureus2/ui/swt/osx" || die
### Removes Windows files.
rm -v ./org/gudy/azureus2/ui/swt/win32/Win32UIEnhancer.java || die
### Removes test files.
- rm -rv "org/gudy/azureus2/ui/swt/test" || die
+ rm -rv "org/gudy/azureus2/ui/swt/test" \
+ org/gudy/azureus2/ui/console/multiuser/TestUserManager.java || die
### Removes bouncycastle (we use our own bcprov).
rm -rv "org/bouncycastle" || die
+
+ ### Removes bundled json
+ rm -rv "org/json" || die
+
+ mkdir -p build/libs || die
}
+JAVA_ANT_REWRITE_CLASSPATH="true"
+EANT_GENTOO_CLASSPATH="swt-3.4,bcprov,json-simple,log4j,commons-cli-1"
+
src_compile() {
local mem
use amd64 && mem="256"
use x86 && mem="128"
use ppc && mem="192"
- find . -name "*.java" > "${T}/az-src"
- ejavac -J-Xmx${mem}m -encoding latin1 \
- -classpath $(java-pkg_getjars swt-3.4,commons-cli-1,log4j,bcprov) \
- @"${T}/az-src"
- find . -type f -a ! -name "*.java" > "${T}/az-jarlist"
- jar cf azureus.jar @"${T}/az-jarlist"
+ use ppc64 && mem="256"
+ export ANT_OPTS="-Xmx${mem}m"
+ java-pkg-2_src_compile
}
src_install() {
-
- java-pkg_dojar "azureus.jar" || die "dojar failed"
+ java-pkg_dojar dist/*.jar || die "dojar failed"
+ dodoc ChangeLog.txt || die
java-pkg_dolauncher "${PN}" \
- --main "org.gudy.azureus2.ui.common.Main" \
- -pre "${FILESDIR}/${PN}-2.5.0.0-pre" \
+ --main 'org.gudy.azureus2.ui.common.Main' -pre "${FILESDIR}/${PN}-3.1.1.0-pre" \
--java_args '-Dazureus.install.path=${HOME}/.azureus/ ${JAVA_OPTIONS}' \
--pkg_args '--ui=${UI}'
+
# https://bugs.gentoo.org/show_bug.cgi?id=204132
java-pkg_register-environment-variable MOZ_PLUGIN_PATH /usr/lib/nsbrowser/plugins
@@ -117,49 +125,25 @@ pkg_postinst() {
### @Todo We should probably deactivate auto-update it by default,
### or even remove the option.
###
- elog
elog "It is not recommended to use the Azureus auto-update feature,"
- elog "and it might not even work. You should disable auto-update,"
- elog "in \"Tools\" -> \"Options...\" -> \"Interface\" -> \"Start\"."
- elog
-
+ elog "and it might not even work. You should disable auto-update via"
+ elog "Tools > Options > Interface > Start"
elog
elog "After running azureus for the first time, configuration"
- elog "options will be placed in \"~/.azureus/gentoo.config\"."
+ elog "options will be placed in '~/.azureus/gentoo.config'."
elog "If you need to change some startup options, you should"
elog "modify this file, rather than the startup script."
elog
elog "Using this config file you can start the console UI."
- elog
-
- elog
+ echo
+ elog "To switch from classic UI to Vuze use"
+ elog "1: Tools > Options > Interface > Start > Display Azureus UI Chooser"
+ elog "2: Toolbar (right-hand side)"
+ echo
elog "If you have problems starting Azureus, try starting it"
elog "from the command line to look at debugging output."
- elog
-
- elog
- elog "To switch from classic UI to Vuze use:"
- elog "Tools -> Options -> Interface -> Start"
- elog "\t-> Display Azureus UI Chooser"
- elog "Restart not working properly is a known issue."
- elog
-
- ewarn
- ewarn "If you are upgrading, and the menu in Azureus has entries"
- ewarn "like \"!MainWindow.menu.transfers!\" then you have a stray"
- ewarn "\"MessageBundle.properties\" file, and you may safely"
- ewarn "delete \"~/.azureus/MessagesBundle.properties\"."
- ewarn
-
- ewarn
- ewarn "Before azureus-2.5.0.0-r3, the Azureus plugin directory was"
- ewarn "set to \"~/plugins\", instead of \"~/.azureus/plugins\"."
- ewarn "If needed, you should move the plugins, to the new location."
- ewarn
-
- ewarn
+ echo
ewarn "Running Azureus as root is not supported."
- ewarn
fdo-mime_desktop_database_update
}
diff --git a/net-p2p/azureus/azureus-4.0.0.2.ebuild b/net-p2p/azureus/azureus-4.0.0.2.ebuild
new file mode 100644
index 000000000000..eaae396a554d
--- /dev/null
+++ b/net-p2p/azureus/azureus-4.0.0.2.ebuild
@@ -0,0 +1,167 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/azureus/azureus-4.0.0.2.ebuild,v 1.1 2008/11/02 20:19:08 caster Exp $
+
+EAPI=2
+
+JAVA_PKG_IUSE="source"
+
+inherit eutils fdo-mime java-pkg-2 java-ant-2
+
+MAIN_DIST=Vuze_${PV}_source.zip
+PLUGINS_N=azplugins
+RATING_N=azrating
+UPDATER_N=azupdater
+UPNPAV_N=azupnpav
+PLUGINS_V=2.1.6
+RATING_V=1.3.1
+UPDATER_V=1.8.8
+UPNPAV_V=0.2.2
+PLUGINS_DIST=${PLUGINS_N}_${PLUGINS_V}.jar
+RATING_DIST=${RATING_N}_${RATING_V}.jar
+UPDATER_DIST=${UPDATER_N}_${UPDATER_V}.zip
+UPNPAV_DIST=${UPNPAV_N}_${UPNPAV_V}.zip
+
+
+ALLPLUGINS_URL="http://azureus.sourceforge.net/plugins"
+
+DESCRIPTION="BitTorrent client in Java, now called Vuze"
+HOMEPAGE="http://www.vuze.com/"
+SRC_URI="mirror://sourceforge/azureus/${MAIN_DIST}
+ ${ALLPLUGINS_URL}/${PLUGINS_DIST}
+ ${ALLPLUGINS_URL}/${RATING_DIST}
+ ${ALLPLUGINS_URL}/${UPDATER_DIST}
+ ${ALLPLUGINS_URL}/${UPNPAV_DIST}"
+LICENSE="GPL-2 BSD"
+
+SLOT="0"
+KEYWORDS="~amd64 ~x86 ~ppc ~ppc64"
+IUSE=""
+
+# bundles parts of commons-lang, but modified
+# bundles parts of http://www.programmers-friend.org/
+RDEPEND="
+ dev-java/json-simple:0
+ >=dev-java/bcprov-1.35:0
+ >=dev-java/commons-cli-1.0:1
+ >=dev-java/log4j-1.2.8:0
+ >=dev-java/swt-3.4:3.4[cairo,xulrunner]
+ !net-p2p/azureus-bin
+ >=virtual/jre-1.5"
+
+DEPEND="${RDEPEND}
+ app-arch/unzip
+ dev-util/desktop-file-utils
+ >=virtual/jdk-1.5"
+
+JAVA_PKG_FILTER_COMPILER="jikes"
+
+src_unpack() {
+ mkdir "${S}" && cd "${S}" || die
+ unpack ${MAIN_DIST}
+
+ cd "${WORKDIR}"
+ mkdir -p plugins/{${PLUGINS_N},${RATING_N},${UPDATER_N},${UPNPAV_N}} || die
+ cp "${DISTDIR}/${PLUGINS_DIST}" plugins/${PLUGINS_N} || die
+ cp "${DISTDIR}/${RATING_DIST}" plugins/${RATING_N} || die
+ cd "${WORKDIR}/plugins/${UPDATER_N}" && unpack ${UPDATER_DIST} || die
+ cd "${WORKDIR}/plugins/${UPNPAV_N}" && unpack ${UPNPAV_DIST} || die
+
+ cd "${S}"
+ epatch "${FILESDIR}/patches-${PV}/use-jdk-cipher-only.diff"
+ epatch "${FILESDIR}/patches-${PV}/remove-osx-platform.diff"
+
+ ### Removes OS X files and entries.
+ rm -rv "org/gudy/azureus2/platform/macosx" \
+ "org/gudy/azureus2/ui/swt/osx" || die
+
+ ### Removes Windows files.
+ rm -v ./org/gudy/azureus2/ui/swt/win32/Win32UIEnhancer.java || die
+
+ ### Removes test files.
+ rm -rv "org/gudy/azureus2/ui/swt/test" \
+ org/gudy/azureus2/ui/console/multiuser/TestUserManager.java || die
+
+ ### Removes bouncycastle (we use our own bcprov).
+ rm -rv "org/bouncycastle" || die
+
+ ### Removes bundled json
+ rm -rv "org/json" || die
+
+ mkdir -p build/libs || die
+}
+
+JAVA_ANT_REWRITE_CLASSPATH="true"
+EANT_GENTOO_CLASSPATH="swt-3.4,bcprov,json-simple,log4j,commons-cli-1"
+
+src_compile() {
+ local mem
+ use amd64 && mem="256"
+ use x86 && mem="128"
+ use ppc && mem="192"
+ use ppc64 && mem="256"
+ export ANT_OPTS="-Xmx${mem}m"
+ java-pkg-2_src_compile
+}
+
+src_install() {
+ java-pkg_dojar dist/*.jar || die "dojar failed"
+ dodoc ChangeLog.txt || die
+
+ java-pkg_dolauncher "${PN}" \
+ --main org.gudy.azureus2.ui.common.Main -pre "${FILESDIR}/${PN}-4.0.0.2-pre" \
+ --java_args '-Dazureus.install.path=/usr/share/azureus/ ${JAVA_OPTIONS}' \
+ --pkg_args '--ui=${UI}'
+
+ insinto /usr/share/${PN}/
+ doins -r "${WORKDIR}/plugins"
+
+ # https://bugs.gentoo.org/show_bug.cgi?id=204132
+ java-pkg_register-environment-variable MOZ_PLUGIN_PATH /usr/lib/nsbrowser/plugins
+
+ doicon "${FILESDIR}/${PN}.png"
+ domenu "${FILESDIR}/${PN}.desktop"
+
+ use source && java-pkg_dosrc "${S}"/{com,edu,org}
+}
+
+pkg_postinst() {
+ ###
+ ### @Todo We should probably deactivate auto-update it by default,
+ ### or even remove the option - bug #218959
+ ###
+ ewarn "Running Azureus as root is not supported and may result in untracked"
+ ewarn "updates to shared components and then collisions on updates via portage"
+
+ elog "Since version 4.0.0.2, plugins that are normally bundled by upstream"
+ elog "(and auto-installed in each user's ~/.azureus if not bundled)"
+ elog "are now installed into shared plugin directory by the ebuild."
+ elog "Users are recommended to delete the following plugin copies:"
+ elog "~/.azureus/plugins/{${PLUGINS_N},${RATING_N},${UPDATER_N},${UPNPAV_N}}"
+ elog
+ elog "Azureus may warn that shared plugin dir is not writable, that's fine."
+ elog "It may also attempt to update some these plugins and fail to write."
+ elog "In that case look for or fill a bump bug in bugs.gentoo.org"
+ elog
+ elog "We plan to disable updater for shared components and plugins."
+ elog "See progress in bug #218959, patches welcome."
+ elog
+ elog "After running azureus for the first time, configuration"
+ elog "options will be placed in '~/.azureus/gentoo.config'."
+ elog "If you need to change some startup options, you should"
+ elog "modify this file, rather than the startup script."
+ elog "Using this config file you can start the console UI."
+ elog
+ elog "To switch from classic UI to Vuze use"
+ elog "1: Tools > Options > Interface > Start > Display Vuze UI Chooser"
+ elog "2: Toolbar (right-hand side)"
+ elog
+ elog "If you have problems starting Azureus, try starting it"
+ elog "from the command line to look at debugging output."
+
+ fdo-mime_desktop_database_update
+}
+
+pkg_postrm() {
+ fdo-mime_desktop_database_update
+}
diff --git a/net-p2p/azureus/files/azureus-3.1.1.0-pre b/net-p2p/azureus/files/azureus-3.1.1.0-pre
new file mode 100644
index 000000000000..505a7e704df3
--- /dev/null
+++ b/net-p2p/azureus/files/azureus-3.1.1.0-pre
@@ -0,0 +1,75 @@
+#
+# Copyright (c) 2005, Petteri Räty <betelgeuse@gentoo.org>
+# Copyright (c) 2004, Jochen Maes <sejo@gentoo.org>
+# Copyright (c) 2004, Karl Trygve Kalleberg <karltk@gentoo.org>
+# Copyright (c) 2004, Gentoo Foundation
+#
+# Licensed under the GNU General Public License, v2
+
+# The Azureus config dir has moved
+olddotazudir="${HOME}/.Azureus"
+oldgentoocfg="${olddotazudir}/gentoo.config"
+dotazudir="${HOME}/.azureus"
+gentoocfg="${dotazudir}/gentoo.config"
+
+if [[ -f "${oldgentoocfg}" && -f "${gentoocfg}" ]]; then
+ cat > /dev/stderr <<END
+You have gentoo.config files in both
+${dotazudir} and
+${olddotazudir}
+${olddotazudir} is deprecated and you can delete this directory.
+
+END
+fi
+
+create_initial_config() {
+ if [[ ! -e "${dotazudir}" ]] ; then
+ mkdir "${dotazudir}"
+ echo "Creating ${dotazudir}"
+ fi
+
+ [[ ${UI} ]] && UI="swt"
+
+ echo "Creating ${gentoocfg}"
+
+ # Create the config file
+ cat > "${gentoocfg}" <<END
+# User Interface options:
+# console - console based
+# swt - swt (GUI) based
+UI="${UI}"
+
+# Options you want to pass to the java binary
+JAVA_OPTIONS=""
+END
+}
+
+if [[ -f "${gentoocfg}" ]] ; then
+ . "${gentoocfg}"
+ echo "using ${gentoocfg}"
+elif [[ -f "${oldgentoocfg}" ]]; then
+ . "${oldgentoocfg}"
+ echo "using ${oldgentoocfg}"
+else
+ create_initial_config
+fi
+
+if [[ -z "${UI}" && -n "${UI_OPTIONS}" ]]; then
+ echo '${UI_OPTIONS} is no longer supported. ${UI} should be used instead instead' > /dev/stderr
+ echo 'Unsetting ${UI_OPTIONS} and trying to migrate to ${UI}' > /dev/stderr
+ if [[ ${UI_OPTIONS} = *--ui=console* ]]; then
+ UI=console
+ elif [[ ${UI_OPTIONS} = *--ui=swt* ]]; then
+ UI=swt
+ else
+ echo 'Could not make $UI from $UI_OPTIONS' > /dev/stderr
+ fi
+ unset UI_OPTIONS
+fi
+
+if [[ -z "${UI}" ]]; then
+ echo '$UI not set defaulting to swt' > /dev/stderr
+ UI="swt"
+fi
+
+[[ ! -e "${dotazudir}" ]] && create_initial_config
diff --git a/net-p2p/azureus/files/azureus-4.0.0.2-pre b/net-p2p/azureus/files/azureus-4.0.0.2-pre
new file mode 100644
index 000000000000..505a7e704df3
--- /dev/null
+++ b/net-p2p/azureus/files/azureus-4.0.0.2-pre
@@ -0,0 +1,75 @@
+#
+# Copyright (c) 2005, Petteri Räty <betelgeuse@gentoo.org>
+# Copyright (c) 2004, Jochen Maes <sejo@gentoo.org>
+# Copyright (c) 2004, Karl Trygve Kalleberg <karltk@gentoo.org>
+# Copyright (c) 2004, Gentoo Foundation
+#
+# Licensed under the GNU General Public License, v2
+
+# The Azureus config dir has moved
+olddotazudir="${HOME}/.Azureus"
+oldgentoocfg="${olddotazudir}/gentoo.config"
+dotazudir="${HOME}/.azureus"
+gentoocfg="${dotazudir}/gentoo.config"
+
+if [[ -f "${oldgentoocfg}" && -f "${gentoocfg}" ]]; then
+ cat > /dev/stderr <<END
+You have gentoo.config files in both
+${dotazudir} and
+${olddotazudir}
+${olddotazudir} is deprecated and you can delete this directory.
+
+END
+fi
+
+create_initial_config() {
+ if [[ ! -e "${dotazudir}" ]] ; then
+ mkdir "${dotazudir}"
+ echo "Creating ${dotazudir}"
+ fi
+
+ [[ ${UI} ]] && UI="swt"
+
+ echo "Creating ${gentoocfg}"
+
+ # Create the config file
+ cat > "${gentoocfg}" <<END
+# User Interface options:
+# console - console based
+# swt - swt (GUI) based
+UI="${UI}"
+
+# Options you want to pass to the java binary
+JAVA_OPTIONS=""
+END
+}
+
+if [[ -f "${gentoocfg}" ]] ; then
+ . "${gentoocfg}"
+ echo "using ${gentoocfg}"
+elif [[ -f "${oldgentoocfg}" ]]; then
+ . "${oldgentoocfg}"
+ echo "using ${oldgentoocfg}"
+else
+ create_initial_config
+fi
+
+if [[ -z "${UI}" && -n "${UI_OPTIONS}" ]]; then
+ echo '${UI_OPTIONS} is no longer supported. ${UI} should be used instead instead' > /dev/stderr
+ echo 'Unsetting ${UI_OPTIONS} and trying to migrate to ${UI}' > /dev/stderr
+ if [[ ${UI_OPTIONS} = *--ui=console* ]]; then
+ UI=console
+ elif [[ ${UI_OPTIONS} = *--ui=swt* ]]; then
+ UI=swt
+ else
+ echo 'Could not make $UI from $UI_OPTIONS' > /dev/stderr
+ fi
+ unset UI_OPTIONS
+fi
+
+if [[ -z "${UI}" ]]; then
+ echo '$UI not set defaulting to swt' > /dev/stderr
+ UI="swt"
+fi
+
+[[ ! -e "${dotazudir}" ]] && create_initial_config
diff --git a/net-p2p/azureus/files/azureus-bcprov-1.35.patch b/net-p2p/azureus/files/azureus-bcprov-1.35.patch
deleted file mode 100644
index 4e96230baf1d..000000000000
--- a/net-p2p/azureus/files/azureus-bcprov-1.35.patch
+++ /dev/null
@@ -1,20 +0,0 @@
---- azureus/com/aelitis/azureus/core/clientmessageservice/secure/impl/SecureMessageServiceClientHelper.java.orig 2007-01-20 18:23:49.000000000 +0100
-+++ azureus/com/aelitis/azureus/core/clientmessageservice/secure/impl/SecureMessageServiceClientHelper.java 2007-01-20 18:25:29.000000000 +0100
-@@ -36,7 +36,7 @@
- import org.bouncycastle.crypto.encodings.PKCS1Encoding;
- import org.bouncycastle.crypto.engines.RSAEngine;
- import org.bouncycastle.crypto.params.ParametersWithRandom;
--import org.bouncycastle.jce.provider.RSAUtil;
-+import org.bouncycastle.jce.provider.DSAUtil;
- import org.gudy.azureus2.core3.util.Debug;
- import org.gudy.azureus2.plugins.utils.StaticUtilities;
-
-@@ -97,7 +97,7 @@
-
- PKCS1Encoding padded_eng = new PKCS1Encoding( eng );
-
-- CipherParameters param = RSAUtil.generatePublicKeyParameter(public_key);
-+ CipherParameters param = DSAUtil.generatePublicKeyParameter(public_key);
-
- param = new ParametersWithRandom(param, new SecureRandom());
-
diff --git a/net-p2p/azureus/files/build.xml b/net-p2p/azureus/files/build.xml
deleted file mode 100644
index e1a91cff85c5..000000000000
--- a/net-p2p/azureus/files/build.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project basedir="." default="compile" name="Azureus">
- <target name="compile">
- <javac debug="true" deprecation="false" destdir="." srcdir=".">
- <classpath>
- <pathelement location="."/>
- <pathelement location="/usr/share/commons-cli-1/lib/commons-cli.jar"/>
- <pathelement location="/usr/share/swt-3/lib/swt.jar"/>
- <pathelement location="seda.jar"/>
- </classpath>
- </javac>
- </target>
- <target name="jar" depends="compile">
- <jar jarfile="azureus.jar" basedir=".">
- <fileset dir=".">
- <include name="**/*.class"/>
- <include name="**/*.properties"/>
- </fileset>
- </jar>
- </target>
-</project>
diff --git a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-cache-size.patch b/net-p2p/azureus/files/fedora-2.5.0.0/azureus-cache-size.patch
deleted file mode 100644
index 954f6eeae4f9..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-cache-size.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- org/gudy/azureus2/core3/config/COConfigurationManager.java.~1.34.~ 2006-01-19 21:27:18.000000000 -0500
-+++ org/gudy/azureus2/core3/config/COConfigurationManager.java 2006-02-09 00:01:46.000000000 -0500
-@@ -39,7 +39,7 @@
- public static final int CONFIG_CACHE_SIZE_MAX_MB;
-
- static{
-- long max_mem_bytes = Runtime.getRuntime().maxMemory();
-+ long max_mem_bytes = Math.min (Runtime.getRuntime().maxMemory(), 64*1024*1024);
- long mb_1 = 1*1024*1024;
- long mb_32 = 32*mb_1;
- CONFIG_CACHE_SIZE_MAX_MB = (int)(( max_mem_bytes - mb_32 )/mb_1);
diff --git a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-no-restart.patch b/net-p2p/azureus/files/fedora-2.5.0.0/azureus-no-restart.patch
deleted file mode 100644
index 11473ccdcdb3..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-no-restart.patch
+++ /dev/null
@@ -1,19 +0,0 @@
---- org/gudy/azureus2/ui/swt/mainwindow/MainMenu.java 2006-08-22 10:18:03.000000000 +0200
-+++ org/gudy/azureus2/ui/swt/mainwindow/MainMenu.java 2006-08-22 10:20:10.000000000 +0200
-@@ -200,16 +200,6 @@
- if(!Constants.isOSX) {
- new MenuItem(fileMenu, SWT.SEPARATOR);
-
-- MenuItem file_restart = new MenuItem(fileMenu, SWT.NULL);
-- Messages.setLanguageText(file_restart, "MainWindow.menu.file.restart"); //$NON-NLS-1$
--
-- file_restart.addListener(SWT.Selection, new Listener() {
--
-- public void handleEvent(Event event) {
-- UIFunctionsManagerSWT.getUIFunctionsSWT().dispose(true, false);
-- }
-- });
--
- final MenuItem file_exit = new MenuItem(fileMenu, SWT.NULL);
- if(!COConfigurationManager.getBooleanParameter("Enable System Tray") || !COConfigurationManager.getBooleanParameter("Close To Tray")) {
- KeyBindings.setAccelerator(file_exit, "MainWindow.menu.file.exit");
diff --git a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-manifest-classpath.patch b/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-manifest-classpath.patch
deleted file mode 100644
index 842e47b39f4a..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-manifest-classpath.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- build.xml.orig 2005-10-25 05:22:46.000000000 -0700
-+++ build.xml 2006-01-25 12:16:32.000000000 -0800
-@@ -39,7 +39,6 @@
- <jar destfile="${root.dir}/${dist.dir}/Azureus2.jar" basedir="${root.dir}" excludes="${dist.jar.excludes}" >
- <manifest>
- <attribute name="Main-Class" value="org.gudy.azureus2.ui.common.Main" />
-- <attribute name="Class-Path" value="Azureus2.jar apple-extensions.jar commons-cli.jar log4j.jar swt.jar swt-win32.jar swt-osx.jar" />
- </manifest>
- </jar>
-
diff --git a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-PlatformManagerUpdateChecker.patch b/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-PlatformManagerUpdateChecker.patch
deleted file mode 100644
index 6cbc8c194a02..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-PlatformManagerUpdateChecker.patch
+++ /dev/null
@@ -1,14 +0,0 @@
---- org/gudy/azureus2/pluginsimpl/local/PluginInitializer.java 2006-07-27 11:35:22.000000000 +0200
-+++ org/gudy/azureus2/pluginsimpl/local/PluginInitializer.java 2006-08-22 10:22:49.000000000 +0200
-@@ -131,11 +131,6 @@
- "azbpcorepatcher",
- "CorePatcher",
- "true" },
-- { PluginManagerDefaults.PID_PLATFORM_CHECKER,
-- "org.gudy.azureus2.platform.win32.PlatformManagerUpdateChecker",
-- "azplatform2",
-- "azplatform2",
-- "true" },
- //{ PluginManagerDefaults.PID_JPC,
- // "com.aelitis.azureus.plugins.jpc.JPCPlugin",
- // "azjpc",
diff --git a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-osx-platforms.patch b/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-osx-platforms.patch
deleted file mode 100644
index 961ee333ceef..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.0/azureus-remove-win32-osx-platforms.patch
+++ /dev/null
@@ -1,37 +0,0 @@
---- org/gudy/azureus2/platform/PlatformManagerFactory.java.orig 2005-09-12 12:00:07.000000000 -0700
-+++ org/gudy/azureus2/platform/PlatformManagerFactory.java 2006-01-25 11:25:11.000000000 -0800
-@@ -42,33 +42,7 @@
- {
- try{
- class_mon.enter();
--
-- if ( platform_manager == null ){
--
-- try{
-- if ( getPlatformType() == PlatformManager.PT_WINDOWS ){
--
-- platform_manager = org.gudy.azureus2.platform.win32.PlatformManagerImpl.getSingleton();
--
-- }else if( getPlatformType() == PlatformManager.PT_MACOSX ){
--
-- platform_manager = org.gudy.azureus2.platform.macosx.PlatformManagerImpl.getSingleton();
--
-- }
-- }catch( PlatformManagerException e ){
--
-- // exception will already have been logged
--
-- }catch( Throwable e ){
--
-- Debug.printStackTrace(e);
-- }
-- }
--
-- if ( platform_manager == null ){
--
-- platform_manager = org.gudy.azureus2.platform.dummy.PlatformManagerImpl.getSingleton();
-- }
-+ platform_manager = org.gudy.azureus2.platform.dummy.PlatformManagerImpl.getSingleton();
-
- return( platform_manager );
-
diff --git a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-cache-size.patch b/net-p2p/azureus/files/fedora-2.5.0.4/azureus-cache-size.patch
deleted file mode 100644
index 954f6eeae4f9..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-cache-size.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- org/gudy/azureus2/core3/config/COConfigurationManager.java.~1.34.~ 2006-01-19 21:27:18.000000000 -0500
-+++ org/gudy/azureus2/core3/config/COConfigurationManager.java 2006-02-09 00:01:46.000000000 -0500
-@@ -39,7 +39,7 @@
- public static final int CONFIG_CACHE_SIZE_MAX_MB;
-
- static{
-- long max_mem_bytes = Runtime.getRuntime().maxMemory();
-+ long max_mem_bytes = Math.min (Runtime.getRuntime().maxMemory(), 64*1024*1024);
- long mb_1 = 1*1024*1024;
- long mb_32 = 32*mb_1;
- CONFIG_CACHE_SIZE_MAX_MB = (int)(( max_mem_bytes - mb_32 )/mb_1);
diff --git a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-no-restart.patch b/net-p2p/azureus/files/fedora-2.5.0.4/azureus-no-restart.patch
deleted file mode 100644
index 11473ccdcdb3..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-no-restart.patch
+++ /dev/null
@@ -1,19 +0,0 @@
---- org/gudy/azureus2/ui/swt/mainwindow/MainMenu.java 2006-08-22 10:18:03.000000000 +0200
-+++ org/gudy/azureus2/ui/swt/mainwindow/MainMenu.java 2006-08-22 10:20:10.000000000 +0200
-@@ -200,16 +200,6 @@
- if(!Constants.isOSX) {
- new MenuItem(fileMenu, SWT.SEPARATOR);
-
-- MenuItem file_restart = new MenuItem(fileMenu, SWT.NULL);
-- Messages.setLanguageText(file_restart, "MainWindow.menu.file.restart"); //$NON-NLS-1$
--
-- file_restart.addListener(SWT.Selection, new Listener() {
--
-- public void handleEvent(Event event) {
-- UIFunctionsManagerSWT.getUIFunctionsSWT().dispose(true, false);
-- }
-- });
--
- final MenuItem file_exit = new MenuItem(fileMenu, SWT.NULL);
- if(!COConfigurationManager.getBooleanParameter("Enable System Tray") || !COConfigurationManager.getBooleanParameter("Close To Tray")) {
- KeyBindings.setAccelerator(file_exit, "MainWindow.menu.file.exit");
diff --git a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-manifest-classpath.patch b/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-manifest-classpath.patch
deleted file mode 100644
index 842e47b39f4a..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-manifest-classpath.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- build.xml.orig 2005-10-25 05:22:46.000000000 -0700
-+++ build.xml 2006-01-25 12:16:32.000000000 -0800
-@@ -39,7 +39,6 @@
- <jar destfile="${root.dir}/${dist.dir}/Azureus2.jar" basedir="${root.dir}" excludes="${dist.jar.excludes}" >
- <manifest>
- <attribute name="Main-Class" value="org.gudy.azureus2.ui.common.Main" />
-- <attribute name="Class-Path" value="Azureus2.jar apple-extensions.jar commons-cli.jar log4j.jar swt.jar swt-win32.jar swt-osx.jar" />
- </manifest>
- </jar>
-
diff --git a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-PlatformManagerUpdateChecker.patch b/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-PlatformManagerUpdateChecker.patch
deleted file mode 100644
index 6cbc8c194a02..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-PlatformManagerUpdateChecker.patch
+++ /dev/null
@@ -1,14 +0,0 @@
---- org/gudy/azureus2/pluginsimpl/local/PluginInitializer.java 2006-07-27 11:35:22.000000000 +0200
-+++ org/gudy/azureus2/pluginsimpl/local/PluginInitializer.java 2006-08-22 10:22:49.000000000 +0200
-@@ -131,11 +131,6 @@
- "azbpcorepatcher",
- "CorePatcher",
- "true" },
-- { PluginManagerDefaults.PID_PLATFORM_CHECKER,
-- "org.gudy.azureus2.platform.win32.PlatformManagerUpdateChecker",
-- "azplatform2",
-- "azplatform2",
-- "true" },
- //{ PluginManagerDefaults.PID_JPC,
- // "com.aelitis.azureus.plugins.jpc.JPCPlugin",
- // "azjpc",
diff --git a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-osx-platforms.patch b/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-osx-platforms.patch
deleted file mode 100644
index 44e1988f8fa1..000000000000
--- a/net-p2p/azureus/files/fedora-2.5.0.4/azureus-remove-win32-osx-platforms.patch
+++ /dev/null
@@ -1,51 +0,0 @@
---- org/gudy/azureus2/platform/PlatformManagerFactory.java.orig 2007-01-26 12:59:30.000000000 -0600
-+++ org/gudy/azureus2/platform/PlatformManagerFactory.java 2007-01-26 13:00:08.000000000 -0600
-@@ -40,46 +40,9 @@
- public static PlatformManager
- getPlatformManager()
- {
-- try{
-- class_mon.enter();
--
-- if ( platform_manager == null ){
--
-- try{
-- if ( getPlatformType() == PlatformManager.PT_WINDOWS ){
--
-- platform_manager = org.gudy.azureus2.platform.win32.PlatformManagerImpl.getSingleton();
--
-- }else if( getPlatformType() == PlatformManager.PT_MACOSX ){
--
-- platform_manager = org.gudy.azureus2.platform.macosx.PlatformManagerImpl.getSingleton();
--
-- }else if( getPlatformType() == PlatformManager.PT_UNIX ){
--
-- platform_manager = org.gudy.azureus2.platform.unix.PlatformManagerImpl.getSingleton();
--
-- }
-- }catch( PlatformManagerException e ){
--
-- // exception will already have been logged
--
-- }catch( Throwable e ){
--
-- Debug.printStackTrace(e);
-- }
-- }
-+ platform_manager = org.gudy.azureus2.platform.dummy.PlatformManagerImpl.getSingleton();
-
-- if ( platform_manager == null ){
--
-- platform_manager = org.gudy.azureus2.platform.dummy.PlatformManagerImpl.getSingleton();
-- }
--
-- return( platform_manager );
--
-- }finally{
--
-- class_mon.exit();
-- }
-+ return( platform_manager );
- }
-
- public static int
diff --git a/net-p2p/azureus/files/patches-4.0.0.2/remove-osx-platform.diff b/net-p2p/azureus/files/patches-4.0.0.2/remove-osx-platform.diff
new file mode 100644
index 000000000000..9821573e4e55
--- /dev/null
+++ b/net-p2p/azureus/files/patches-4.0.0.2/remove-osx-platform.diff
@@ -0,0 +1,24 @@
+--- org/gudy/azureus2/platform/PlatformManagerFactory.java.orig 2008-07-06 22:58:18.000000000 +0200
++++ org/gudy/azureus2/platform/PlatformManagerFactory.java 2008-07-06 22:59:21.000000000 +0200
+@@ -50,10 +50,6 @@
+
+ platform_manager = org.gudy.azureus2.platform.win32.PlatformManagerImpl.getSingleton();
+
+- }else if( getPlatformType() == PlatformManager.PT_MACOSX ){
+-
+- platform_manager = org.gudy.azureus2.platform.macosx.PlatformManagerImpl.getSingleton();
+-
+ }else if( getPlatformType() == PlatformManager.PT_UNIX ){
+
+ platform_manager = org.gudy.azureus2.platform.unix.PlatformManagerImpl.getSingleton();
+@@ -89,10 +85,6 @@
+
+ return (PlatformManager.PT_WINDOWS );
+
+- } else if (Constants.isOSX) {
+-
+- return (PlatformManager.PT_MACOSX );
+-
+ } else if (Constants.isUnix) {
+
+ return (PlatformManager.PT_UNIX );
diff --git a/net-p2p/azureus/files/patches-4.0.0.2/use-jdk-cipher-only.diff b/net-p2p/azureus/files/patches-4.0.0.2/use-jdk-cipher-only.diff
new file mode 100644
index 000000000000..cc5055cbd770
--- /dev/null
+++ b/net-p2p/azureus/files/patches-4.0.0.2/use-jdk-cipher-only.diff
@@ -0,0 +1,41 @@
+--- com/aelitis/azureus/core/clientmessageservice/secure/impl/SecureMessageServiceClientHelper.java.orig 2008-07-06 22:54:36.000000000 +0200
++++ com/aelitis/azureus/core/clientmessageservice/secure/impl/SecureMessageServiceClientHelper.java 2008-07-06 22:56:29.000000000 +0200
+@@ -36,7 +36,6 @@
+ import org.bouncycastle.crypto.encodings.PKCS1Encoding;
+ import org.bouncycastle.crypto.engines.RSAEngine;
+ import org.bouncycastle.crypto.params.ParametersWithRandom;
+-import org.bouncycastle.jce.provider.RSAUtil;
+ import org.gudy.azureus2.core3.util.Debug;
+ import org.gudy.azureus2.plugins.utils.StaticUtilities;
+
+@@ -82,30 +81,12 @@
+
+ byte[] secret_bytes = session_key.getEncoded();
+
+- try{
+ Cipher rsa_cipher = Cipher.getInstance( "RSA" );
+
+ rsa_cipher.init( Cipher.ENCRYPT_MODE, public_key );
+
+ encryped_session_key = rsa_cipher.doFinal( secret_bytes );
+
+- }catch( Throwable e ){
+-
+- // fallback to the BC implementation for jdk1.4.2 as JCE RSA not available
+-
+- RSAEngine eng = new RSAEngine();
+-
+- PKCS1Encoding padded_eng = new PKCS1Encoding( eng );
+-
+- CipherParameters param = RSAUtil.generatePublicKeyParameter(public_key);
+-
+- param = new ParametersWithRandom(param, new SecureRandom());
+-
+- padded_eng.init( true, param );
+-
+- encryped_session_key = padded_eng.processBlock(secret_bytes, 0, secret_bytes.length);
+- }
+-
+ }catch( Throwable e ){
+
+ e.printStackTrace();