blob: 7d1ef039dff54f86be3405b574affabca27d1b5f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
|
# 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.8 2007/07/13 05:52:07 mr_bones_ 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"
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_prerm() {
fdo-mime_desktop_database_update
}
|