blob: f8740ac6c3e113d64257462bcfcac6081aca83a0 (
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
|
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-util/visualvm/visualvm-1.3.3-r8.ebuild,v 1.1 2011/12/26 14:11:39 fordfrog Exp $
EAPI="4"
inherit autotools
VISUALVM_PKG="visualvm_harness-1.3"
VISUALVM_TARBALL="visualvm_133-src.tar.gz"
NETBEANS_PROFILER_TARBALL="netbeans-profiler-visualvm_release701.tar.gz"
DESCRIPTION="Integrates commandline JDK tools and profiling capabilites."
HOMEPAGE="http://icedtea.classpath.org"
SRC_URI="
http://icedtea.classpath.org/download/visualvm/${VISUALVM_PKG}.tar.gz
http://icedtea.classpath.org/download/visualvm/${VISUALVM_TARBALL}
http://icedtea.classpath.org/download/visualvm/${NETBEANS_PROFILER_TARBALL}"
LICENSE="GPL-2-with-linking-exception"
SLOT="7"
KEYWORDS="~amd64"
IUSE=""
COMMON_DEP="
dev-java/icedtea:${SLOT}
dev-util/netbeans:7.0"
RDEPEND="${COMMON_DEP}"
DEPEND="${COMMON_DEP}
dev-java/ant-core
dev-java/ant-nodeps"
S="${WORKDIR}/${VISUALVM_PKG}"
src_unpack() {
unpack ${VISUALVM_PKG}.tar.gz
}
src_prepare() {
epatch "${FILESDIR}"/netbeans-platform-version.patch
eautoreconf
unset JAVA_HOME JDK_HOME CLASSPATH JAVAC JAVACFLAGS
export ANT_RESPECT_JAVA_HOME=TRUE
export ANT_TASKS=ant-nodeps
}
src_configure() {
local vmhome=`get_vmhome`
econf NB_PLATFORM=platform \
--bindir="${vmhome}"/bin \
--libdir="${vmhome}"/lib \
--sysconfdir="${vmhome}"/lib/visualvm/etc \
--with-netbeans-profiler-zip="${DISTDIR}"/${NETBEANS_PROFILER_TARBALL} \
--with-visualvm-zip="${DISTDIR}"/${VISUALVM_TARBALL} \
--with-visualvm-version=${PV} \
--with-netbeans-home="${EPREFIX}"/usr/share/netbeans-nb-7.0 \
--with-jdk-home="${vmhome}"
}
src_compile() {
default
}
src_install() {
emake DESTDIR="${ED}" install
# Don't install default .desktop, file collision.
local vmhome=`get_vmhome`
rm -rf "${ED}"/usr/share
make_desktop_entry "${vmhome}/bin/jvisualvm" "OpenJDK ${SLOT} VisualVM" "java" "Development;Java;"
}
get_vmhome() {
local vmhandle=icedtea-${SLOT}
has_version "<=dev-java/icedtea-6.1.10.4:6" && vmhandle=icedtea6
local vmhome
vmhome="$(GENTOO_VM=${vmhandle} java-config -O)" || die
echo "${vmhome}"
}
|